我在我的Mint Linux安裝上編譯了一些C代碼時出現了一些編譯錯誤。編譯期間共享庫版本不匹配?
錯誤是所有版本不匹配問題。
這裏的「做錯誤」一節:
/usr/bin/ld: warning: libthread.so.1, needed by /home/lynton/Backup/Logosworld/IBM/Websphere MQ for Solaris x86 64bit/CZRV9ML/mqm/root/opt/mqm/lib64/libmqm.so, not found (try using -rpath or -rpath-link)
/usr/bin/ld: warning: libsocket.so.1, needed by /home/lynton/Backup/Logosworld/IBM/Websphere MQ for Solaris x86 64bit/CZRV9ML/mqm/root/opt/mqm/lib64/libmqm.so, not found (try using -rpath or -rpath-link)
/usr/bin/ld: warning: libc.so.1, needed by /home/lynton/Backup/Logosworld/IBM/Websphere MQ for Solaris x86 64bit/CZRV9ML/mqm/root/opt/mqm/lib64/libmqm.so, not found (try using -rpath or -rpath-link)
/usr/bin/ld: warning: libdl.so.1, needed by /home/lynton/Backup/Logosworld/IBM/Websphere MQ for Solaris x86 64bit/CZRV9ML/mqm/root/opt/mqm/lib64/libmqm.so, not found (try using -rpath or -rpath-link)
/home/lynton/Backup/Logosworld/IBM/Websphere MQ for Solaris x86 64bit/CZRV9ML/mqm/root/opt/mqm/lib64/libmqm.so: undefined reference to `xihThreadKey'
/home/lynton/Backup/Logosworld/IBM/Websphere MQ for Solaris x86 64bit/CZRV9ML/mqm/root/opt/mqm/lib64/libmqm.so: undefined reference to `xcsCreateThreadMutexSemX'
/home/lynton/Backup/Logosworld/IBM/Websphere MQ for Solaris x86 64bit/CZRV9ML/mqm/root/opt/mqm/lib64/libmqm.so: undefined reference to `thr_getspecific'
/home/lynton/Backup/Logosworld/IBM/Websphere MQ for Solaris x86 64bit/CZRV9ML/mqm/root/opt/mqm/lib64/libmqm.so: undefined reference to `xcsReleaseThreadMutexSem'
/home/lynton/Backup/Logosworld/IBM/Websphere MQ for Solaris x86 64bit/CZRV9ML/mqm/root/opt/mqm/lib64/libmqm.so: undefined reference to `xcsRequestThreadMutexSem'
collect2: ld returned 1 exit status
make: *** [idoclink_outbound] Error 1
因此,例如,它抱怨「libsocket.so.1」而我有的只是「libsocket.so.0」?
C開發人員通常如何解決這類問題?有什麼辦法可以下載那些抱怨的特定庫嗎?
感謝您的幫助;-)
林頓
您似乎嘗試在Linux上使用Solaris版本的Websphere MQ ... Solaris可能使用libmqm.so正在查找的版本號,而Linux不會。但是,僅僅更改版本號不會使編譯的Sparc對象代碼在Linux下運行。 – 2011-01-23 16:44:18
你們100%是正確的.....你看到發生了什麼是我的機器上的Solaris UNZIPPED Websphere MQ文件夾的「副本」以及..... DEEP在我的文件夾結構中。然後,當我在Code Blocks中工作時,我搜索了「libmqm.so」,並在那個愚蠢的solaris文件夾中找到了錯誤的lib ... aaarrgg。我已經指出正確的lib,並且所有編譯100%。再次感謝您的幫助; _) – 2011-01-24 08:15:41