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.
9 include $(TOPDIR)/rules.mk
15 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
16 PKG_SOURCE_URL:= http://cairographics.org/releases/
19 include $(INCLUDE_DIR)/package.mk
25 TITLE:=2D graphics library with support for multiple output devices
26 DEPENDS:=+xorg-server-essentials +fontconfig +libpng
29 define Build/Configure
30 (cd $(PKG_BUILD_DIR)/$(CONFIGURE_PATH); \
31 if [ -x $(CONFIGURE_CMD) ]; then \
32 $(CP) $(SCRIPT_DIR)/config.{guess,sub} $(PKG_BUILD_DIR)/ && \
35 $(CONFIGURE_ARGS_XTRA) \
42 $(MAKE) -C $(PKG_BUILD_DIR)
43 $(MAKE) -C $(PKG_BUILD_DIR)/ install DESTDIR=$(PKG_INSTALL_DIR)
46 define Build/InstallDev
48 $(CP) $(PKG_INSTALL_DIR)/* $(1)/
49 $(SED) "s,-L/usr/local/lib,,g" $(1)/usr/lib/libcairo.la
50 $(SED) "s,/usr/lib/libfontconfig.la,$(STAGING_DIR)/usr/lib/libfontconfig.la,g" $(1)/usr/lib/libcairo.la
51 $(SED) "s,$(STAGING_DIR)$(STAGING_DIR),$(STAGING_DIR),g" $(1)/usr/lib/libcairo.la
54 define Package/cairo/Install
55 $(INSTALL_DIR) $(1)/usr/lib
56 $(CP) $(PKG_INSTALL_DIR)/usr/lib/lib*so* $(1)/usr/lib/
59 $(eval $(call BuildPackage,cairo))