From patchwork Wed Apr 25 13:15:09 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Gustavo Zacarias X-Patchwork-Id: 154906 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from fraxinus.osuosl.org (fraxinus.osuosl.org [140.211.166.137]) by ozlabs.org (Postfix) with ESMTP id D25B0B6F13 for ; Wed, 25 Apr 2012 23:15:26 +1000 (EST) Received: from localhost (localhost [127.0.0.1]) by fraxinus.osuosl.org (Postfix) with ESMTP id E3E2F10B8E7; Wed, 25 Apr 2012 13:15:24 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from fraxinus.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 9zoE4n7GHM0J; Wed, 25 Apr 2012 13:15:22 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by fraxinus.osuosl.org (Postfix) with ESMTP id 12CAD10B8A8; Wed, 25 Apr 2012 13:15:22 +0000 (UTC) X-Original-To: buildroot@lists.busybox.net Delivered-To: buildroot@osuosl.org Received: from whitealder.osuosl.org (whitealder.osuosl.org [140.211.166.138]) by ash.osuosl.org (Postfix) with ESMTP id 2F5BE8F753 for ; Wed, 25 Apr 2012 13:15:21 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by whitealder.osuosl.org (Postfix) with ESMTP id 24C1E858A5 for ; Wed, 25 Apr 2012 13:15:21 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from whitealder.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id foF7NSkw-1J4 for ; Wed, 25 Apr 2012 13:15:16 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.6 Received: from loknar.toptech.com.ar (loknar.toptech.com.ar [74.118.36.95]) by whitealder.osuosl.org (Postfix) with ESMTPS id 70D2B8FE33 for ; Wed, 25 Apr 2012 13:15:16 +0000 (UTC) Received: from asgard (host21.200-117-174.telecom.net.ar [200.117.174.21]) (authenticated bits=0) by loknar.toptech.com.ar (8.14.4/8.14.4) with ESMTP id q3PDFA0T003051 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Wed, 25 Apr 2012 10:15:12 -0300 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=zacarias.com.ar; s=dkey; t=1335359714; bh=V7ejjWUOx9pZ7RkwN7ys34swWMxMoGYcx4Gj25GPemg=; h=From:To:Cc:Subject:Date:Message-Id; b=bP4H27e1DoUZobUmzr0meDsJ/YGn8fqMRIjJkib0g+QTz5+88xpfeOTxSlFH8Z6Ws 3icQq4oHCQmZ3ZCVmXX4HbIpu43KLDEGFuDmm4eaqm8kAg4AT7+N+oCBr3fvZZUgNN DA1OAr4phnOWOzTlYIdvqbFYyYx75QYRSt3jS338= Received: by asgard (sSMTP sendmail emulation); Wed, 25 Apr 2012 10:15:09 -0300 From: Gustavo Zacarias To: buildroot@busybox.net Date: Wed, 25 Apr 2012 10:15:09 -0300 Message-Id: <1335359709-26898-1-git-send-email-gustavo@zacarias.com.ar> X-Mailer: git-send-email 1.7.3.4 X-Virus-Scanned: clamav-milter 0.97.3 at loknar X-Virus-Status: Clean Subject: [Buildroot] [PATCH] util-linux: disable installing binaries by default X-BeenThere: buildroot@busybox.net X-Mailman-Version: 2.1.14 Precedence: list List-Id: Discussion and development of buildroot List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: buildroot-bounces@busybox.net Sender: buildroot-bounces@busybox.net Disable installing binaries by default. This is to avoid installing unnecessary bloat when we just need libblkid/libuuid for some packages like e2fsprogs. Signed-off-by: Gustavo Zacarias --- package/util-linux/Config.in | 35 ++++++++++++++++++++++------------- package/util-linux/util-linux.mk | 37 ++++++++++++++++++++++++++++++++++++- 2 files changed, 58 insertions(+), 14 deletions(-) diff --git a/package/util-linux/Config.in b/package/util-linux/Config.in index 43a8444..65e90fb 100644 --- a/package/util-linux/Config.in +++ b/package/util-linux/Config.in @@ -11,6 +11,26 @@ config BR2_PACKAGE_UTIL_LINUX if BR2_PACKAGE_UTIL_LINUX +config BR2_PACKAGE_UTIL_LINUX_LIBBLKID + select BR2_PACKAGE_UTIL_LINUX_LIBUUID + bool "libblkid and blkid utilities" + default y + +config BR2_PACKAGE_UTIL_LINUX_LIBMOUNT + select BR2_PACKAGE_UTIL_LINUX_LIBBLKID + bool "libmount" + +config BR2_PACKAGE_UTIL_LINUX_LIBUUID + bool "libuuid and uuid utilities" + default y + +config BR2_PACKAGE_UTIL_LINUX_BINARIES + bool "install utilities" + help + Install util-linux binaries. + +if BR2_PACKAGE_UTIL_LINUX_BINARIES + ############################################ # default enabled and should be disabled by # --disable-foo @@ -24,22 +44,9 @@ config BR2_PACKAGE_UTIL_LINUX_FSCK select BR2_PACKAGE_UTIL_LINUX_LIBBLKID bool "build \"fsck\"" -config BR2_PACKAGE_UTIL_LINUX_LIBMOUNT - select BR2_PACKAGE_UTIL_LINUX_LIBBLKID - bool "build libmount" - -config BR2_PACKAGE_UTIL_LINUX_LIBUUID - bool "build libuuid and uuid utilities" - default y - config BR2_PACKAGE_UTIL_LINUX_UUIDD bool "build \"uuidd\"" -config BR2_PACKAGE_UTIL_LINUX_LIBBLKID - select BR2_PACKAGE_UTIL_LINUX_LIBUUID - bool "build libblkid and blkid utilities" - default y - config BR2_PACKAGE_UTIL_LINUX_AGETTY bool "build \"agetty\"" @@ -104,5 +111,7 @@ config BR2_PACKAGE_UTIL_LINUX_WRITE endif +endif + comment "util-linux requires a toolchain with LARGEFILE + WCHAR support" depends on !(BR2_LARGEFILE && BR2_USE_WCHAR) diff --git a/package/util-linux/util-linux.mk b/package/util-linux/util-linux.mk index d8a3ac9..08dbdcd 100644 --- a/package/util-linux/util-linux.mk +++ b/package/util-linux/util-linux.mk @@ -3,6 +3,7 @@ # util-linux # ############################################################# + UTIL_LINUX_VERSION = $(UTIL_LINUX_VERSION_MAJOR).1 UTIL_LINUX_VERSION_MAJOR = 2.20 UTIL_LINUX_SOURCE = util-linux-$(UTIL_LINUX_VERSION).tar.bz2 @@ -11,7 +12,6 @@ UTIL_LINUX_AUTORECONF = YES UTIL_LINUX_INSTALL_STAGING = YES UTIL_LINUX_DEPENDENCIES = host-pkg-config UTIL_LINUX_CONF_ENV = scanf_cv_type_modifier=no - UTIL_LINUX_CONF_OPT += --disable-rpath --disable-makeinstall-chown # We don't want the host-busybox dependency to be added automatically @@ -81,6 +81,41 @@ HOST_UTIL_LINUX_CONF_OPT += \ --disable-fallocate --disable-unshare --disable-rename \ --disable-schedutils --disable-wall --disable-partx +# Avoid the basic utilities if we just want the libraries +ifeq ($(BR2_PACKAGE_UTIL_LINUX_BINARIES),y) +define UTIL_LINUX_INSTALL_BINARIES + $(TARGET_MAKE_ENV) $(MAKE) -C $(@D) DESTDIR=$(TARGET_DIR) install +endef +endif + +ifeq ($(BR2_PACKAGE_UTIL_LINUX_LIBBLKID),y) +define UTIL_LINUX_INSTALL_LIBBLKID + $(TARGET_MAKE_ENV) $(MAKE) -C $(@D)/libblkid \ + DESTDIR=$(TARGET_DIR) install +endef +endif + +ifeq ($(BR2_PACKAGE_UTIL_LINUX_LIBMOUNT),y) +define UTIL_LINUX_INSTALL_LIBMOUNT + $(TARGET_MAKE_ENV) $(MAKE) -C $(@D)/libmount \ + DESTDIR=$(TARGET_DIR) install +endef +endif + +ifeq ($(BR2_PACKAGE_UTIL_LINUX_LIBUUID),y) +define UTIL_LINUX_INSTALL_LIBUUID + $(TARGET_MAKE_ENV) $(MAKE) -C $(@D)/libuuid \ + DESTDIR=$(TARGET_DIR) install +endef +endif + +define UTIL_LINUX_INSTALL_TARGET_CMDS + $(UTIL_LINUX_INSTALL_BINARIES) + $(UTIL_LINUX_INSTALL_LIBBLKID) + $(UTIL_LINUX_INSTALL_LIBMOUNT) + $(UTIL_LINUX_INSTALL_LIBUUID) +endef + $(eval $(call AUTOTARGETS)) $(eval $(call AUTOTARGETS,host))