Compiling

未解決的 bz* 文件的依賴關係 rpm make from source

  • March 28, 2018

我正在嘗試從原始碼建構 rpm。我通過./configure並跑過一大塊makebzerror不幸的是,我一直被未定義的,bzwritebzflush其他引用阻止。在網上環顧四周,我看到這些功能是bzip2包的一部分。我已經安裝了開發庫,但我仍然收到此消息。誰能幫助我解決這些依賴關係?

make[2]: Entering directory `/mnt/fedRoot/rpm-4.6.1/lib'
make  all-am
make[3]: Entering directory `/mnt/fedRoot/rpm-4.6.1/lib'
/bin/sh ../libtool --tag=CC   --mode=link gcc -std=gnu99  -g -O2 -fPIC -DPIC -D_REENTRANT -Wall -Wpointer-arith -Wmissing-prototypes -Wno-char-subscripts  -fno-strict-aliasing -fstack-protector   -o rpmdb_archive  ../db3/db_archive.o ../db3/util_sig.o librpm.la -lrt -lpthread 
gcc -std=gnu99 -g -O2 -fPIC -DPIC -D_REENTRANT -Wall -Wpointer-arith -Wmissing-prototypes -Wno-char-subscripts -fno-strict-aliasing -fstack-protector -o .libs/rpmdb_archive ../db3/db_archive.o ../db3/util_sig.o  ./.libs/librpm.so /mnt/fedRoot/rpm-4.6.1/rpmio/.libs/librpmio.so -lmagic -lelf -llua -lm -lnss3 -lpopt -lrt -lpthread  -Wl,--rpath -Wl,/usr/local/lib

/mnt/fedRoot/rpm-4.6.1/rpmio/.libs/librpmio.so: undefined reference to `bzerror'
/mnt/fedRoot/rpm-4.6.1/rpmio/.libs/librpmio.so: undefined reference to `bzwrite'
/mnt/fedRoot/rpm-4.6.1/rpmio/.libs/librpmio.so: undefined reference to `bzflush'
/mnt/fedRoot/rpm-4.6.1/rpmio/.libs/librpmio.so: undefined reference to `bzdopen'
/mnt/fedRoot/rpm-4.6.1/rpmio/.libs/librpmio.so: undefined reference to `bzread'
/mnt/fedRoot/rpm-4.6.1/rpmio/.libs/librpmio.so: undefined reference to `bzclose'
/mnt/fedRoot/rpm-4.6.1/rpmio/.libs/librpmio.so: undefined reference to `bzopen'
collect2: ld returned 1 exit status
make[3]: *** [rpmdb_archive] Error 1
make[3]: Leaving directory `/mnt/fedRoot/rpm-4.6.1/lib'
make[2]: *** [all] Error 2
make[2]: Leaving directory `/mnt/fedRoot/rpm-4.6.1/lib'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/mnt/fedRoot/rpm-4.6.1'
make: *** [all] Error 2

圖書館必須由configure. 如果你執行configure,然後安裝 bzip2 開發文件,然後重新執行configure,它可能仍然從記憶體中選擇了錯誤的資訊。執行make distclean,然後./configure再執行。

引用自:https://unix.stackexchange.com/questions/15067