2 # Copyright (C) 2008-2009 OpenWrt.org
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
8 include $(TOPDIR)/rules.mk
14 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
15 PKG_SOURCE_URL:=http://cairographics.org/releases/
16 PKG_MD5SUM:=4e64139ef6f668df24450f3b81dd0771
19 include $(INCLUDE_DIR)/package.mk
27 TITLE:=Multi-platform 2D graphics library
28 DEPENDS:=+fontconfig +libpng +libexpat +pixman
31 define Package/cairo/description
32 Cairo is a 2D graphics library. The cairo API provides operations similar
33 to the drawing operators of PostScript and PDF. Operations in cairo
34 include stroking and filling cubic Bézier splines, transforming and
35 compositing translucent images, and antialiased text rendering. All
36 drawing operations can be transformed by any affine transformation
37 (scale, rotation, shear, etc.).
40 CONFIGURE_VARS+=FONTCONFIG_LIBS="-lfreetype -lfontconfig -lz -lexpat"
41 CONFIGURE_ARGS+=--enable-freetype=yes
42 TARGET_CFLAGS+=$(TARGET_LDFLAGS)
44 define Build/InstallDev
45 $(INSTALL_DIR) $(1)/usr/lib/
46 $(CP) $(PKG_INSTALL_DIR)/usr/lib/*.{so*,a,la} $(1)/usr/lib/
47 $(INSTALL_DIR) $(1)/usr/lib/pkgconfig/
48 $(INSTALL_DATA) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/* $(1)/usr/lib/pkgconfig/
49 $(INSTALL_DIR) $(1)/usr/include/cairo/
50 $(INSTALL_DATA) $(PKG_INSTALL_DIR)/usr/include/cairo/* $(1)/usr/include/cairo/
53 define Package/cairo/install
54 $(INSTALL_DIR) $(1)/usr/lib/
55 $(CP) $(PKG_INSTALL_DIR)/usr/lib/*.so* $(1)/usr/lib/
58 $(eval $(call BuildPackage,cairo))