Add ext2 as a compiled in on x86-2.4 so it's available for initrd on netboot and...
[openwrt.git] / package / util-linux / Makefile
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: Makefile 3822 2006-05-24 07:01:52Z nico $
8
9 include $(TOPDIR)/rules.mk
10
11 PKG_NAME:=util-linux
12 PKG_VERSION:=2.12r
13 PKG_RELEASE:=1
14 PKG_MD5SUM:=c261230b27fc0fbcc287c76884caf2d3
15
16 PKG_SOURCE_URL:=ftp://ftp.kernel.org/pub/linux/utils/$(PKG_NAME)/ \
17 http://ftp.kernel.org/pub/linux/utils/$(PKG_NAME)/ \
18 ftp://ftp.de.kernel.org/pub/linux/utils/$(PKG_NAME)/ \
19 http://ftp.de.kernel.org/pub/linux/utils/$(PKG_NAME)/
20 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
21 PKG_CAT:=zcat
22 PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION)
23 PKG_INSTALL_DIR:=$(PKG_BUILD_DIR)/ipkg-install
24
25 include $(INCLUDE_DIR)/package.mk
26
27 define Package/fdisk
28 SECTION:=base
29 CATEGORY:=Utilities
30 TITLE:=Partition table manipulation utility
31 DESCRIPTION:=A partition table manipulation utility
32 URL:=http://www.kernel.org/pub/linux/utils/util-linux/
33 endef
34
35 define Package/losetup
36 $(call Package/fdisk)
37 TITLE:=Loopback devices setup and control utility
38 DESCRIPTION:=A loopback devices setup and control utility
39 endef
40
41 define Package/swap-utils
42 $(call Package/fdisk)
43 TITLE:=Swap space management utilities
44 DESCRIPTION:=A collection of tools to manage swap space \\\
45 * mkswap\\\
46 * swapon\\\
47 * swapoff
48 endef
49
50 define Build/Compile
51 rm -rf $(PKG_INSTALL_DIR)
52 mkdir -p $(PKG_INSTALL_DIR)
53 $(MAKE) -C $(PKG_BUILD_DIR) \
54 $(TARGET_CONFIGURE_OPTS) \
55 OPT="$(TARGET_CFLAGS)" \
56 DESTDIR="$(PKG_INSTALL_DIR)" \
57 INSTALLSUID="install -m 4755" \
58 all install
59 endef
60
61 define Package/Template
62 @if [ \! -f "$(PKG_INSTALL_DIR)/$(1)" ]; then \
63 rm -f $(PKG_BUILD_DIR)/.built; \
64 $(MAKE) $(PKG_BUILD_DIR)/.built; \
65 fi
66 install -d -m0755 $(2)
67 $(CP) $(PKG_INSTALL_DIR)/$(1) $(2)/
68 endef
69
70 define Package/fdisk/install
71 $(call Package/Template,sbin/fdisk,$(1)/usr/sbin)
72 endef
73 define Package/losetup/install
74 $(call Package/Template,sbin/losetup,$(1)/usr/sbin)
75 endef
76 define Package/swap-utils/install
77 $(call Package/Template,sbin/mkswap,$(1)/usr/sbin)
78 $(call Package/Template,sbin/swapon,$(1)/usr/sbin)
79 $(call Package/Template,sbin/swapoff,$(1)/usr/sbin)
80 endef
81 $(eval $(call BuildPackage,fdisk))
82 $(eval $(call BuildPackage,losetup))
83 $(eval $(call BuildPackage,swap-utils))
This page took 0.045844 seconds and 5 git commands to generate.