sqliapi.h: No such file or directory
main.ec#include <stdio.h>
#include <stdlib.h>
main()
{
/*
$char DbNameLc;
printf( "Enter name of database: " );
gets( DbNameLc );
$database $DbNameLc;
if( SQLCODE == 0 )
printf( "Database %s is now open.\n", DbNameLc );
else
printf( "Error in opening database: %d\n", SQLCODE );
exit( 0 );
*/
}
d:\c_informix\esql -e main.ec
生成:main.c
然后编译main.c提示:
sqlhdr.h: No such file or directory.
sqliapi.h: No such file or directory.
我测试中发现通过esql.exe编译后的main.ec变为:
#include <sqlhdr.h>
#include <sqliapi.h>
#line 1 "main.ec"
#include <stdio.h>
#include <stdlib.h>
main()
{
/*
$char DbNameLc;
printf( "Enter name of database: " );
gets( DbNameLc );
$database $DbNameLc;
if( SQLCODE == 0 )
printf( "Database %s is now open.\n", DbNameLc );
else
printf( "Error in opening database: %d\n", SQLCODE );
exit( 0 );
*/
}
#line 18 "main.ec"
头文件自动添加了:
#include <sqlhdr.h>
#include <sqliapi.h>
于是我将这两个文件所在的目录引入配置到编译器的目录中,可是编译main.c还是提示:
sqlhdr.h: No such file or directory.
sqliapi.h: No such file or directory. 需要设置LD_LIBRARY_PATH,WINDOWS上不知道怎么设置,没在windows上弄过esql
/home/informix> esql -o test test.ec
/home/informix> ./test
/home/informix> 回复 2# sqlnet
谢谢你的回复。:)
我再找找资料看在win下面能否编译通过。也许是那里的设置有点问题。 在win下,实在是找不到关于esql.exe编辑.ec方面的资料。:cry:
页:
[1]