You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

83 lines
2.3 KiB

  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. include $(TOPDIR)/rules.mk
  8. PKG_NAME:=freetype
  9. PKG_VERSION:=2.9.1
  10. PKG_RELEASE:=1
  11. PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
  12. PKG_SOURCE_URL:=@SF/freetype
  13. PKG_HASH:=db8d87ea720ea9d5edc5388fc7a0497bb11ba9fe972245e0f7f4c7e8b1e1e84d
  14. PKG_LICENSE:=FTL GPL-2.0 MIT ZLIB
  15. PKG_LICENSE_FILES:=docs/LICENSE.TXT docs/FTL.TXT docs/GPLv2.TXT src/bdf/README src/pcf/README src/gzip/zlib.h
  16. PKG_CPE_ID:=cpe:/a:freetype:freetype2
  17. PKG_MAINTAINER:=Val Kulkov <val.kulkov@gmail.com>
  18. PKG_FIXUP:=autoreconf
  19. PKG_LIBTOOL_PATHS:=builds/unix
  20. include $(INCLUDE_DIR)/host-build.mk
  21. include $(INCLUDE_DIR)/package.mk
  22. define Package/libfreetype
  23. SECTION:=libs
  24. CATEGORY:=Libraries
  25. TITLE:=A free, high-quality and portable font engine
  26. URL:=http://www.freetype.org/
  27. DEPENDS:=+zlib +libpng
  28. endef
  29. define Package/libfreetype/description
  30. The FreeType project is a team of volunteers who develop free,
  31. portable and high-quality software solutions for digital typography.
  32. They specifically target embedded systems and focus on bringing small,
  33. efficient and ubiquitous products.
  34. endef
  35. TARGET_CFLAGS += $(FPIC)
  36. CONFIGURE_ARGS += \
  37. --enable-freetype-config \
  38. --enable-shared \
  39. --enable-static \
  40. --with-bzip2=no \
  41. --with-zlib=yes \
  42. --with-png=yes
  43. define Build/Compile
  44. $(MAKE) -C $(PKG_BUILD_DIR) DESTDIR="$(PKG_INSTALL_DIR)" all install
  45. endef
  46. define Build/InstallDev
  47. $(INSTALL_DIR) $(1)/bin
  48. $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/freetype-config $(1)/bin/
  49. $(INSTALL_DIR) $(2)/bin
  50. $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/freetype-config $(2)/bin/
  51. $(INSTALL_DIR) $(1)/usr/include
  52. $(CP) $(PKG_INSTALL_DIR)/usr/include/freetype2 $(1)/usr/include/
  53. $(INSTALL_DIR) $(1)/usr/lib
  54. $(CP) $(PKG_INSTALL_DIR)/usr/lib/libfreetype.{a,so*} $(1)/usr/lib/
  55. $(INSTALL_DIR) $(1)/usr/lib/pkgconfig
  56. $(CP) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/freetype2.pc $(1)/usr/lib/pkgconfig/
  57. $(SED) \
  58. 's,/usr/include,$$$${prefix}/include,g; \
  59. s,/usr/lib,$$$${exec_prefix}/lib,g' \
  60. $(1)/usr/lib/pkgconfig/freetype2.pc
  61. endef
  62. define Package/libfreetype/install
  63. $(INSTALL_DIR) $(1)/usr/lib
  64. $(CP) $(PKG_INSTALL_DIR)/usr/lib/libfreetype.so.* $(1)/usr/lib/
  65. endef
  66. $(eval $(call HostBuild))
  67. $(eval $(call BuildPackage,libfreetype))