fix cbtt compile
[openwrt/svn-archive/archive.git] / utils / unzip / 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$
8
9 include $(TOPDIR)/rules.mk
10
11 PKG_NAME:=unzip
12 PKG_VERSION:=5.52
13 PKG_RELEASE:=1
14
15 PKG_SOURCE:=$(PKG_NAME)552.zip
16 PKG_SOURCE_URL:=@SF/infozip
17 PKG_MD5SUM:=3d55b4e7375c3d0b81feca52dc0e4d48
18
19 PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION)
20 PKG_INSTALL_DIR:=$(PKG_BUILD_DIR)/ipkg-install
21 PKG_UNPACK:=unzip -d $(PKG_BUILD_DIR)/ $(DL_DIR)/$(PKG_SOURCE)
22
23 include $(INCLUDE_DIR)/package.mk
24
25 define Package/unzip
26 SECTION:=utils
27 CATEGORY:=Utilities
28 DEPENDS:=
29 TITLE:=De-archiver for .zip files
30 URL:=http://infozip.sourceforge.net/Zip.html
31 SUBMENU:=compression
32 endef
33
34 define Package/unzip/description
35 InfoZIP's unzip program. With the exception of multi-volume archives
36 (ie, .ZIP files that are split across several disks using PKZIP's /& option),
37 this can handle any file produced either by PKZIP, or the corresponding
38 InfoZIP zip program.
39 endef
40
41 define Build/Configure
42 endef
43
44 define Build/Compile
45 $(MAKE) -C $(PKG_BUILD_DIR) -f unix/Makefile generic \
46 $(TARGET_CONFIGURE_OPTS) \
47 prefix="$(PKG_INSTALL_DIR)/usr" \
48 CFLAGS="$(TARGET_CFLAGS)" \
49 CF="$(TARGET_CFLAGS) -O -I$(STAGING_DIR)/usr/include -I. -DUNIX" \
50 LD="$(TARGET_CC) -L$(STAGING_DIR)/usr/lib" \
51 install
52 endef
53
54 define Package/unzip/install
55 $(INSTALL_DIR) $(1)/usr/bin/
56 $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/* $(1)/usr/bin/
57 endef
58
59 $(eval $(call BuildPackage,unzip))