add util-linux for fdisk (thanks to Philipp Kewisch )
[openwrt.git] / package / util-linux / Makefile
1 include $(TOPDIR)/rules.mk
2
3 PKG_NAME:=fdisk
4 PKG_VERSION:=2.12r
5 PKG_RELEASE:=1
6 PKG_MD5SUM:=c261230b27fc0fbcc287c76884caf2d3
7
8 PKG_SOURCE_URL:=ftp://ftp.kernel.org/pub/linux/utils/util-linux/ \
9 http://ftp.kernel.org/pub/linux/utils/util-linux/ \
10 ftp://ftp.de.kernel.org/pub/linux/utils/util-linux/ \
11 http://ftp.de.kernel.org/pub/linux/utils/util-linux/
12 PKG_SOURCE:=util-linux-$(PKG_VERSION).tar.gz
13 PKG_CAT:=zcat
14 PKG_BUILD_DIR:=$(BUILD_DIR)/util-linux-$(PKG_VERSION)
15 PKG_INSTALL_DIR:=$(PKG_BUILD_DIR)/ipkg-install
16
17 include $(TOPDIR)/package/rules.mk
18
19 $(eval $(call PKG_template,FDISK,fdisk,$(PKG_VERSION)-$(PKG_RELEASE),$(ARCH)))
20
21 $(PKG_BUILD_DIR)/.configured: $(PKG_BUILD_DIR)/.prepared
22 (cd $(PKG_BUILD_DIR); \
23 $(TARGET_CONFIGURE_OPTS) \
24 CFLAGS="$(TARGET_CFLAGS) -I$(STAGING_DIR)/usr/include -I$(STAGING_DIR)/include" \
25 LDFLAGS="-L$(STAGING_DIR)/usr/lib -L$(STAGING_DIR)/lib" \
26 ./configure \
27 );
28 touch $@
29
30 $(PKG_BUILD_DIR)/.built:
31 rm -rf $(PKG_INSTALL_DIR)
32 mkdir -p $(PKG_INSTALL_DIR)
33 $(MAKE) -C $(PKG_BUILD_DIR)/fdisk \
34 $(TARGET_CONFIGURE_OPTS) \
35 OPT="$(TARGET_CFLAGS)" \
36 DESTDIR="$(PKG_INSTALL_DIR)" \
37 all install
38 touch $@
39
40 $(IPKG_FDISK):
41 install -d -m0755 $(IDIR_FDISK)/usr/sbin
42 cp -fpR $(PKG_INSTALL_DIR)/sbin/fdisk $(IDIR_FDISK)/usr/sbin/
43 $(RSTRIP) $(IDIR_FDISK)
44 $(IPKG_BUILD) $(IDIR_FDISK) $(PACKAGE_DIR)
45
46 mostlyclean:
47 -$(MAKE) -C $(PKG_BUILD_DIR) clean
48 rm -f $(PKG_BUILD_DIR)/.built
This page took 0.044277 seconds and 5 git commands to generate.