[v5,3/5] package/netopeer2-keystored: add package
diff mbox series

Message ID 20191028090329.25432-4-heiko.thiery@gmail.com
State New
Headers show
Series
  • Add netopeer2 package (and dependencies)
Related show

Commit Message

Heiko Thiery Oct. 28, 2019, 9:03 a.m. UTC
From: Heiko Thiery <heiko.thiery@kontron.com>

netopeer2 keystored plugin.

Signed-off-by: Heiko Thiery <heiko.thiery@kontron.com>
---
 DEVELOPERS                                    |  1 +
 package/Config.in                             |  1 +
 package/netopeer2-keystored/Config.in         | 17 ++++++++++
 .../netopeer2-keystored.hash                  |  2 ++
 .../netopeer2-keystored.mk                    | 31 +++++++++++++++++++
 5 files changed, 52 insertions(+)
 create mode 100644 package/netopeer2-keystored/Config.in
 create mode 100644 package/netopeer2-keystored/netopeer2-keystored.hash
 create mode 100644 package/netopeer2-keystored/netopeer2-keystored.mk

Patch
diff mbox series

diff --git a/DEVELOPERS b/DEVELOPERS
index 6f6b768e0d..0f0089dfaf 100644
--- a/DEVELOPERS
+++ b/DEVELOPERS
@@ -1048,6 +1048,7 @@  F:	package/python-sip/
 N:	Heiko Thiery <heiko.thiery@gmail.com>
 F:	package/libnetconf2/
 F:	package/libyang/
+F:	package/netopeer2-keystored/
 F:	package/sysrepo/
 
 N:	Henrique Camargo <henrique@henriquecamargo.com>
diff --git a/package/Config.in b/package/Config.in
index ae1c5013b6..1fcd7dd2d7 100644
--- a/package/Config.in
+++ b/package/Config.in
@@ -1659,6 +1659,7 @@  menu "Networking"
 	source "package/mongoose/Config.in"
 	source "package/nanomsg/Config.in"
 	source "package/neon/Config.in"
+	source "package/netopeer2-keystored/Config.in"
 	source "package/nghttp2/Config.in"
 	source "package/norm/Config.in"
 	source "package/nss-mdns/Config.in"
diff --git a/package/netopeer2-keystored/Config.in b/package/netopeer2-keystored/Config.in
new file mode 100644
index 0000000000..d23ec2f1b9
--- /dev/null
+++ b/package/netopeer2-keystored/Config.in
@@ -0,0 +1,17 @@ 
+config BR2_PACKAGE_NETOPEER2_KEYSTORED
+	bool "netopeer2-keystored"
+	depends on BR2_TOOLCHAIN_HAS_THREADS
+	depends on !BR2_STATIC_LIBS
+	select BR2_PACKAGE_LIBYANG
+	select BR2_PACKAGE_OPENSSL
+	select BR2_PACKAGE_SYSREPO
+	help
+	  Netopeer2 is a set of tools implementing network
+	  configuration tools based on the NETCONF Protocol.
+
+	  This is the keystored sysrepo plugin.
+
+	  https://github.com/CESNET/Netopeer2
+
+comment "needs a toolchain w/ threads, dynamic libraray"
+	depends on BR2_STATIC_LIBS || !BR2_TOOLCHAIN_HAS_THREADS
diff --git a/package/netopeer2-keystored/netopeer2-keystored.hash b/package/netopeer2-keystored/netopeer2-keystored.hash
new file mode 100644
index 0000000000..2ad5db9260
--- /dev/null
+++ b/package/netopeer2-keystored/netopeer2-keystored.hash
@@ -0,0 +1,2 @@ 
+sha256 59688271be4fecbbee671fc7eb3dc0538b13b4baab53e923e26eaeb33e6f7ec0  netopeer2-0.7-r2.tar.gz
+sha256 932b75a8610a5c58e0fe0f70f8e4ebbcf3a2392acc16a88e95aebcdbdb9245e0  LICENSE
diff --git a/package/netopeer2-keystored/netopeer2-keystored.mk b/package/netopeer2-keystored/netopeer2-keystored.mk
new file mode 100644
index 0000000000..65a4c799b7
--- /dev/null
+++ b/package/netopeer2-keystored/netopeer2-keystored.mk
@@ -0,0 +1,31 @@ 
+################################################################################
+#
+# netopeer2-keystored
+#
+################################################################################
+
+NETOPEER2_KEYSTORED_VERSION = 0.7-r2
+NETOPEER2_KEYSTORED_SOURCE = netopeer2-$(NETOPEER2_KEYSTORED_VERSION).tar.gz
+NETOPEER2_KEYSTORED_SITE = $(call github,CESNET,Netopeer2,v$(NETOPEER2_KEYSTORED_VERSION))
+NETOPEER2_KEYSTORED_DL_SUBDIR = netopeer2
+NETOPEER2_KEYSTORED_SUBDIR = keystored
+NETOPEER2_KEYSTORED_LICENSE = BSD-3-Clause
+NETOPEER2_KEYSTORED_LICENSE_FILES = LICENSE
+NETOPEER2_KEYSTORED_DEPENDENCIES = host-sysrepo sysrepo
+
+NETOPEER2_KEYSTORED_CONF_OPTS = \
+	-DKEYSTORED_DEFER_SSH_KEY=ON \
+	-DSSH_KEY_INSTALL=ON \
+	-DMODEL_INSTALL=ON \
+	-DSYSREPOCTL_EXECUTABLE=$(HOST_DIR)/bin/sysrepoctl \
+	-DSYSREPOCFG_EXECUTABLE=$(HOST_DIR)/bin/sysrepocfg
+
+define NETOPEER2_KEYSTORED_PERMISSIONS
+	/etc/sysrepo/data/ietf-keystore.persist f 600 0 0 - - - - -
+	/etc/sysrepo/data/ietf-keystore.running f 600 0 0 - - - - -
+	/etc/sysrepo/data/ietf-keystore.running.lock f 600 0 0 - - - - -
+	/etc/sysrepo/data/ietf-keystore.startup f 600 0 0 - - - - -
+	/etc/sysrepo/data/ietf-keystore.startup.lock f 600 0 0 - - - - -
+endef
+
+$(eval $(cmake-package))