当前位置:网站首页>GCC:头文件和库文件的路径
GCC:头文件和库文件的路径
2022-08-05 00:41:00 【风静如云】
GCC有以下几个环境变量用于指定头文件和库文件的路径:
C_INCLUDE_PATH:用于指定C的头文件路径
CPLUS_INCLUDE_PATH:用于指定C++的头文件路径
LD_LIBRARY_PATH:用于指定运行时,库文件的路径(优先级要高于系统默认的查找路径)
LIBRARY_PATH:用于指定编译时,库文件的路径
如需修改这几个环境变量可以通过以下几种方法:
1.直接在命令行里输入(仅一次有效,终端关闭后失效),如:
export C_INCLUDE_PATH=XXXX:$C_INCLUDE_PATH
2.修改/etc/profile中完成(对所有用户生效),如:
export C_INCLUDE_PATH=XXXX:$C_INCLUDE_PATH
3.修改~/.bashrc(对当前用户生效),如:
export C_INCLUDE_PATH=XXXX:$C_INCLUDE_PATH
另外可以在编译时指定路径:
-I XXX:指定头文件路径
-L XXX:指定静态/动态库路径(编译时)
边栏推荐
- gorm联表查询-实战
- Software Testing Interview Questions: What is Software Testing?The purpose and principle of software testing?
- Software Testing Interview Questions: About Automated Testing Tools?
- canvas Gaussian blur effect
- 2022杭电多校第三场 K题 Taxi
- tiup telemetry
- Mysql_14 存储引擎
- EL定时刷新页面中的皕杰报表实例
- MongoDB搭建及基础操作
- tiup status
猜你喜欢

leetcode: 266. All Palindromic Permutations

QSunSync Qiniu cloud file synchronization tool, batch upload

刘润直播预告 | 顶级高手,如何创造财富

电赛必备技能___定时ADC+DMA+串口通信

gorm联表查询-实战

could not build server_names_hash, you should increase server_names_hash_bucket_size: 32

《WEB安全渗透测试》(28)Burp Collaborator-dnslog外带技术

典型相关分析CCA计算过程

数据类型-整型(C语言)

电子行业MES管理系统的主要功能与用途
随机推荐
Matlab uses plotting method for data simulation and simulation
could not build server_names_hash, you should increase server_names_hash_bucket_size: 32
Theory of Software Fundamentals
BC(转)[js]js计算两个时间相差天数
数据类型-整型(C语言)
2022 Multi-school Second Session K Question Link with Bracket Sequence I
《MySQL入门很轻松》第2章:MySQL管理工具介绍
what?测试/开发程序员要被淘汰了?年龄40被砍到了32?一瞬间,有点缓不过神来......
tiup status
Software testing interview questions: What are the three modules of LoadRunner?
Software testing interview questions: Please draw the seven-layer network structure diagram of OSI and the four-layer structure diagram of TCP/IP?
More than 2022 cattle school training topic Link with the second L Level Editor I
"WEB Security Penetration Testing" (28) Burp Collaborator-dnslog out-band technology
tiup telemetry
Software Testing Interview Questions: What aspects should be considered when designing test cases, i.e. what aspects should different test cases test against?
软件测试面试题:软件都有多少种分类?
软件测试面试题:黑盒测试、白盒测试以及单元测试、集成测试、系统测试、验收测试的区别与联系?
Software testing interview questions: Have you used some tools for software defect (Bug) management in your past software testing work? If so, please describe the process of software defect (Bug) trac
2022 Hangzhou Electric Multi-School 1004 Ball
典型相关分析CCA计算过程