utilsnap.c问题
今天测试sqllib/samples下面的utilsnap.c函数,总是编译不过去,返回错误:/tmp/ccCBeM2B.o(.text+0x12b): In function `GetSnapshot':
: undefined reference to `db2GetSnapshotSize'
/tmp/ccCBeM2B.o(.text+0x1be): In function `GetSnapshot':
: undefined reference to `SqlInfoPrint'
/tmp/ccCBeM2B.o(.text+0x41b): In function `GetSnapshot':
: undefined reference to `db2GetSnapshot'
/tmp/ccCBeM2B.o(.text+0x5d8): In function `GetSnapshot':
: undefined reference to `db2GetSnapshot'
/tmp/ccCBeM2B.o(.text+0x670): In function `GetSnapshot':
: undefined reference to `SqlInfoPrint'
/tmp/ccCBeM2B.o(.text+0x22af): In function `TurnOnAllMonitorSwitches':
: undefined reference to `db2MonitorSwitches'
/tmp/ccCBeM2B.o(.text+0x22d6): In function `TurnOnAllMonitorSwitches':
: undefined reference to `SqlInfoPrint'
/tmp/ccCBeM2B.o(.text+0x2424): In function `UpdateUtilImpactLim':
: undefined reference to `db2CfgSet'
/tmp/ccCBeM2B.o(.text+0x2442): In function `UpdateUtilImpactLim':
: undefined reference to `SqlInfoPrint'
collect2: ld returned 1 exit status
请问是怎么回事?
调用他的主函数为:
#include "utilsnap.h"
#include <db2ApiDf.h>
main()
{
struct sqlma *qjsnap;
GetSnapshot(qjsnap);
}
头文件utilsnap.h为:
#include <db2ApiDf.h>
extern int GetSnapshot(struct sqlma *ma_ptr);
文件utilsnap.c在sqllib/samples下面
页:
[1]