2 # Copyright (C) 2006-2008 OpenWrt.org
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
8 include $(TOPDIR
)/rules.mk
14 PKG_SOURCE
:=$(PKG_NAME
)-$(PKG_VERSION
).
tar.bz2
15 PKG_SOURCE_URL
:=@KERNEL
/linux
/utils
/kernel
/hotplug
/
16 PKG_MD5SUM
:=320ccd2d0f4540d10e021bafa14f8985
18 include $(INCLUDE_DIR
)/package.mk
24 TITLE
:=Dynamic device management subsystem
25 URL
:=http
://www.kernel.org
/pub
/linux
/utils
/kernel
/hotplug
/udev.html
28 define Package
/udev
/description
29 udev provides a dynamic device directory containing only the files for
30 actually present devices. It creates or removes device node files in
31 the
/dev directory
, or it renames network interfaces.
34 define Package
/udevextras
36 TITLE
:=Utilities for udev scripts
, for general device discovery
40 define Package
/udevextras
/config
41 source
"$(SOURCE)/udevextras-config.in"
44 UDEV_ALL_EXTRAS
=ata_id cdrom_id dasd_id edd_id scsi_id path_id usb_id volume_id
45 UDEV_EXTRAS
=$(strip $(foreach e
, $(UDEV_ALL_EXTRAS
), \
46 $(if
$(CONFIG_UDEVEXTRAS_
$(e
)),extras
/$(e
))))
49 $(MAKE
) -C
$(PKG_BUILD_DIR
) \
50 CROSS_COMPILE
="$(TARGET_CROSS)" \
52 OPTFLAGS
="$(TARGET_CFLAGS)" \
53 DESTDIR
="$(PKG_INSTALL_DIR)" \
54 INSTALL
="install -c" \
55 EXTRAS
="$(UDEV_EXTRAS)" \
56 VOLUME_ID_STATIC
=true \
60 define Package
/udev
/install
61 install -d
-m0775
$(1)/etc
/udev
62 $(CP
) $(PKG_INSTALL_DIR
)/etc
/udev
/* $(1)/etc
/udev
/
63 install -d
-m0775
$(1)/lib
/udev
64 install -d
-m0775
$(1)/sbin
/
65 $(INSTALL_BIN
) $(PKG_INSTALL_DIR
)/sbin
/udevcontrol
$(1)/sbin
/
66 $(INSTALL_BIN
) $(PKG_INSTALL_DIR
)/sbin
/udevd
$(1)/sbin
/
67 $(INSTALL_BIN
) $(PKG_INSTALL_DIR
)/sbin
/udevsettle
$(1)/sbin
/
68 install -d
-m0775
$(1)/usr
/bin
/
69 $(INSTALL_BIN
) $(PKG_INSTALL_DIR
)/usr
/bin
/udevinfo
$(1)/usr
/bin
/
70 $(INSTALL_BIN
) $(PKG_INSTALL_DIR
)/usr
/bin
/udevtest
$(1)/usr
/bin
/
71 install -d
-m0775
$(1)/usr
/sbin
/
72 $(INSTALL_BIN
) $(PKG_INSTALL_DIR
)/usr
/sbin
/udevmonitor
$(1)/usr
/sbin
/
73 install -d
-m0775
$(1)/etc
/udev
/rules.d
74 $(CP
) files
/20-input-grouping.rules
$(1)/etc
/udev
/rules.d
/
77 define Package
/udevextras
/install
78 $(INSTALL_DIR
) $(1)/etc
/udev
79 $(CP
) $(PKG_BUILD_DIR
)/etc
/udev
/rules.d
$(1)/etc
/udev
/
80 $(INSTALL_DIR
) $(1)/lib
/udev
81 $$(foreach f
, $$(shell $(FIND
) $(PKG_INSTALL_DIR
)/lib
/udev
/ -type f
), \
82 $(CP
) $$(f
) $(1)/lib
/udev
/ ; \
86 $(eval
$(call BuildPackage
,udev
))
87 $(eval
$(call BuildPackage
,udevextras
))