cmake linux模板 多目录_CMake:如何在Linux中将目标/文件打包到多个包中?

I'm working on a project which generates quite a few executables, libraries

and configs, they need to be packed into different packages for deployment.

The problem is, the inclusion of those targets/files is not mutual

exclusive. One target/file can belong to multiple packages.

I'm using CMake 2.8.9 and trying CPack. I know it's kind of doable with

install types. But my platform is Ubuntu, so on Archives/Debs are

acceptable and they don't seem to support that.

With components/groups/parent groups it seems only possible to pack one

target/file into one component/group.

Is there any way out of this?

Thanks

解决方案

Well, I'll answer it myself for convinience of late comers: from CMake mail list, I got the answer: with cmake 2.8.9 or earlier (so far), run CPack multiple times with different component settings. That's a bit adhoc but does the job.

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值