summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--.gitmodules5
m---------packages/libyang0
-rwxr-xr-xscripts/build-submodules38
3 files changed, 42 insertions, 1 deletions
diff --git a/.gitmodules b/.gitmodules
index 22bb87d5..30793200 100644
--- a/.gitmodules
+++ b/.gitmodules
@@ -236,4 +236,7 @@
[submodule "packages/igmpproxy"]
path = packages/igmpproxy
url = https://github.com/vyos/igmpproxy.git
- branch = current \ No newline at end of file
+ branch = current
+[submodule "packages/libyang"]
+ path = packages/libyang
+ url = https://github.com/opensourcerouting/libyang.git
diff --git a/packages/libyang b/packages/libyang
new file mode 160000
+Subproject 179da47f2e8def1907372408a9df97a0dcbc134
diff --git a/scripts/build-submodules b/scripts/build-submodules
index 0d11c059..b3ea2c1a 100755
--- a/scripts/build-submodules
+++ b/scripts/build-submodules
@@ -140,6 +140,44 @@ if [ $INIT_PACKAGES ]; then
initialize_packages
fi
+build_libyang() {
+ PKG=libyang
+ COMMITID=$(cd $PKGDIR/$PKG; git rev-parse --short=10 HEAD)
+ if ! package_in_buildlist $1; then
+ return 0
+ fi
+ status_start "Building package: $PKG Commit id: $COMMITID"
+ if [ ! -f "$PKGDIR/$PKG/README.md" ]; then
+ status_skip "No source for: $PKG"
+ return 1
+ fi
+
+ ( set -e; set -x
+ cd $PKGDIR/$PKG
+ git checkout 179da47f2e8de
+
+ git clean -dxf
+ git reset --hard
+
+ mkdir build
+ cd build
+
+ cmake ..
+ make build-deb
+
+ cp debs/* $PKGDIR
+
+ ) >>$PKGDIR/$PKG.buildlog 2>&1
+
+ if [ $? -ne 0 ]; then
+ status_fail
+ error_msg "Failed to build package $PKG, look in $PKG.buildlog to examine the fault\n"
+ return 2
+ fi
+ status_ok
+}
+build_libyang
+
build_frr() {
PKG=frr
COMMITID=$(cd $PKGDIR/$PKG; git rev-parse --short=10 HEAD)