summaryrefslogtreecommitdiffstats
path: root/package
diff options
context:
space:
mode:
authorUlf Samuelsson <ulf.samuelsson@atmel.com>2007-08-14 06:16:08 +0000
committerUlf Samuelsson <ulf.samuelsson@atmel.com>2007-08-14 06:16:08 +0000
commit3966e30541460e686012cc0d202b0dffac18ce5d (patch)
tree8fb8f4bc0193ba833aaf4c139eaac7d6f5ae361c /package
parentff2c1c8cd7c71e5633eb4baf9463fe3378a27312 (diff)
downloadbuildroot-novena-3966e30541460e686012cc0d202b0dffac18ce5d.tar.gz
buildroot-novena-3966e30541460e686012cc0d202b0dffac18ce5d.zip
Change udev target from udev to udevd. Add .PHONY targets. Rearrange targets
Diffstat (limited to 'package')
-rw-r--r--package/udev/udev.mk40
1 files changed, 24 insertions, 16 deletions
diff --git a/package/udev/udev.mk b/package/udev/udev.mk
index 014339092..0dbb2f5e3 100644
--- a/package/udev/udev.mk
+++ b/package/udev/udev.mk
@@ -9,7 +9,7 @@ UDEV_SITE:=ftp://ftp.kernel.org/pub/linux/utils/kernel/hotplug/
UDEV_CAT:=$(BZCAT)
UDEV_DIR:=$(BUILD_DIR)/udev-$(UDEV_VERSION)
UDEV_TARGET_BINARY:=sbin/udevd
-UDEV_BINARY:=udev
+UDEV_BINARY:=udevd
# 094 had _GNU_SOURCE set
BR2_UDEV_CFLAGS:= -D_GNU_SOURCE $(TARGET_CFLAGS)
@@ -17,15 +17,12 @@ ifeq ($(BR2_LARGEFILE),)
BR2_UDEV_CFLAGS+=-U_FILE_OFFSET_BITS
endif
-
# UDEV_ROOT is /dev so we can replace devfs, not /udev for experiments
UDEV_ROOT:=/dev
$(DL_DIR)/$(UDEV_SOURCE):
$(WGET) -P $(DL_DIR) $(UDEV_SITE)/$(UDEV_SOURCE)
-udev-source: $(DL_DIR)/$(UDEV_SOURCE)
-
$(UDEV_DIR)/.unpacked: $(DL_DIR)/$(UDEV_SOURCE)
$(UDEV_CAT) $(DL_DIR)/$(UDEV_SOURCE) | tar -C $(BUILD_DIR) $(TAR_OPTIONS) -
toolchain/patch-kernel.sh $(UDEV_DIR) package/udev \*.patch
@@ -36,10 +33,10 @@ $(UDEV_DIR)/$(UDEV_BINARY): $(UDEV_DIR)/.unpacked
CFLAGS="$(BR2_UDEV_CFLAGS)" \
USE_LOG=false USE_SELINUX=false \
udevdir=$(UDEV_ROOT) -C $(UDEV_DIR)
- touch -c $(UDEV_DIR)/$(UDEV_BINARY)
+ touch -c $@
$(TARGET_DIR)/$(UDEV_TARGET_BINARY): $(UDEV_DIR)/$(UDEV_BINARY)
- -mkdir $(TARGET_DIR)/sys
+ -mkdir -p $(TARGET_DIR)/sys
$(MAKE) CROSS_COMPILE=$(TARGET_CROSS) DESTDIR=$(TARGET_DIR) \
CFLAGS="$(BR2_UDEV_CFLAGS)" \
LDFLAGS="-warn-common" \
@@ -56,8 +53,25 @@ ifneq ($(strip $(BR2_PACKAGE_UDEV_UTILS)),y)
rm -f $(TARGET_DIR)/usr/bin/udevtest
endif
+#####################################################################
+.PHONY: udev-source udev udev-clean udev-dirclean
+
udev: uclibc $(TARGET_DIR)/$(UDEV_TARGET_BINARY)
+udev-source: $(DL_DIR)/$(UDEV_SOURCE)
+
+udev-clean: $(UDEV_CLEAN_DEPS)
+ rm -f $(TARGET_DIR)/etc/init.d/S10udev $(TARGET_DIR)/sbin/udev*
+ rm -f $(TARGET_DIR)/usr/sbin/udevmonitor $(TARGET_DIR)/usr/bin/udev*
+ rmdir $(TARGET_DIR)/sys
+ -$(MAKE) -C $(UDEV_DIR) clean
+
+udev-dirclean: $(UDEV_DIRCLEAN_DEPS)
+ rm -rf $(UDEV_DIR)
+
+#####################################################################
+.PHONY: udev-volume_id udev-volume_id-clean
+
ifeq ($(strip $(BR2_PACKAGE_UDEV_VOLUME_ID)),y)
$(STAGING_DIR)/usr/lib/libvolume_id.so.0.72.0:
$(MAKE) CROSS_COMPILE=$(TARGET_CROSS) \
@@ -74,7 +88,7 @@ $(TARGET_DIR)/lib/udev/vol_id: $(STAGING_DIR)/usr/lib/libvolume_id.so.0.72.0
-ln -sf libvolume_id.so.0.72.0 $(TARGET_DIR)/usr/lib/libvolume_id.so.0
$(STRIP) --strip-unneeded $(TARGET_DIR)/usr/lib/libvolume_id.so.0.72.0
-udev-volume_id: udev $(TARGET_DIR)/lib/udev/vol_id
+udev-volume_id: udev $(TARGET_DIR)/lib/udev/vol_id udev-volume_id-dirclean
udev-volume_id-clean:
rm -f $(STAGING_DIR)/usr/include/libvolume_id.h
@@ -90,6 +104,9 @@ UDEV_CLEAN_DEPS+=udev-volume_id-clean
UDEV_DIRCLEAN_DEPS+=udev-volume_id-dirclean
endif
+#####################################################################
+.PHONY: udev-scsi_id udev-scsi_id-clean udev-scsi_id-dirclean
+
ifeq ($(strip $(BR2_PACKAGE_UDEV_SCSI_ID)),y)
$(TARGET_DIR)/lib/udev/scsi_id: $(STAGING_DIR)/usr/lib/libvolume_id.so.0.72.0
$(MAKE) CROSS_COMPILE=$(TARGET_CROSS) \
@@ -115,15 +132,6 @@ UDEV_CLEAN_DEPS+=udev-scsi_id-clean
UDEV_DIRCLEAN_DEPS+=udev-scsi_id-dirclean
endif
-udev-clean: $(UDEV_CLEAN_DEPS)
- rm -f $(TARGET_DIR)/etc/init.d/S10udev $(TARGET_DIR)/sbin/udev*
- rm -f $(TARGET_DIR)/usr/sbin/udevmonitor $(TARGET_DIR)/usr/bin/udev*
- rmdir $(TARGET_DIR)/sys
- -$(MAKE) -C $(UDEV_DIR) clean
-
-udev-dirclean: $(UDEV_DIRCLEAN_DEPS)
- rm -rf $(UDEV_DIR)
-
#############################################################
#
# Toplevel Makefile options