2 # Copyright (C) 2006 OpenWrt.org
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
7 # $Id: Makefile 3822 2006-05-24 07:01:52Z nico $
9 include $(TOPDIR
)/rules.mk
15 PKG_SOURCE
:=$(PKG_NAME
)-$(PKG_VERSION
).
tar.gz
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_MD5SUM
:=c261230b27fc0fbcc287c76884caf2d3
23 PKG_BUILD_DIR
:=$(BUILD_DIR
)/$(PKG_NAME
)-$(PKG_VERSION
)
24 PKG_INSTALL_DIR
:=$(PKG_BUILD_DIR
)/ipkg-install
26 include $(INCLUDE_DIR
)/package.mk
28 define Package
/util-linux
/Default
31 URL
:=http
://www.kernel.org
/pub
/linux
/utils
/util-linux
/
35 $(call Package
/util-linux
/Default
)
36 TITLE
:=Partition table manipulation utility
38 This package contains an utility for managing disk partition tables.
39 URL
:=http
://www.kernel.org
/pub
/linux
/utils
/util-linux
/
42 define Package
/losetup
43 $(call Package
/util-linux
/Default
)
44 TITLE
:=Loopback devices setup and control utility
46 This package contains an utility for managing loopback devices.
49 define Package
/swap-utils
50 $(call Package
/util-linux
/Default
)
51 TITLE
:=Swap space management utilities
53 This package contains a collection of tools for managing swap space
: \\\
60 $(call Build
/Compile
/Default
, \
61 OPT
="$(TARGET_CFLAGS)" \
62 INSTALLSUID
="install -m 4755" \
63 DESTDIR
="$(PKG_INSTALL_DIR)" \
68 define Package
/Template
69 @if
[ \
! -f
"$(PKG_INSTALL_DIR)/$(1)" ]; then \
70 rm -f
$(PKG_BUILD_DIR
)/.built
; \
71 $(MAKE
) $(PKG_BUILD_DIR
)/.built
; \
73 install -d
-m0755
$(2)
74 $(CP
) $(PKG_INSTALL_DIR
)/$(1) $(2)/
77 define Package
/fdisk
/install
78 $(call Package
/Template
,sbin
/fdisk
,$(1)/usr
/sbin
)
81 define Package
/losetup
/install
82 $(call Package
/Template
,sbin
/losetup
,$(1)/usr
/sbin
)
85 define Package
/swap-utils
/install
86 $(call Package
/Template
,sbin
/mkswap
,$(1)/usr
/sbin
)
87 $(call Package
/Template
,sbin
/swapon
,$(1)/usr
/sbin
)
88 $(call Package
/Template
,sbin
/swapoff
,$(1)/usr
/sbin
)
91 $(eval
$(call BuildPackage
,fdisk
))
92 $(eval
$(call BuildPackage
,losetup
))
93 $(eval
$(call BuildPackage
,swap-utils
))