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.

76 lines
2.0 KiB

  1. #
  2. # Copyright (C) 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:=libradcli
  9. PKG_VERSION:=1.2.11
  10. PKG_RELEASE:=1
  11. PKG_SOURCE:=radcli-$(PKG_VERSION).tar.gz
  12. PKG_SOURCE_URL:=https://github.com/radcli/radcli/releases/download/$(PKG_VERSION)
  13. PKG_HASH:=b6210e4c7deae235bb8c4e9df20c4f82c8bc2bda6d6214d50c5667660ab38548
  14. PKG_BUILD_DIR:=$(BUILD_DIR)/radcli-$(PKG_VERSION)
  15. PKG_INSTALL:=1
  16. PKG_BUILD_PARALLEL:=1
  17. include $(INCLUDE_DIR)/package.mk
  18. define Package/libradcli
  19. SECTION:=libs
  20. CATEGORY:=Libraries
  21. TITLE:=A library for radius clients
  22. URL:=https://radcli.github.io/radcli
  23. MAINTAINER:=Nikos Mavrogiannopoulos <nmav@gnutls.org>
  24. DEPENDS:= +RADCLI_TLS:libgnutls +libnettle
  25. endef
  26. define Package/libradcli/decription
  27. The radcli library is a library for writing RADIUS Clients. The library's
  28. approach is to allow writing RADIUS-aware application in less than 50 lines
  29. of C code. It was based originally on freeradius-client and is source
  30. compatible with it.
  31. endef
  32. CONFIGURE_ARGS+= \
  33. --enable-legacy-compat
  34. ifneq ($(CONFIG_RADCLI_TLS),y)
  35. CONFIGURE_ARGS += --without-tls
  36. endif
  37. define Build/InstallDev
  38. $(INSTALL_DIR) $(1)/usr/include/radcli
  39. $(CP) \
  40. $(PKG_INSTALL_DIR)/usr/include/radcli/radcli.h \
  41. $(PKG_INSTALL_DIR)/usr/include/radcli/version.h \
  42. $(1)/usr/include/radcli
  43. $(CP) \
  44. $(PKG_INSTALL_DIR)/usr/include/freeradius-client.h \
  45. $(1)/usr/include/
  46. $(INSTALL_DIR) $(1)/usr/lib
  47. $(CP) \
  48. $(PKG_INSTALL_DIR)/usr/lib/libradcli.so* \
  49. $(PKG_INSTALL_DIR)/usr/lib/libfreeradius-client.so \
  50. $(1)/usr/lib/
  51. endef
  52. define Package/libradcli/conffiles
  53. /etc/radcli/radiusclient.conf
  54. endef
  55. define Package/libradcli/install
  56. $(INSTALL_DIR) $(1)/etc/radcli
  57. $(INSTALL_CONF) $(PKG_BUILD_DIR)/etc/radiusclient.conf $(1)/etc/radcli/
  58. $(INSTALL_DIR) $(1)/usr/lib
  59. $(CP) \
  60. $(PKG_INSTALL_DIR)/usr/lib/libradcli.so.* \
  61. $(1)/usr/lib/
  62. endef
  63. $(eval $(call BuildPackage,libradcli))