2005-03-21 10:12:49 +02:00
|
|
|
# $Id$
|
|
|
|
|
2005-03-06 05:34:52 +02:00
|
|
|
include $(TOPDIR)/rules.mk
|
|
|
|
|
2005-04-14 09:11:36 +03:00
|
|
|
PKG_NAME:=zlib
|
2006-01-13 17:36:09 +02:00
|
|
|
PKG_VERSION:=1.2.3
|
|
|
|
PKG_RELEASE:=3
|
2005-03-06 05:34:52 +02:00
|
|
|
|
2006-05-10 22:06:22 +03:00
|
|
|
PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION)
|
|
|
|
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
|
2006-06-18 21:30:40 +03:00
|
|
|
PKG_SOURCE_URL:=http://www.zlib.net @SF/zlib
|
2006-05-10 22:06:22 +03:00
|
|
|
PKG_MD5SUM:=dee233bf288ee795ac96a98cc2e369b6
|
2005-05-24 05:27:19 +03:00
|
|
|
PKG_CAT:=bzcat
|
2005-03-06 05:34:52 +02:00
|
|
|
|
2005-05-13 07:26:17 +03:00
|
|
|
PKG_INSTALL_DIR:=$(PKG_BUILD_DIR)/ipkg-install
|
2005-03-06 05:34:52 +02:00
|
|
|
|
2005-05-13 07:26:17 +03:00
|
|
|
include $(TOPDIR)/package/rules.mk
|
2005-03-06 05:34:52 +02:00
|
|
|
|
2006-05-10 22:06:22 +03:00
|
|
|
define Package/zlib
|
|
|
|
SECTION:=base
|
|
|
|
CATEGORY:=Libraries
|
|
|
|
TITLE:=Library implementing the deflate compression method
|
|
|
|
DESCRIPTION:=A library implementing the 'deflate' compression method
|
|
|
|
URL:=http://www.zlib.net/
|
|
|
|
endef
|
2005-03-06 05:34:52 +02:00
|
|
|
|
2006-05-10 22:06:22 +03:00
|
|
|
define Build/Configure
|
2005-03-06 05:34:52 +02:00
|
|
|
(cd $(PKG_BUILD_DIR); \
|
2005-04-14 09:11:36 +03:00
|
|
|
$(TARGET_CONFIGURE_OPTS) \
|
2005-08-30 00:41:38 +03:00
|
|
|
LDSHARED="$(TARGET_CC) -shared -Wl,-soname,libz.so.1" \
|
2005-08-30 01:07:44 +03:00
|
|
|
CFLAGS="$(TARGET_CFLAGS) $(CFLAGS_LARGEFILE)" \
|
2005-04-14 09:11:36 +03:00
|
|
|
./configure \
|
|
|
|
--prefix=/usr \
|
|
|
|
--shared \
|
|
|
|
);
|
2006-05-10 22:06:22 +03:00
|
|
|
endef
|
2005-03-06 05:34:52 +02:00
|
|
|
|
2006-05-10 22:06:22 +03:00
|
|
|
define Build/Compile
|
2005-03-06 05:34:52 +02:00
|
|
|
$(MAKE) -C $(PKG_BUILD_DIR) \
|
2005-04-14 09:11:36 +03:00
|
|
|
$(TARGET_CONFIGURE_OPTS) \
|
|
|
|
CFLAGS="$(TARGET_CFLAGS) $(CFLAGS_LARGEFILE)" \
|
|
|
|
libz.a libz.so
|
2005-05-13 07:26:17 +03:00
|
|
|
mkdir -p $(PKG_INSTALL_DIR)
|
2005-03-06 05:34:52 +02:00
|
|
|
$(MAKE) -C $(PKG_BUILD_DIR) \
|
2005-05-13 07:26:17 +03:00
|
|
|
DESTDIR="$(PKG_INSTALL_DIR)" \
|
2005-04-14 09:11:36 +03:00
|
|
|
install
|
2006-05-10 22:06:22 +03:00
|
|
|
endef
|
2005-03-06 05:34:52 +02:00
|
|
|
|
2006-05-29 04:29:46 +03:00
|
|
|
define Build/InstallDev
|
2005-05-13 07:26:17 +03:00
|
|
|
mkdir -p $(STAGING_DIR)/usr/include
|
2006-06-18 21:30:40 +03:00
|
|
|
$(CP) $(PKG_INSTALL_DIR)/usr/include/z{conf,lib}.h \
|
2006-05-29 04:29:46 +03:00
|
|
|
$(STAGING_DIR)/usr/include/
|
2005-05-13 07:26:17 +03:00
|
|
|
mkdir -p $(STAGING_DIR)/usr/lib
|
2006-06-18 21:30:40 +03:00
|
|
|
$(CP) $(PKG_INSTALL_DIR)/usr/lib/libz.{a,so*} \
|
2006-05-29 04:29:46 +03:00
|
|
|
$(STAGING_DIR)/usr/lib/
|
|
|
|
endef
|
2005-05-13 07:26:17 +03:00
|
|
|
|
2006-05-29 04:29:46 +03:00
|
|
|
define Build/UninstallDev
|
2006-06-18 21:30:40 +03:00
|
|
|
rm -rf $(STAGING_DIR)/usr/include/z{conf,lib}.h \
|
|
|
|
$(STAGING_DIR)/usr/lib/libz.{a,so*}
|
|
|
|
endef
|
|
|
|
|
|
|
|
define Package/zlib/install
|
|
|
|
install -m0755 -d $(1)/usr/lib
|
|
|
|
$(CP) $(PKG_INSTALL_DIR)/usr/lib/libz.so.* $(1)/usr/lib/
|
2006-05-29 04:29:46 +03:00
|
|
|
endef
|
2006-05-10 22:16:02 +03:00
|
|
|
|
|
|
|
$(eval $(call BuildPackage,zlib))
|