Buildroot Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Maxim Mikityanskiy <maxtram95@gmail.com>
To: buildroot@busybox.net
Subject: [Buildroot] [PATCH 01/16] package/busybox: optional udhcpc script
Date: Mon, 19 Jan 2015 18:14:01 +0200	[thread overview]
Message-ID: <1421684056-5266-2-git-send-email-maxtram95@gmail.com> (raw)
In-Reply-To: <1421684056-5266-1-git-send-email-maxtram95@gmail.com>

Create new config option BR2_PACKAGE_BUSYBOX_UDHCPC_SCRIPT to control
whether to install optional udhcpc default.script. It is possible that
udhcpc is not enabled in busybox config, so default.script is useless in
that case.

Signed-off-by: Maxim Mikityanskiy <maxtram95@gmail.com>
---
 package/busybox/Config.in  |  5 +++++
 package/busybox/busybox.mk | 15 +++++++++++----
 2 files changed, 16 insertions(+), 4 deletions(-)

diff --git a/package/busybox/Config.in b/package/busybox/Config.in
index f2f2990..626faf5 100644
--- a/package/busybox/Config.in
+++ b/package/busybox/Config.in
@@ -26,6 +26,11 @@ config BR2_PACKAGE_BUSYBOX_SHOW_OTHERS
 	  Show packages in menuconfig that are potentially also provided
 	  by busybox.
 
+config BR2_PACKAGE_BUSYBOX_UDHCPC_SCRIPT
+	bool "Install the udhcpc default script"
+	help
+	  Install /usr/share/udhcp/default.script for udhcpc.
+
 config BR2_PACKAGE_BUSYBOX_WATCHDOG
 	bool "Install the watchdog daemon startup script"
 	help
diff --git a/package/busybox/busybox.mk b/package/busybox/busybox.mk
index f68a2f8..fbdde62 100644
--- a/package/busybox/busybox.mk
+++ b/package/busybox/busybox.mk
@@ -49,10 +49,20 @@ BUSYBOX_KCONFIG_FILE = $(BUSYBOX_CONFIG_FILE)
 BUSYBOX_KCONFIG_EDITORS = menuconfig xconfig gconfig
 BUSYBOX_KCONFIG_OPTS = $(BUSYBOX_MAKE_OPTS)
 
+ifeq ($(BR2_PACKAGE_BUSYBOX_UDHCPC_SCRIPT),y)
+define BUSYBOX_INSTALL_UDHCPC_SCRIPT
+	$(INSTALL) -m 0755 -D package/busybox/udhcpc.script \
+		$(TARGET_DIR)/usr/share/udhcpc/default.script; \
+endef
 define BUSYBOX_PERMISSIONS
 	/bin/busybox                     f 4755 0  0 - - - - -
 	/usr/share/udhcpc/default.script f 755  0  0 - - - - -
 endef
+else
+define BUSYBOX_PERMISSIONS
+	/bin/busybox                     f 4755 0  0 - - - - -
+endef
+endif
 
 # If mdev will be used for device creation enable it and copy S10mdev to /etc/init.d
 ifeq ($(BR2_ROOTFS_DEVICE_CREATION_DYNAMIC_MDEV),y)
@@ -210,10 +220,7 @@ endef
 
 define BUSYBOX_INSTALL_TARGET_CMDS
 	$(BUSYBOX_MAKE_ENV) $(MAKE) $(BUSYBOX_MAKE_OPTS) -C $(@D) install
-	$(INSTALL) -m 0755 -D package/busybox/udhcpc.script \
-		$(TARGET_DIR)/usr/share/udhcpc/default.script
-	$(INSTALL) -m 0755 -d \
-		$(TARGET_DIR)/usr/share/udhcpc/default.script.d
+	$(BUSYBOX_INSTALL_UDHCPC_SCRIPT)
 	$(BUSYBOX_INSTALL_MDEV_CONF)
 endef
 
-- 
2.2.1

  reply	other threads:[~2015-01-19 16:14 UTC|newest]

Thread overview: 60+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-01-19 16:14 [Buildroot] [PATCH 00/16] Different enhancements, primarily for systemd Maxim Mikityanskiy
2015-01-19 16:14 ` Maxim Mikityanskiy [this message]
2015-01-26 21:26   ` [Buildroot] [PATCH 01/16] package/busybox: optional udhcpc script Thomas Petazzoni
2015-01-26 22:06     ` Peter Korsgaard
2015-01-19 16:14 ` [Buildroot] [PATCH 02/16] package: install bash-completion files only with bash Maxim Mikityanskiy
2015-01-26 22:00   ` Thomas Petazzoni
2015-01-19 16:14 ` [Buildroot] [PATCH 03/16] package/dbus: fix machine-id when using systemd Maxim Mikityanskiy
2015-02-02 14:50   ` Samuel Martin
2015-02-02 15:18     ` Maxim Mikityanskiy
2015-07-12 23:48   ` Thomas Petazzoni
2015-01-19 16:14 ` [Buildroot] [PATCH 04/16] package/systemd: add missing dependencies Maxim Mikityanskiy
2015-02-02 14:22   ` Samuel Martin
2015-07-12 22:27   ` Thomas Petazzoni
2015-01-19 16:14 ` [Buildroot] [PATCH 05/16] package/systemd: apply locale settings in user shells Maxim Mikityanskiy
2015-02-02 15:20   ` Samuel Martin
2015-02-02 15:28     ` Maxim Mikityanskiy
2015-07-12 22:55   ` [Buildroot] [PATCH v2] skeleton: " Arnout Vandecappelle
2015-07-13 20:36     ` Thomas Petazzoni
2015-01-19 16:14 ` [Buildroot] [PATCH 06/16] package/dosfstools: add missing symlinks Maxim Mikityanskiy
2015-02-02 16:22   ` Samuel Martin
2015-03-08 22:04   ` Thomas Petazzoni
2015-01-19 16:14 ` [Buildroot] [PATCH 07/16] package/dropbear: install dropbear.service to correct dir Maxim Mikityanskiy
2015-02-02 20:41   ` Samuel Martin
2015-02-23 11:38   ` Thomas Petazzoni
2015-01-19 16:14 ` [Buildroot] [PATCH 08/16] package/e2fsprogs: make /sbin/fsck available Maxim Mikityanskiy
2015-02-02 20:44   ` Samuel Martin
2015-07-10 17:35   ` Thomas Petazzoni
2015-01-19 16:14 ` [Buildroot] [PATCH 09/16] package/minidlna: improve systemd support Maxim Mikityanskiy
2015-02-02 21:12   ` Samuel Martin
2015-02-02 21:30     ` Maxim Mikityanskiy
2015-02-02 23:22       ` Samuel Martin
2015-02-03  9:10       ` Arnout Vandecappelle
2015-03-08 21:52   ` Thomas Petazzoni
2015-01-19 16:14 ` [Buildroot] [PATCH 10/16] package/transmission: " Maxim Mikityanskiy
2015-02-02 22:09   ` Samuel Martin
2015-02-03  9:11     ` Arnout Vandecappelle
2015-07-14 13:51   ` [Buildroot] [PATCHv2] transmission: " Aurélien Chabot
2015-07-14 14:05     ` Maxime Hadjinlian
2015-07-16 21:27       ` Aurélien Chabot
2015-07-18 15:20         ` Maxime Hadjinlian
2015-07-19 22:18   ` [Buildroot] [PATCH v3] " Aurélien Chabot
2015-07-26 21:38     ` Maxime Hadjinlian
2015-07-27 21:56     ` Thomas Petazzoni
2015-01-19 16:14 ` [Buildroot] [PATCH 11/16] package/samba: use FHS dirs Maxim Mikityanskiy
2015-02-02 22:49   ` Samuel Martin
2015-04-06  9:45   ` Thomas Petazzoni
2015-01-19 16:14 ` [Buildroot] [PATCH 12/16] package/samba: add systemd support Maxim Mikityanskiy
2015-02-02 22:38   ` Samuel Martin
2015-07-13 20:47     ` Maxime Hadjinlian
2015-01-19 16:14 ` [Buildroot] [PATCH 13/16] package/tar: add support for acl and xattr Maxim Mikityanskiy
2015-02-02  8:26   ` Thomas Petazzoni
2015-01-19 16:14 ` [Buildroot] [PATCH 14/16] package/util-linux: add more tool select options Maxim Mikityanskiy
2015-01-26 22:11   ` Thomas Petazzoni
2015-02-07 22:00   ` Yann E. MORIN
2015-01-19 16:14 ` [Buildroot] [PATCH 15/16] package/vim: add default vimrc Maxim Mikityanskiy
2015-02-02 23:00   ` Samuel Martin
2015-07-10 18:24   ` Thomas Petazzoni
2015-01-19 16:14 ` [Buildroot] [PATCH 16/16] package/rng-tools: add systemd support for rngd Maxim Mikityanskiy
2015-02-02 17:12   ` Samuel Martin
2015-04-22 20:10   ` Thomas Petazzoni

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1421684056-5266-2-git-send-email-maxtram95@gmail.com \
    --to=maxtram95@gmail.com \
    --cc=buildroot@busybox.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox