2009-06-17 15:22:37 +00:00
|
|
|
#
|
2011-11-03 21:06:18 +00:00
|
|
|
# Copyright (C) 2006-2011 OpenWrt.org
|
2006-07-22 22:29:01 +00:00
|
|
|
#
|
|
|
|
# This is free software, licensed under the GNU General Public License v2.
|
|
|
|
# See /LICENSE for more information.
|
|
|
|
#
|
|
|
|
|
|
|
|
include $(TOPDIR)/rules.mk
|
|
|
|
|
|
|
|
PKG_NAME:=libpng
|
2011-11-03 21:06:18 +00:00
|
|
|
PKG_VERSION:=1.2.46
|
2006-07-22 22:29:01 +00:00
|
|
|
PKG_RELEASE:=1
|
|
|
|
|
2008-06-20 13:18:33 +00:00
|
|
|
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
|
2006-07-22 22:29:01 +00:00
|
|
|
PKG_SOURCE_URL:=@SF/libpng
|
2011-11-03 21:06:18 +00:00
|
|
|
PKG_MD5SUM:=e8b43dc78ef95b3949af7f961d76874b
|
2006-07-22 22:29:01 +00:00
|
|
|
|
2010-02-18 13:10:21 +00:00
|
|
|
PKG_FIXUP:=libtool
|
|
|
|
PKG_INSTALL:=1
|
2010-09-07 10:04:42 +00:00
|
|
|
PKG_BUILD_PARALLEL:=1
|
2009-05-29 12:01:08 +00:00
|
|
|
|
2009-02-28 20:50:40 +00:00
|
|
|
include $(INCLUDE_DIR)/host-build.mk
|
2006-07-22 22:29:01 +00:00
|
|
|
include $(INCLUDE_DIR)/package.mk
|
|
|
|
|
|
|
|
define Package/libpng
|
|
|
|
SECTION:=libs
|
|
|
|
CATEGORY:=Libraries
|
|
|
|
DEPENDS:=+zlib
|
|
|
|
TITLE:=A PNG format files handling library
|
|
|
|
URL:=http://www.libpng.org/pub/png/libpng.html
|
|
|
|
endef
|
|
|
|
|
2010-07-13 03:11:20 +00:00
|
|
|
TARGET_CFLAGS += $(FPIC)
|
|
|
|
|
|
|
|
CONFIGURE_ARGS += \
|
|
|
|
--enable-shared \
|
|
|
|
--enable-static \
|
2006-07-22 22:29:01 +00:00
|
|
|
|
|
|
|
define Build/InstallDev
|
2010-07-13 03:11:20 +00:00
|
|
|
$(INSTALL_DIR) $(1)/usr/bin
|
|
|
|
$(CP) $(PKG_INSTALL_DIR)/usr/bin/libpng{,12}-config $(1)/usr/bin/
|
|
|
|
$(SED) \
|
|
|
|
's,^\(prefix\|exec_prefix\)=.*,\1=$(STAGING_DIR)/usr,g' \
|
|
|
|
$(1)/usr/bin/libpng{,12}-config
|
2009-12-18 11:06:19 +00:00
|
|
|
$(INSTALL_DIR) $(1)/usr/include
|
2007-10-07 03:20:26 +00:00
|
|
|
$(CP) $(PKG_INSTALL_DIR)/usr/include/png{,conf}.h $(1)/usr/include/
|
2008-06-20 13:18:33 +00:00
|
|
|
$(CP) $(PKG_INSTALL_DIR)/usr/include/libpng12 $(1)/usr/include/
|
2009-12-18 11:06:19 +00:00
|
|
|
$(INSTALL_DIR) $(1)/usr/lib
|
2010-07-13 03:11:20 +00:00
|
|
|
$(CP) $(PKG_INSTALL_DIR)/usr/lib/libpng{,12}.{a,la,so*} $(1)/usr/lib/
|
2009-12-18 11:06:19 +00:00
|
|
|
$(INSTALL_DIR) $(1)/usr/lib/pkgconfig
|
2007-10-07 03:20:26 +00:00
|
|
|
$(CP) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/libpng{,12}.pc $(1)/usr/lib/pkgconfig/
|
2010-07-13 03:11:20 +00:00
|
|
|
$(INSTALL_DIR) $(2)/bin
|
|
|
|
for f in libpng{,12}-config; do \
|
|
|
|
$(LN) ../../usr/bin/$$$$f $(2)/bin/ ; \
|
|
|
|
done
|
2006-07-22 22:29:01 +00:00
|
|
|
endef
|
|
|
|
|
2006-10-28 22:43:08 +00:00
|
|
|
define Package/libpng/install
|
2006-11-23 00:29:07 +00:00
|
|
|
$(INSTALL_DIR) $(1)/usr/lib
|
2006-10-28 22:43:08 +00:00
|
|
|
$(CP) $(PKG_INSTALL_DIR)/usr/lib/libpng{,12}.so.* $(1)/usr/lib/
|
|
|
|
endef
|
|
|
|
|
2009-02-28 20:50:40 +00:00
|
|
|
$(eval $(call HostBuild))
|
2006-07-22 22:29:01 +00:00
|
|
|
$(eval $(call BuildPackage,libpng))
|