prometheus-node-exporter-lua: add dawn exporter
[feed/packages.git] / libs / freetype / Makefile
1 #
2 # Copyright (C) 2006-2015 OpenWrt.org
3 #
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
6 #
7
8 include $(TOPDIR)/rules.mk
9
10 PKG_NAME:=freetype
11 PKG_VERSION:=2.10.1
12 PKG_RELEASE:=1
13
14 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz
15 PKG_SOURCE_URL:=@SF/freetype
16 PKG_HASH:=16dbfa488a21fe827dc27eaf708f42f7aa3bb997d745d31a19781628c36ba26f
17
18 PKG_LICENSE:=FTL GPL-2.0-only MIT ZLIB GPL-3.0-or-later
19 PKG_LICENSE_FILES:=docs/LICENSE.TXT docs/FTL.TXT docs/GPLv2.TXT src/bdf/README src/pcf/README src/gzip/zlib.h builds/unix/config.sub builds/unix/config.guess builds/unix/libtool
20 PKG_CPE_ID:=cpe:/a:freetype:freetype2
21 PKG_MAINTAINER:=Val Kulkov <val.kulkov@gmail.com>
22
23 PKG_FIXUP:=autoreconf
24 PKG_LIBTOOL_PATHS:=builds/unix
25
26 include $(INCLUDE_DIR)/host-build.mk
27 include $(INCLUDE_DIR)/package.mk
28
29 define Package/libfreetype
30 SECTION:=libs
31 CATEGORY:=Libraries
32 TITLE:=A free, high-quality and portable font engine
33 URL:=http://www.freetype.org/
34 DEPENDS:=+zlib +libpng
35 endef
36
37 define Package/libfreetype/description
38 The FreeType project is a team of volunteers who develop free,
39 portable and high-quality software solutions for digital typography.
40 They specifically target embedded systems and focus on bringing small,
41 efficient and ubiquitous products.
42 endef
43
44 TARGET_CFLAGS += $(FPIC)
45
46 CONFIGURE_ARGS += \
47 --enable-freetype-config \
48 --enable-shared \
49 --enable-static \
50 --with-bzip2=no \
51 --with-zlib=yes \
52 --with-png=yes
53
54 HOST_CONFIGURE_ARGS+= \
55 --with-bzip2=no \
56 --with-zlib=no \
57 --with-png=no
58
59 define Build/Compile
60 $(MAKE) -C $(PKG_BUILD_DIR) DESTDIR="$(PKG_INSTALL_DIR)" all install
61 endef
62
63 define Build/InstallDev
64 $(INSTALL_DIR) $(1)/bin
65 $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/freetype-config $(1)/bin/
66 $(INSTALL_DIR) $(2)/bin
67 $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/freetype-config $(2)/bin/
68 $(INSTALL_DIR) $(1)/usr/include
69 $(CP) $(PKG_INSTALL_DIR)/usr/include/freetype2 $(1)/usr/include/
70 $(INSTALL_DIR) $(1)/usr/lib
71 $(CP) $(PKG_INSTALL_DIR)/usr/lib/libfreetype.{a,so*} $(1)/usr/lib/
72 $(INSTALL_DIR) $(1)/usr/lib/pkgconfig
73 $(CP) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/freetype2.pc $(1)/usr/lib/pkgconfig/
74
75 $(SED) \
76 's,/usr/include,$$$${prefix}/include,g; \
77 s,/usr/lib,$$$${exec_prefix}/lib,g' \
78 $(1)/usr/lib/pkgconfig/freetype2.pc
79 endef
80
81
82 define Package/libfreetype/install
83 $(INSTALL_DIR) $(1)/usr/lib
84 $(CP) $(PKG_INSTALL_DIR)/usr/lib/libfreetype.so.* $(1)/usr/lib/
85 endef
86
87 $(eval $(call HostBuild))
88 $(eval $(call BuildPackage,libfreetype))