Message ID | 1341980076-28347-1-git-send-email-danomimanchego123@gmail.com |
---|---|
State | Superseded |
Headers | show |
On 07/11/12 06:14, Danomi Manchego wrote: > To allow custom scripts in the target skeletons. > > Signed-off-by: Danomi Manchego<danomimanchego123@gmail.com> Acked-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
Le Wed, 11 Jul 2012 00:14:36 -0400, Danomi Manchego <danomimanchego123@gmail.com> a écrit : > + if [ ! -f $(TARGET_DIR)/usr/share/udhcpc/default.script ]; then \ > + $(INSTALL) -m 0755 -D package/avahi/busybox-udhcpc-default.script \ > + $(TARGET_DIR)/usr/share/udhcpc/default.script; \ > + fi This doesn't work: the Busybox package already installs a default.script file in usr/share/udhcpc. If avahi is built before Busybox, then you'll have the Avahi script. If Busybox is built before Avahi, then you'll have the Busybox script. This doesn't look correct. Best regards, Thomas
Thomas, > If avahi is built before > Busybox, then you'll have the Avahi script. If Busybox is built before > Avahi, then you'll have the Busybox script. This doesn't look correct. Would it be appropriate to add something like this to busybox.mk, so that Avahi always gets built first? ifeq ($(BR2_PACKAGE_AVAHI),y) # Compile Avahi first, to ensure proper preference of conditional udhcpc/default.script installations BUSYBOX_DEPENDENCIES += avahi endif Dan - On Tue, Jul 17, 2012 at 5:45 PM, Thomas Petazzoni < thomas.petazzoni@free-electrons.com> wrote: > Le Wed, 11 Jul 2012 00:14:36 -0400, > Danomi Manchego <danomimanchego123@gmail.com> a écrit : > > > + if [ ! -f $(TARGET_DIR)/usr/share/udhcpc/default.script ]; then \ > > + $(INSTALL) -m 0755 -D > package/avahi/busybox-udhcpc-default.script \ > > + $(TARGET_DIR)/usr/share/udhcpc/default.script; \ > > + fi > > This doesn't work: the Busybox package already installs a > default.script file in usr/share/udhcpc. If avahi is built before > Busybox, then you'll have the Avahi script. If Busybox is built before > Avahi, then you'll have the Busybox script. This doesn't look correct. > > Best regards, > > Thomas > -- > Thomas Petazzoni, Free Electrons > Kernel, drivers, real-time and embedded Linux > development, consulting, training and support. > http://free-electrons.com >
diff --git a/package/avahi/avahi.mk b/package/avahi/avahi.mk index 32e3df7..481da03 100644 --- a/package/avahi/avahi.mk +++ b/package/avahi/avahi.mk @@ -144,8 +144,14 @@ AVAHI_POST_INSTALL_TARGET_HOOKS += AVAHI_REMOVE_INITSCRIPT define AVAHI_INSTALL_AUTOIPD rm -rf $(TARGET_DIR)/etc/dhcp3/ - $(INSTALL) -D -m 0755 package/avahi/busybox-udhcpc-default.script $(TARGET_DIR)/usr/share/udhcpc/default.script - $(INSTALL) -m 0755 package/avahi/S05avahi-setup.sh $(TARGET_DIR)/etc/init.d/ + if [ ! -f $(TARGET_DIR)/usr/share/udhcpc/default.script ]; then \ + $(INSTALL) -m 0755 -D package/avahi/busybox-udhcpc-default.script \ + $(TARGET_DIR)/usr/share/udhcpc/default.script; \ + fi + if [ ! -f $(TARGET_DIR)/etc/init.d/S05avahi-setup.sh ]; then \ + $(INSTALL) -m 0755 -D package/avahi/S05avahi-setup.sh \ + $(TARGET_DIR)/etc/init.d/S05avahi-setup.sh; \ + fi rm -f $(TARGET_DIR)/var/lib/avahi-autoipd $(INSTALL) -d -m 0755 $(TARGET_DIR)/var/lib ln -sf /tmp/avahi-autoipd $(TARGET_DIR)/var/lib/avahi-autoipd
To allow custom scripts in the target skeletons. Signed-off-by: Danomi Manchego <danomimanchego123@gmail.com> --- package/avahi/avahi.mk | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-)