linux程序小手記

查看程序的依賴庫c++

ldd 應用程序

有時會提示不是有效的動態執行文件,有人說是操做系統版本問題。具體查看方式和結果以下:ubuntu

root@ubuntu:/opt/build# readelf -d LinuxApp |grep NEEDED
 0x00000001 (NEEDED)                     Shared library: [libQt5Gui.so.5]
 0x00000001 (NEEDED)                     Shared library: [libQt5Qml.so.5]
 0x00000001 (NEEDED)                     Shared library: [libQt5SerialPort.so.5]
 0x00000001 (NEEDED)                     Shared library: [libQt5Core.so.5]
 0x00000001 (NEEDED)                     Shared library: [libpthread.so.0]
 0x00000001 (NEEDED)                     Shared library: [libstdc++.so.6]
 0x00000001 (NEEDED)                     Shared library: [libm.so.6]
 0x00000001 (NEEDED)                     Shared library: [libgcc_s.so.1]
 0x00000001 (NEEDED)                     Shared library: [libc.so.6]

這是qt寫的一個程序,有詳細的依賴關係。ui

相關文章
相關標籤/搜索