开发者

Can't get my MacPorts libraries included in scons scripts

开发者 https://www.devze.com 2023-04-13 06:22 出处:网络
I\'m pretty new at command line stuff...currently trying to compile some library projects that are mostly built in C++, on my 200开发者_如何学JAVA7-era MacBook Pro running snow leopard. I was trying t

I'm pretty new at command line stuff...currently trying to compile some library projects that are mostly built in C++, on my 200开发者_如何学JAVA7-era MacBook Pro running snow leopard. I was trying to download some necessary libraries using MacPorts, which places them in opt/local/... which is not a default search path. I know that if I was compiling individual c++ programs I could just use the -L tag when running g++ but I am actually running scons scripts which compile dozens of lines at a time. I can't place dozens or hundreds of -L tags throughout these programs.

I don't know how to add /opt/local to the default library directories for gcc/g++ and I don't know how to get these Macports-installed libraries from /opt/local into a default directory. I would think either should work. I saw a related topic on a different board that recommended recompiling gcc, but I am using the older version of gcc which came with Xcode, I'd rather not risk screwing things up with Xcode unless I know that is the only way.


Try adding '/opt/local/lib' to the LIBPATH in the Environment() in the SCons build system.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号