package/libcgroup: allow to build cgroup-tools
authorBartosz Golaszewski <bgolaszewski@baylibre.com>
Mon, 24 Aug 2015 10:49:53 +0000 (12:49 +0200)
committerThomas Petazzoni <thomas.petazzoni@free-electrons.com>
Thu, 27 Aug 2015 18:30:39 +0000 (20:30 +0200)
Add a new config option that allows to build cgroup-tools - a set of
command-line utils for managing cgroups.

[Thomas: slightly change the prompt of the new Config.in option.]

Signed-off-by: Bartosz Golaszewski <bgolaszewski@baylibre.com>
Reviewed-by: Vicente Olivert Riera <Vincent.Riera@imgtec.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
package/libcgroup/Config.in
package/libcgroup/libcgroup.mk

index b7a84e06e0c953b1578797d616f1987274ff5aa3..d02c2829ad9eedb20509138fde5d88041fca5e10 100644 (file)
@@ -9,5 +9,14 @@ config BR2_PACKAGE_LIBCGROUP
 
          http://libcg.sourceforge.net/
 
+if BR2_PACKAGE_LIBCGROUP
+
+config BR2_PACKAGE_LIBCGROUP_TOOLS
+       bool "install tools"
+       help
+         Include a set of command-line tools for managing cgroups.
+
+endif
+
 comment "libcgroup needs an (e)glibc toolchain w/ C++"
        depends on !BR2_INSTALL_LIBSTDCPP || !BR2_TOOLCHAIN_USES_GLIBC
index ace27446995be0b3e27212566eeb32ba54acebc7..a4c3084c6c03f22f66eca8892d0dbc9ee8f65f7d 100644 (file)
@@ -20,10 +20,15 @@ LIBCGROUP_CONF_ENV = \
        CFLAGS="$(TARGET_CFLAGS) -U_FILE_OFFSET_BITS"
 
 LIBCGROUP_CONF_OPTS = \
-       --disable-tools \
        --disable-daemon \
        --disable-initscript-install
 
+ifeq ($(BR2_PACKAGE_LIBCGROUP_TOOLS),y)
+LIBCGROUP_CONF_OPTS += --enable-tools
+else
+LIBCGROUP_CONF_OPTS += --disable-tools
+endif
+
 ifeq ($(BR2_PACKAGE_LINUX_PAM),y)
 LIBCGROUP_DEPENDENCIES += linux-pam
 LIBCGROUP_CONF_OPTS += --enable-pam