Makefile 1.1 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950
  1. # Copyright (C) 2020 Paul Spooren <mail@aparcar.org>
  2. #
  3. # SPDX-License-Identifier: GPL-2.0-or-later
  4. include $(TOPDIR)/rules.mk
  5. PKG_NAME:=px5g-wolfssl
  6. PKG_RELEASE:=9
  7. PKG_LICENSE:=GPL-2.0-or-later
  8. PKG_BUILD_FLAGS:=no-mips16
  9. PKG_MAINTAINER:=Paul Spooren <mail@aparcar.org>
  10. PKG_CONFIG_DEPENDS:=CONFIG_WOLFSSL_ALT_NAMES
  11. include $(INCLUDE_DIR)/package.mk
  12. define Package/px5g-wolfssl
  13. SECTION:=utils
  14. CATEGORY:=Utilities
  15. SUBMENU:=Encryption
  16. TITLE:=X.509 certificate generator (using WolfSSL)
  17. DEPENDS:=+libwolfssl
  18. PROVIDES:=px5g
  19. VARIANT:=wolfssl
  20. endef
  21. define Package/px5g-wolfssl/description
  22. Px5g is a tiny X.509 certificate generator.
  23. It suitable to create key files and certificates in DER
  24. and PEM format for use with stunnel, uhttpd and others.
  25. endef
  26. TARGET_LDFLAGS += -lwolfssl
  27. TARGET_CFLAGS += -Wl,--gc-sections
  28. define Build/Compile
  29. $(TARGET_CC) $(TARGET_CPPFLAGS) $(TARGET_CFLAGS) \
  30. -o $(PKG_BUILD_DIR)/px5g px5g-wolfssl.c $(TARGET_LDFLAGS)
  31. endef
  32. define Package/px5g-wolfssl/install
  33. $(INSTALL_DIR) $(1)/usr/sbin
  34. $(INSTALL_BIN) $(PKG_BUILD_DIR)/px5g $(1)/usr/sbin/px5g
  35. endef
  36. $(eval $(call BuildPackage,px5g-wolfssl))