ubuntu16.04安装qtcreator

问题1:安装好qtcreator后,发现点击桌面Qt Creator图标没有反应,进入bin目录, ./qtcreator 。终端提示
[email protected]:~/qtcreator-2.5.0/bin$ ./qtcreator
./qtcreator: error while loading shared libraries: libstdc++.so.6: cannot open shared object file: No such file or directory

分析是缺少相应的动态库,后查百度,其动态库对应的安装包是 lib32stdc++6,于是sudo apt-get install lib32stdc++6    
问题2:解决上一个问题之后,再次 ./qtcreator,报如下错误    。
./qtcreator: error while loading shared libraries: libgthread-2.0.so.0: cannot open shared object file: No such file or directory

于是通过dpkg查找动态库对应的包  
[email protected]:~/qtcreator-2.5.0/bin$ dpkg -S libgthread-2.0.so.0
libglib2.0-0:amd64: /usr/lib/x86_64-linux-gnu/libgthread-2.0.so.0.4800.2
libglib2.0-0:amd64: /usr/lib/x86_64-linux-gnu/libgthread-2.0.so.0

于是sudo apt-get install libglib2.0-0:i386安装    (后面需要加i386,查百度说,i386是intel32位的统称)    
。。。。。。。此处省略三百安装。。。。后通过 ldd命名查看qtcreator所依赖的库        
[email protected]:~/qtcreator-2.5.0/bin$ ldd  qtcreator
	linux-gate.so.1 =>  (0xf7771000)
	libExtensionSystem.so.1 => /home/book/qtcreator-2.5.0/bin/./../lib/qtcreator/libExtensionSystem.so.1 (0xf773a000)
	libAggregation.so.1 => /home/book/qtcreator-2.5.0/bin/./../lib/qtcreator/libAggregation.so.1 (0xf7733000)
	libQtGui.so.4 => /home/book/qtcreator-2.5.0/bin/./../lib/libQtGui.so.4 (0xf6bb8000)
	libQtNetwork.so.4 => /home/book/qtcreator-2.5.0/bin/./../lib/libQtNetwork.so.4 (0xf6a5b000)
	libQtCore.so.4 => /home/book/qtcreator-2.5.0/bin/./../lib/libQtCore.so.4 (0xf6756000)
	libpthread.so.0 => /lib/i386-linux-gnu/libpthread.so.0 (0xf671f000)
	libstdc++.so.6 => /usr/lib32/libstdc++.so.6 (0xf65a8000)

后经过安装无数库,终于成功安装了qtCreator。        
ubuntu16.04安装qtcreator_第1张图片

主要涉及的命令有   分析库依赖安装包:  dpkg -S    xxx    
软件安装命令:sudo  apt-get install xxx:i386  (注意后面需要加 i386
查看qtcreator依赖的库 ldd   qtcreator

你可能感兴趣的:(QT)