嗨,在我的项目中,我配置了gcc选项。
介子构建-交叉文件mygcc.txt
在文件mygcc.txt中,我设置了gcc所需的命令:
[binaries]
c = '/usr/bin/gcc'
cc = '/usr/bin/gcc'
cpp = '/usr/bin/g++'
ar = '/usr/bin/gcc-ar'
strip = '/usr/bin/strip'
ld = '/usr/bin/ld'
....我想知道是否可以动态地设置安装gcc的根。
例如,如果我使用gcc -工具集,我可以切换安装在
/user/bin
至
/opt/rh/gcc-工具集-9/root/usr/bin
为了使用新的gcc,我需要改变mygcc.txt中的路径,删除构建dir,重新配置介子。
但是,是否可以配置介子,以便在所使用的巴什中选择gcc的集合?
gcc /opt/rh/gcc-工具集-9/root/usr/bin/ devel@lnx+
发布于 2022-05-25 06:33:49
为了解决这个问题,我在
[binaries]
c = 'gcc'
cc = 'gcc'
cpp = 'g++'
ar = 'gcc-ar'
strip = 'strip'
ld = 'ld'
pkgconfig = 'pkg-config'
.......然后我在.bashrc中添加了
#source gcc
source /opt/rh/gcc-toolset-9/enablehttps://stackoverflow.com/questions/71408939
复制相似问题