Welcome 微信登录

首页 / 操作系统 / Linux / Ubuntu proc gcc典型问题

1.error: sqlca.h: No such file or directory执行gcc -o test test.c时:test.c:152:19: error: sqlca.h: No such file or directorysqlca.h在$Oracle_HOME/precomp/public/下更正后的命令:gcc -o test test.c -I $ORACLE_HOME/precomp/public2.undefined reference to `sqlcxt"执行5中的命令时出现错误如下:test.c:(.text+0x5e5): undefined reference to `sqlcxt"需要用到$ORACLE_HOME/lib/libclntsh.so故需加上 -L $ORACLE_HOME/lib -l clntsh更正后的命令为:gcc -o test test.c -I /home/oracle/oracle/product/10.2.0/db_1/precomp/public -L $ORACLE_HOME/lib -l clntsh3.proc着不到目录可执行export LD_LIBRARY_PATH=$ORACLE_HOME/lib