我使用以下参数编译
#./configure --prefix=/usr/local CFLAGS=-fPIC --enable-static --enable-shared \ CFLAGS="-g -O2 -DSQLITE_ENABLE_FTS3=1 \ -DSQLITE_ENABLE_COLUMN_METADATA=1 \ -DSQLITE_ENABLE_UNLOCK_NOTIFY=1 \ -DSQLITE_SECURE_DELETE=1 \ -DSQLITE_ENABLE_DBSTAT_VTAB=1" # make -j 8 # make install
使用sqlite后,我收到以下错误消息:
/usr/bin/g++ -o utools/utools.so -Wl,-Bsymbolic -g -O2 -shared -Wl,-z,defs utools/utools.plugin.o utools/lib/libutools.a core/lib/libunv.a fv/lib/libfv.a sb/lib/libsb.a -lz -ldl /usr/bin/ld: /usr/local/sqlite/lib/libsqlite3.a(sqlite3.o): relocation R_X86_64_32S against `.rodata' can not be used when making a shared object; recompile with -fPIC /usr/local/sqlite/lib/libsqlite3.a: could not read symbols: Bad value collect2: ld returned 1 exit status scons: *** [stdarm/stdarm.so] Error 1 scons: building terminated because of errors.
答案 0 :(得分:1)
在/usr/local/lib/
目录中,删除以下对我有用的文件
我认为这些文件来自旧版本的libsqlite3,
因为当您键入并选中dpkg -L libsqlite3-dev
时,都不会进入/usr/local/lib/
我引用了sqlite3 breakage