ocserv: add otp config option
authorThlv Alivs <zgmzzzz18@gmail.com>
Sat, 20 May 2023 04:21:57 +0000 (12:21 +0800)
committerTianling Shen <cnsztl@gmail.com>
Sun, 21 May 2023 11:42:53 +0000 (19:42 +0800)
and also fix build error:
Package ocserv is missing dependencies for the following libraries:
liboath.so.0

Signed-off-by: Thlv Alivs <zgmzzzz18@gmail.com>
net/ocserv/Config.in
net/ocserv/Makefile

index cf86bef172f907d2cd443c121ba6e3f7860a62c1..36533dfae1005ed8328c45aeb6e6cb60f11683a2 100644 (file)
@@ -16,6 +16,10 @@ config OCSERV_RADIUS
        bool "enable radius authentication"
        default n
 
+config OCSERV_LIBOATH
+       bool "enable OTP"
+       default n
+
 config OCSERV_PROTOBUF
        bool "use external libprotobuf"
        default y
index 7db36a6e1e4605fcbe85391b501a42f80e9997b4..0bbe4f3b2b127128f638eabe2af566eef43cf42f 100644 (file)
@@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk
 
 PKG_NAME:=ocserv
 PKG_VERSION:=1.1.7
-PKG_RELEASE:=1
+PKG_RELEASE:=2
 PKG_BUILD_FLAGS:=no-mips16
 
 PKG_BUILD_DIR :=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION)
@@ -39,7 +39,7 @@ define Package/ocserv
   TITLE:=OpenConnect VPN server
   URL:=http://www.infradead.org/ocserv/
   MAINTAINER:=Nikos Mavrogiannopoulos <n.mavrogiannopoulos@gmail.com>
-  DEPENDS:= +OCSERV_RADIUS:libradcli +OCSERV_HTTP_PARSER:libhttp-parser +OCSERV_SECCOMP:libseccomp +libgnutls +certtool +libncurses +libreadline +OCSERV_PAM:libpam +OCSERV_PROTOBUF:libprotobuf-c +libev +kmod-tun
+  DEPENDS:= +OCSERV_RADIUS:libradcli +OCSERV_HTTP_PARSER:libhttp-parser +OCSERV_SECCOMP:libseccomp +libgnutls +certtool +libncurses +libreadline +OCSERV_PAM:libpam +OCSERV_PROTOBUF:libprotobuf-c +OCSERV_LIBOATH:liboath +libev +kmod-tun
   USERID:=ocserv=72:ocserv=72
 endef
 
@@ -89,6 +89,10 @@ ifneq ($(CONFIG_OCSERV_HTTP_PARSER),y)
 CONFIGURE_ARGS += --without-http-parser
 endif
 
+ifndef CONFIG_OCSERV_LIBOATH
+CONFIGURE_ARGS += --without-liboath
+endif
+
 define Package/ocserv/conffiles
 /etc/config/ocserv
 endef