Adds CI CD with deb for external deps

This commit is contained in:
torsten committed 2026-11-06 18:15:17 +00:00
1 parent 03d48b76e4
commit 7373cb8d73
82 files changed
+3547 -3

No files matched your search

@@ -0,0 +1,74 @@
#!/bin/bash
# GeographicLib DEB Package Build Script
# Builds libgeographiclib-dev DEB package for internal SCM repository
set -e
PACKAGE_NAME="libgeographiclib-dev"
VERSION="2.3"
ARCHITECTURE="amd64"
MAINTAINER="Legatus Team <legatus@defence-elec.de>"
DESCRIPTION="GeographicLib library - development files"
# Create package structure
DEB_DIR="deb-package"
rm -rf "$DEB_DIR"
mkdir -p "$DEB_DIR/DEBIAN"
mkdir -p "$DEB_DIR/opt/GeographicLib"
mkdir -p "$DEB_DIR/opt/offline-cache/geographiclib"
# Copy GeographicLib files from external/GeographicLib
if [ -d "../../external/GeographicLib" ]; then
cp -r ../../external/GeographicLib/* "$DEB_DIR/opt/GeographicLib/"
fi
# Create control file
cat > "$DEB_DIR/DEBIAN/control" << EOF
Package: $PACKAGE_NAME
Version: $VERSION
Architecture: $ARCHITECTURE
Maintainer: $MAINTAINER
Depends: libc6, libgcc1, libstdc++6
Section: libdevel
Priority: optional
Description: $DESCRIPTION
GeographicLib library for geodesic calculations.
.
License: MIT/X11 (open source)
EOF
# Create postinst script
cat > "$DEB_DIR/DEBIAN/postinst" << 'EOF'
#!/bin/bash
set -e
echo "GeographicLib DEB package installed successfully"
# Set permissions
chmod -R 755 /opt/GeographicLib
exit 0
EOF
chmod 755 "$DEB_DIR/DEBIAN/postinst"
# Create postrm script
cat > "$DEB_DIR/DEBIAN/postrm" << 'EOF'
#!/bin/bash
set -e
echo "GeographicLib DEB package removed"
exit 0
EOF
chmod 755 "$DEB_DIR/DEBIAN/postrm"
# Build DEB package
echo "Building DEB package: ${PACKAGE_NAME}_${VERSION}_${ARCHITECTURE}.deb"
cd "$DEB_DIR"
dpkg-deb --build . "../${PACKAGE_NAME}_${VERSION}_${ARCHITECTURE}.deb"
cd ..
echo "DEB package created: ${PACKAGE_NAME}_${VERSION}_${ARCHITECTURE}.deb"
echo "Size: $(du -h ${PACKAGE_NAME}_${VERSION}_${ARCHITECTURE}.deb | cut -f1)"
@@ -0,0 +1,7 @@
libgeographiclib-dev (2.3) stable; urgency=medium
* Initial release for air-gapped environment
* GeographicLib library with MIT-style license
* Installs to /opt/GeographicLib
-- Legatus Team <legatus@defence-elec.de> Mon, 01 Jan 2024 00:00:00 +0000
@@ -0,0 +1,18 @@
Source: libgeographiclib-dev
Section: libdevel
Priority: optional
Maintainer: Legatus Team <legatus@defence-elec.de>
Build-Depends: debhelper (>= 12)
Standards-Version: 4.6.0
Vcs-Browser: https://internal-repo.sl.defence-elec.de/#browse/browse:external-rpms:general
Vcs-Git: https://internal-repo.sl.defence-elec.de/git/external/geographiclib.git
Package: libgeographiclib-dev
Architecture: amd64
Depends: libgeographiclib23, ${shlibs:Depends}, ${misc:Depends}
Description: GeographicLib library - development files
GeographicLib library for Legatus.
.
License: MIT-style open source
.
This package contains the development files for GeographicLib library.
@@ -0,0 +1,17 @@
#!/usr/bin/make -f
# Allow override of source path for building in CI/CD or local environments
# Default: /opt (production build machine)
# Can be overridden via DEB_BUILD_OPT_PATH environment variable
OPT_BASE ?= /opt
%:
dh $@
override_dh_auto_install:
dh_auto_install
install -d debian/libgeographiclib-dev/opt/GeographicLib
cp -r $(OPT_BASE)/GeographicLib/* debian/libgeographiclib-dev/opt/GeographicLib/
override_dh_strip:
dh_strip --no-automatic-dbgsym
@@ -0,0 +1,7 @@
libgeographiclib-dev (2.3) stable; urgency=medium
* Initial release for air-gapped environment
* GeographicLib library with MIT-style license
* Installs to /opt/GeographicLib
-- Legatus Team <legatus@defence-elec.de> Mon, 01 Jan 2024 00:00:00 +0000
@@ -0,0 +1 @@
12
@@ -0,0 +1,18 @@
Source: libgeographiclib-dev
Section: libdevel
Priority: optional
Maintainer: Legatus Team <legatus@defence-elec.de>
Build-Depends: debhelper (>= 12)
Standards-Version: 4.6.0
Vcs-Browser: https://internal-repo.sl.defence-elec.de/#browse/browse:external-rpms:general
Vcs-Git: https://internal-repo.sl.defence-elec.de/git/external/geographiclib.git
Package: libgeographiclib-dev
Architecture: amd64
Depends: libgeographiclib23, ${shlibs:Depends}, ${misc:Depends}
Description: GeographicLib library - development files
GeographicLib library for Legatus.
.
License: MIT-style open source
.
This package contains the development files for GeographicLib library.
@@ -0,0 +1,17 @@
#!/usr/bin/make -f
# Allow override of source path for building in CI/CD or local environments
# Default: /opt (production build machine)
# Can be overridden via DEB_BUILD_OPT_PATH environment variable
OPT_BASE ?= /opt
%:
dh $@
override_dh_auto_install:
dh_auto_install
install -d debian/libgeographiclib-dev/opt/GeographicLib
cp -r $(OPT_BASE)/GeographicLib/* debian/libgeographiclib-dev/opt/GeographicLib/
override_dh_strip:
dh_strip --no-automatic-dbgsym
@@ -0,0 +1 @@
3.0 (native)