Makefile 1.8 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970
  1. include $(TOPDIR)/rules.mk
  2. PKG_NAME:=ustream-ssl
  3. PKG_RELEASE:=1
  4. PKG_SOURCE_PROTO:=git
  5. PKG_SOURCE_URL=$(PROJECT_GIT)/ustream-ssl.git
  6. PKG_SOURCE_DATE:=2020-03-13
  7. PKG_SOURCE_VERSION:=40b563b1ea89dabb2b6cd90644908134a0c8eff2
  8. PKG_MIRROR_HASH:=db562c9919b4045c7b735c935b0a93983686b827ec4d537e8aa875c7e6df21a1
  9. CMAKE_INSTALL:=1
  10. PKG_LICENSE:=ISC
  11. PKG_LICENSE_FILES:=
  12. PKG_MAINTAINER:=Felix Fietkau <nbd@nbd.name>
  13. include $(INCLUDE_DIR)/package.mk
  14. include $(INCLUDE_DIR)/cmake.mk
  15. define Package/libustream/default
  16. SECTION:=libs
  17. CATEGORY:=Libraries
  18. TITLE:=ustream SSL Library
  19. DEPENDS:=+libubox
  20. ABI_VERSION:=20150806
  21. endef
  22. define Package/libustream-openssl
  23. $(Package/libustream/default)
  24. TITLE += (openssl)
  25. DEPENDS += +PACKAGE_libustream-openssl:libopenssl
  26. VARIANT:=openssl
  27. endef
  28. define Package/libustream-wolfssl
  29. $(Package/libustream/default)
  30. TITLE += (wolfssl)
  31. DEPENDS += +PACKAGE_libustream-wolfssl:libwolfssl
  32. VARIANT:=wolfssl
  33. endef
  34. define Package/libustream-mbedtls
  35. $(Package/libustream/default)
  36. TITLE += (mbedtls)
  37. DEPENDS += +libmbedtls
  38. VARIANT:=mbedtls
  39. DEFAULT_VARIANT:=1
  40. endef
  41. ifeq ($(BUILD_VARIANT),wolfssl)
  42. TARGET_CFLAGS += -I$(STAGING_DIR)/usr/include/wolfssl
  43. CMAKE_OPTIONS += -DWOLFSSL=on
  44. endif
  45. ifeq ($(BUILD_VARIANT),mbedtls)
  46. CMAKE_OPTIONS += -DMBEDTLS=on
  47. endif
  48. define Package/libustream/default/install
  49. $(INSTALL_DIR) $(1)/lib/
  50. $(INSTALL_DATA) $(PKG_INSTALL_DIR)/usr/lib/libustream-ssl.so $(1)/lib/
  51. endef
  52. Package/libustream-openssl/install = $(Package/libustream/default/install)
  53. Package/libustream-wolfssl/install = $(Package/libustream/default/install)
  54. Package/libustream-mbedtls/install = $(Package/libustream/default/install)
  55. $(eval $(call BuildPackage,libustream-mbedtls))
  56. $(eval $(call BuildPackage,libustream-wolfssl))
  57. $(eval $(call BuildPackage,libustream-openssl))