Makefile 2.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566
  1. #
  2. # Copyright (C) 2006 OpenWrt.org
  3. #
  4. # This is free software, licensed under the GNU General Public License v2.
  5. # See /LICENSE for more information.
  6. #
  7. # $Id$
  8. include $(TOPDIR)/rules.mk
  9. PKG_NAME:=udev
  10. PKG_VERSION:=103
  11. PKG_RELEASE:=1
  12. PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
  13. PKG_SOURCE_URL:=ftp://ftp.kernel.org/pub/linux/utils/kernel/hotplug/ \
  14. http://ftp.kernel.org/pub/linux/utils/kernel/hotplug/ \
  15. ftp://ftp.de.kernel.org/pub/linux/utils/kernel/hotplug/ \
  16. http://ftp.de.kernel.org/pub/linux/utils/kernel/hotplug/ \
  17. ftp://ftp.fr.kernel.org/pub/linux/utils/kernel/hotplug/ \
  18. http://ftp.fr.kernel.org/pub/linux/utils/kernel/hotplug/
  19. PKG_MD5SUM:=7360ce47b5ec3f9fa71f18071ecb8b97
  20. PKG_CAT:=bzcat
  21. PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION)
  22. PKG_INSTALL_DIR:=$(PKG_BUILD_DIR)/ipkg-install
  23. include $(INCLUDE_DIR)/package.mk
  24. define Package/udev
  25. SECTION:=utils
  26. CATEGORY:=Utilities
  27. DEPENDS:=@LINUX_2_6
  28. TITLE:=Dynamic device management subsystem
  29. DESCRIPTION:=\
  30. udev provides a dynamic device directory containing only the files for \\\
  31. actually present devices. It creates or removes device node files in \\\
  32. the /dev directory, or it renames network interfaces.
  33. URL:=http://www.kernel.org/pub/linux/utils/kernel/hotplug/udev.html
  34. endef
  35. define Build/Compile
  36. $(MAKE) -C $(PKG_BUILD_DIR) \
  37. CROSS_COMPILE="$(TARGET_CROSS)" \
  38. STRIP="/bin/true" \
  39. OPTFLAGS="$(TARGET_CFLAGS)" \
  40. DESTDIR="$(PKG_INSTALL_DIR)" \
  41. INSTALL="install -c" \
  42. all install
  43. endef
  44. define Package/udev/install
  45. install -d -m0775 $(1)/etc/udev
  46. $(CP) $(PKG_INSTALL_DIR)/etc/udev/* $(1)/etc/udev/
  47. install -d -m0775 $(1)/lib/udev
  48. install -d -m0775 $(1)/sbin/
  49. $(CP) $(PKG_INSTALL_DIR)/sbin/udevcontrol $(1)/sbin/
  50. $(CP) $(PKG_INSTALL_DIR)/sbin/udevd $(1)/sbin/
  51. install -d -m0775 $(1)/usr/bin/
  52. $(CP) $(PKG_INSTALL_DIR)/usr/bin/udevinfo $(1)/usr/bin/
  53. $(CP) $(PKG_INSTALL_DIR)/usr/bin/udevtest $(1)/usr/bin/
  54. install -d -m0775 $(1)/usr/sbin/
  55. $(CP) $(PKG_INSTALL_DIR)/usr/sbin/udevmonitor $(1)/usr/sbin/
  56. endef
  57. $(eval $(call BuildPackage,udev))