From 6ac36e29d47c08f189829cff457d991db6ff4fdf Mon Sep 17 00:00:00 2001 From: mstroh76 Date: Fri, 1 Mar 2024 16:53:26 +0100 Subject: [PATCH 1/2] #192 --- build | 4 +++- debian-template/wiringPi/{DEBIAN/control => control_template} | 2 +- 2 files changed, 4 insertions(+), 2 deletions(-) rename debian-template/wiringPi/{DEBIAN/control => control_template} (95%) diff --git a/build b/build index 49117519..309f75dc 100755 --- a/build +++ b/build @@ -86,6 +86,8 @@ if [ x$1 = "xdebian" ]; then here=`pwd` deb_destdir=${here}/debian-template/wiringPi cd debian-template/wiringPi + ARCH=$(dpkg-architecture -qDEB_HOST_ARCH) + envsubst < control_template > DEBIAN/control rm -rf usr cd $here/wiringPi make install-deb DEB_DESTDIR=${deb_destdir} @@ -95,7 +97,7 @@ if [ x$1 = "xdebian" ]; then make install-deb INCLUDE='-I../wiringPi -I../devLib' LDFLAGS=-L../debian-template/wiringPi/usr/lib DEB_DESTDIR=${deb_destdir} cd $here/debian-template fakeroot dpkg-deb --build wiringPi - mv wiringPi.deb wiringpi-`cat $here/VERSION`-1.deb + dpkg-name wiringPi.deb exit fi diff --git a/debian-template/wiringPi/DEBIAN/control b/debian-template/wiringPi/control_template similarity index 95% rename from debian-template/wiringPi/DEBIAN/control rename to debian-template/wiringPi/control_template index 2d1ae2c3..383b3889 100644 --- a/debian-template/wiringPi/DEBIAN/control +++ b/debian-template/wiringPi/control_template @@ -2,7 +2,7 @@ Package: wiringpi Version: 3.0 Section: libraries Priority: optional -Architecture: armhf +Architecture: $ARCH Depends: libc6 Maintainer: Grazer Computer Club - GC2 Uploaders: Grazer Computer Club - GC2 From d0e2f8fcb3f4b81f0be07b25ec876eafcedd7c0e Mon Sep 17 00:00:00 2001 From: mstroh76 Date: Fri, 1 Mar 2024 18:59:58 +0100 Subject: [PATCH 2/2] #192 --- build | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/build b/build index 309f75dc..c9937927 100755 --- a/build +++ b/build @@ -86,7 +86,8 @@ if [ x$1 = "xdebian" ]; then here=`pwd` deb_destdir=${here}/debian-template/wiringPi cd debian-template/wiringPi - ARCH=$(dpkg-architecture -qDEB_HOST_ARCH) + export ARCH=$(dpkg-architecture -qDEB_HOST_ARCH) + echo architecture $ARCH envsubst < control_template > DEBIAN/control rm -rf usr cd $here/wiringPi @@ -97,7 +98,7 @@ if [ x$1 = "xdebian" ]; then make install-deb INCLUDE='-I../wiringPi -I../devLib' LDFLAGS=-L../debian-template/wiringPi/usr/lib DEB_DESTDIR=${deb_destdir} cd $here/debian-template fakeroot dpkg-deb --build wiringPi - dpkg-name wiringPi.deb + dpkg-name -o wiringPi.deb exit fi