Makefile 2.0 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182
  1. #
  2. # Copyright (C) 2011-2013 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:=polarssl
  9. PKG_VERSION:=1.2.9
  10. PKG_RELEASE:=1
  11. PKG_USE_MIPS16:=0
  12. PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-gpl.tgz
  13. PKG_SOURCE_URL:=https://polarssl.org/code/releases
  14. PKG_MD5SUM:=3d8e01537e747d7997993c70f2e108db
  15. include $(INCLUDE_DIR)/package.mk
  16. include $(INCLUDE_DIR)/cmake.mk
  17. define Package/polarssl/Default
  18. SUBMENU:=SSL
  19. TITLE:=Embedded SSL
  20. URL:=http://polarssl.org/
  21. endef
  22. define Package/polarssl/Default/description
  23. The aim of the PolarSSL project is to provide a quality, open-source
  24. cryptographic library written in C and targeted at embedded systems.
  25. endef
  26. define Package/libpolarssl
  27. $(call Package/polarssl/Default)
  28. SECTION:=libs
  29. CATEGORY:=Libraries
  30. TITLE+= (library)
  31. endef
  32. define Package/libpolarssl/description
  33. $(call Package/polarssl/Default/description)
  34. This package contains the PolarSSL library.
  35. endef
  36. define Package/polarssl-progs
  37. $(call Package/polarssl/Default)
  38. SECTION:=utils
  39. CATEGORY:=Utilities
  40. DEPENDS:=+libpolarssl
  41. TITLE+= (programs)
  42. endef
  43. define Package/polarssl-progs/description
  44. $(call Package/polarssl/Default/description)
  45. This package contains the PolarSSL programs.
  46. endef
  47. PKG_INSTALL:=1
  48. CMAKE_OPTIONS += \
  49. -DCMAKE_BUILD_TYPE:String="Release" \
  50. -DUSE_SHARED_POLARSSL_LIBRARY:Bool=ON \
  51. define Build/InstallDev
  52. $(INSTALL_DIR) $(1)/usr/include
  53. $(CP) $(PKG_INSTALL_DIR)/usr/include/polarssl $(1)/usr/include/
  54. $(INSTALL_DIR) $(1)/usr/lib
  55. $(CP) $(PKG_INSTALL_DIR)/usr/lib/libpolarssl.so* $(1)/usr/lib/
  56. endef
  57. define Package/libpolarssl/install
  58. $(INSTALL_DIR) $(1)/usr/lib
  59. $(CP) $(PKG_INSTALL_DIR)/usr/lib/libpolarssl.so* $(1)/usr/lib/
  60. endef
  61. define Package/polarssl-progs/install
  62. $(INSTALL_DIR) $(1)/usr/bin
  63. $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/* $(1)/usr/bin/
  64. endef
  65. $(eval $(call BuildPackage,libpolarssl))
  66. $(eval $(call BuildPackage,polarssl-progs))