From b8231dc570ecc914b52d9e3f8fc9c009280d1791 Mon Sep 17 00:00:00 2001
From: Vivek Kumar Dutta <vivek.dutta@iopsys.eu>
Date: Tue, 18 Apr 2023 18:46:45 +0530
Subject: [PATCH] Align with bbfdm

---
 docs/.pages                       |  2 +-
 docs/api/.pages                   |  2 +-
 docs/api/ubus/.pages              |  1 +
 docs/api/uci/.pages               |  2 +-
 docs/arch/.pages                  |  1 +
 docs/guide/.pages                 |  1 +
 docs/index.md                     |  1 +
 docs/spec/.pages                  |  1 +
 gitlab-ci/install-dependencies.sh |  4 ++--
 gitlab-ci/shared.sh               | 18 ++++++++++--------
 mkdocs.yml                        |  2 +-
 src/datamodel.c                   |  4 ++--
 12 files changed, 23 insertions(+), 16 deletions(-)
 create mode 120000 docs/index.md

diff --git a/docs/.pages b/docs/.pages
index 8ffe072..db0ac1b 100644
--- a/docs/.pages
+++ b/docs/.pages
@@ -1,4 +1,4 @@
-title: "STUN Client documentation"
+title: "STUNC"
 
 nav:
     - "api"
diff --git a/docs/api/.pages b/docs/api/.pages
index e96c0a6..78b4dfa 100644
--- a/docs/api/.pages
+++ b/docs/api/.pages
@@ -1,4 +1,4 @@
-title: "STUN Client API"
+title: "STUNC"
 
 nav:
     - "ubus"
diff --git a/docs/api/ubus/.pages b/docs/api/ubus/.pages
index e2d5ae9..08f02a8 100644
--- a/docs/api/ubus/.pages
+++ b/docs/api/ubus/.pages
@@ -1 +1,2 @@
+title: "STUNC"
 hide: true
diff --git a/docs/api/uci/.pages b/docs/api/uci/.pages
index 9370ea5..3db2037 100644
--- a/docs/api/uci/.pages
+++ b/docs/api/uci/.pages
@@ -1,4 +1,4 @@
-title: "STUN Client UCI"
+title: "STUNC"
 
 nav:
     - "..."
diff --git a/docs/arch/.pages b/docs/arch/.pages
index e2d5ae9..08f02a8 100644
--- a/docs/arch/.pages
+++ b/docs/arch/.pages
@@ -1 +1,2 @@
+title: "STUNC"
 hide: true
diff --git a/docs/guide/.pages b/docs/guide/.pages
index e2d5ae9..08f02a8 100644
--- a/docs/guide/.pages
+++ b/docs/guide/.pages
@@ -1 +1,2 @@
+title: "STUNC"
 hide: true
diff --git a/docs/index.md b/docs/index.md
new file mode 120000
index 0000000..32d46ee
--- /dev/null
+++ b/docs/index.md
@@ -0,0 +1 @@
+../README.md
\ No newline at end of file
diff --git a/docs/spec/.pages b/docs/spec/.pages
index e2d5ae9..08f02a8 100644
--- a/docs/spec/.pages
+++ b/docs/spec/.pages
@@ -1 +1,2 @@
+title: "STUNC"
 hide: true
diff --git a/gitlab-ci/install-dependencies.sh b/gitlab-ci/install-dependencies.sh
index 08ca246..a0bc2c3 100755
--- a/gitlab-ci/install-dependencies.sh
+++ b/gitlab-ci/install-dependencies.sh
@@ -10,5 +10,5 @@ exec_cmd apt update
 exec_cmd apt install -y python3-pip
 exec_cmd pip3 install pexpect ubus
 
-# install bbfdm
-install_bbfdm
+# install cwmp client
+install_icwmp
diff --git a/gitlab-ci/shared.sh b/gitlab-ci/shared.sh
index c24c4ea..4ecd966 100644
--- a/gitlab-ci/shared.sh
+++ b/gitlab-ci/shared.sh
@@ -51,17 +51,19 @@ function build_stunc()
 	exec_cmd ln -s ${PWD}/src/stunc /usr/sbin/stunc
 }
 
-function install_bbfdm()
+function install_icwmp()
 {
-	[ -d "/opt/dev/bbfdm" ] && rm -rf /opt/dev/bbfdm
+	[ -d "/opt/dev/icwmp" ] && rm -rf /opt/dev/icwmp
 
-	if [ -n "${BBFDM_BRANCH}" ]; then
-		exec_cmd git clone -b ${BBFDM_BRANCH} https://dev.iopsys.eu/bbf/bbfdm.git /opt/dev/bbfdm
+	if [ -n "${CWMP_BRANCH}" ]; then
+		exec_cmd git clone -b ${CWMP_BRANCH} https://dev.iopsys.eu/bbf/icwmp.git /opt/dev/icwmp
 	else
-		exec_cmd git clone https://dev.iopsys.eu/bbf/bbfdm.git /opt/dev/bbfdm
+		exec_cmd git clone https://dev.iopsys.eu/bbf/icwmp.git /opt/dev/icwmp
 	fi
 
-	cd /opt/dev/bbfdm
-	./gitlab-ci/install-dependencies.sh install
-	./gitlab-ci/setup.sh install
+	cd /opt/dev/icwmp
+	./gitlab-ci/install-dependencies.sh
+	./gitlab-ci/setup.sh
+	. ./gitlab-ci/shared.sh
+	build_icwmp
 }
diff --git a/mkdocs.yml b/mkdocs.yml
index 8b06ce8..7f01584 100755
--- a/mkdocs.yml
+++ b/mkdocs.yml
@@ -1,4 +1,4 @@
-site_name: TR-x69
+site_name: TR-x69 STUNC
 site_url: https://docs.iopsys.eu/bbf/stunc/
 edit_uri: "https://dev.iopsys.eu/bbf/stunc"
 
diff --git a/src/datamodel.c b/src/datamodel.c
index dc18d4b..7fc5d7e 100644
--- a/src/datamodel.c
+++ b/src/datamodel.c
@@ -9,8 +9,8 @@
  *
  */
 
-#include <libbbf_api.h>
-#include <libbbf_api/dmuci.h>
+#include <libbbfdm_api.h>
+#include <libbbfdm-api/dmuci.h>
 
 /*
  * STUN parameters
-- 
GitLab