日历
网志分类
· 所有网志 (15)
站内搜索
友情链接
· 我的歪酷

订阅 RSS

0002972

歪酷博客

一个人默默的走


« 上一篇: 樱花烂漫 下一篇: Yahoo pipes »
BillWang @ 2007-04-10 00:13

  昨天研究了一下boost.build v2,花了不少时间才明白这玩意是怎么配置的。觉得开发boost的人都是天才,文档写的那叫一个简洁,不该说的话那是一个字都不肯多说。当然更不可能期待什么Step by step tutorial了。因此这里还是写一下这个玩意是怎么工作的吧。(本人在Windows下工作,不过大部分内容对Linux的用户应该也有参考意义)

  1、编译bjam,运行\tools\jam\src\build.bat就行了。

  2、配置编译器,库,python等。配置文件在\tools\build\v2\user-config.jam里
在这个文件的某位添加
using <toolname>:<pram1>:<pram2>:......
关于param的定义可以使用bjam --help <toolname>.init,例如使用bjam --help intel-win.init
可以得到:
Rule 'intel-win.init ( version ? : command * : options * )':

  Initializes the intel toolset for windows

  * version: the compiler version
  * command: the command to invoke the compiler itself
  * options: Additional option: <compatibility> either 'vc6', 'vc7', 'vc7.1' or
    'native'(default).
这些话是什么以上我就不讲了

  3、配置python的param没有帮助,因此也让我摸索了不少的时间(还因此去研究了jam的语法)。首先,boost好像不支持python 2.5(反正我使用python 2.5没编译boost.python成功过),对于2.4,使用下面的配置可以正常工作。
using python : d:/Python24 ;

大概就这么多了,最后运行bjam就可以了,bjam的参数使用bjam --help有说明,个人觉得这个说明还是比较清楚的。祝大家编译boost成功。

最后说一句,最好不要使用STLPort编译boost,就算一定要用也一定要用5.0以下的老版本啊!



评论 / 个人网页 / 扔小纸条
*昵称

已经注册过? 请登录

Email
网址
*评论