how linux find dynamic lib?
来源:互联网 发布:centos smtp server 编辑:程序博客网 时间:2024/05/16 12:27
1.LD_LIBRARY_PATH环境变量
2.system default path:
linux:
file: /etc/ld.so.conf
trusted directories: /lib /usr/lib
通过命令ldconfig来设置:
http://linux.die.net/man/8/ldconfig
solaris:
file: /var/ld/ld.config
crle command:
http://docs.sun.com/app/docs/doc/819-2239/crle-1?a=view
3.write rpath to binary(在编译的时候通过rpath来将寻找链接库的路径写道binary):
LD_RUN_PATH环境变量
-R gcc的参数
如果找到include文件的:
gcc首先查找-I选项指定的目录,然后查找系统的头文件目录(通常是/usr/include);
而对于用引号包含的头文件,gcc首先查找包含头文件的.c文件所在的目录,然后查找-I选项指定的目录,然后查找系统的头文件目录。
参见:
http://www.eyrie.org/~eagle/notes/rpath.html
http://learn.akae.cn/media/ch20s04.html
http://www.yolinux.com/TUTORIALS/LibraryArchives-StaticAndDynamic.html
http://tldp.org/HOWTO/Program-Library-HOWTO/shared-libraries.html
- how linux find dynamic lib?
- static lib和dynamic lib
- static lib and dynamic lib
- how to find shell type in linux
- How to find a directory on linux?
- how to compile and link static/dynamic library in linux
- Dynamic connectivity --Union-Find
- 说说static lib ,dynamic lib,dll
- armv6zk-none-linux-gnueabi/bin/ld: cannot find /lib/libc.so.6 与cannot find /lib/libpthread.so.0
- armv6zk-none-linux-gnueabi/bin/ld: cannot find /lib/libc.so.6 与cannot find /lib/libpthread.so.0
- How to find and fix faults in Linux applications.
- How do I Find Out Linux CPU Utilization?
- How to Find Your IP Address in Ubuntu Linux
- How To Find Large File Size On Linux
- How do I Find Out Linux CPU Utilization?
- 【转载】How To Find IP Conflicts In Linux
- (2) How to find namespaces in a Linux system
- Find common substring[Dynamic Programming]
- 详解spring事务属性
- 认识GPS卫星导航定位系统
- Shortcuts for the Edit menu
- 通过ICSharpCode.SharpZipLib.dll压缩和解压ZIP文件
- final与static final变量(原生类型)的初始化方式
- how linux find dynamic lib?
- php excel类 ,phpExcel使用方法介绍
- 强制将需要的lib链接到binary中去
- 写下吧
- 骨灰级 Eclipse 快捷键
- Windows CE 和 Windows Mobile的区别
- Spring的事务属性
- Ext中checkbox和radio捕获check事件
- CodeSmith OracleUI界面写法