On 12/24/2013 11:14 AM, Lev Brouk wrote:
Hi,

I am not very experienced with Cmake, and couldn't figure this out
quickly...

I am trying to build and use a customized version of heka, with my own
plugin.

For compliance with our production conventions, I'd like to change the
package name and the install directory.   So far I have not found a good
way to do it.

You should be able to accomplish this by setting the appropriate variables in CMakeLists.txt. I think CPACK_PACKAGING_INSTALL_PREFIX and CPACK_DEBIAN_PACKAGE_NAME look might be helpful. Learn more at the following links:

- Intro to CPack: http://www.cmake.org/Wiki/CMake:Packaging_With_CPack
- CPack config reference: http://www.cmake.org/Wiki/CMake:CPackConfiguration
- CPack deb config reference: http://www.cmake.org/Wiki/CMake:CPackPackageGenerators#DEB_.28UNIX_only.29

It's worth noting that we've added a custom 'deb' target to build debian packages, separate from CPack's default 'package' target. You can see how this is happening in CMakeLists.txt: http://is.gd/xZDmds

/  Also, it appears that the deb package makes a home
directory...  not sure if I am doing something wrong?..

Nope, you're not, seems to be a bug that has recently appeared; I can reproduce on dev, but have verified that it's not happening on the versions/0.4 branch. I peeked at changes, but it's not immediately obvious to me what's causing the problem, and the winter holidays mean that I don't have the time to dig in right now. Can you open a bug in the github issue tracker?

-r

...
make deb
...

➜  DEB git:(dev) sudo dpkg --install --instdir=/opt heka_0.5.0_amd64.deb
Selecting previously deselected package heka.
(Reading database ... 51819 files and directories currently installed.)
Unpacking heka (from heka_0.5.0_amd64.deb) ...
Setting up heka (0.5.0) ...
➜  DEB git:(dev) l /opt
total 40
...
drwxr-xr-x  3 root     root     4096 Dec 24 18:55 home
...
drwxr-xr-x  4 root     root     4096 Dec 24 18:55 usr
...
➜  DEB git:(dev) l /opt/home/lev/dev/heka/build/heka/
total 12
drwxr-xr-x 2 root root 4096 Dec 24 18:55 include
drwxr-xr-x 2 root root 4096 Dec 24 18:55 lib
drwxr-xr-x 2 root root 4096 Dec 24 18:55 modules
➜  DEB git:(dev) l /opt/home/lev/dev/heka/build/heka/modules
total 12
-rw-r--r-- 1 root root 1478 Dec 24 18:04 cbufd.lua
-rw-r--r-- 1 root root 2500 Dec 24 18:04 rfc3339.lua
-rw-r--r-- 1 root root  666 Dec 24 18:04 rfc5424.lua


_______________________________________________
Heka mailing list
[email protected]
https://mail.mozilla.org/listinfo/heka

_______________________________________________
Heka mailing list
[email protected]
https://mail.mozilla.org/listinfo/heka

Reply via email to