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.

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