From: Michael Wagner Date: Mon, 11 Feb 2019 22:38:57 +0000 (+0100) Subject: epic-ts X-Git-Tag: mbuild_0.3-2~3 X-Git-Url: http://wagnertech.de/git?a=commitdiff_plain;h=0633b557b49fed857fcb209037a12138c7cb6467;p=projects.git epic-ts --- diff --git a/tools/make/mconfigure b/tools/make/mconfigure index a6e919d..4313e46 100755 --- a/tools/make/mconfigure +++ b/tools/make/mconfigure @@ -120,15 +120,21 @@ then # delete changelog and control rm debian/changelog debian/control || true - echo "paket=$paket" > debian/rules.pre + # mconfigure builds 2 environment files: setenv.sh + rules.pre + # setenv.sh is finally appended to rules.pre + + dpkg-architecture > debian/setenv.sh + echo "" > debian/rules.pre + + echo "paket=$paket" >> debian/setenv.sh # shift ARCH="" cpp_build=0 set_build check_version - echo "version=$version" >> debian/rules.pre - echo "build=$build" >> debian/rules.pre + echo "version=$version" >> debian/setenv.sh + echo "build=$build" >> debian/setenv.sh # get repository name # tmp=$(pwd) @@ -153,18 +159,20 @@ then then echo "add_inst_tgt += debian/tmp/DEBIAN/preinst" >> rules.pre fi - if [ -f $paket.postinst ] - then - echo "add_inst_tgt += debian/tmp/DEBIAN/postinst" >> rules.pre - fi - if [ -f $paket.prerm ] - then - echo "add_inst_tgt += debian/tmp/DEBIAN/prerm" >> rules.pre - fi - if [ -f $paket.postrm ] - then - echo "add_inst_tgt += debian/tmp/DEBIAN/postrm" >> rules.pre - fi + if [ -f $paket.postinst ] + then + echo "add_inst_tgt += debian/tmp/DEBIAN/postinst" >> rules.pre + fi + if [ -f $paket.prerm ] + then + echo "add_inst_tgt += debian/tmp/DEBIAN/prerm" >> rules.pre + fi + if [ -f $paket.postrm ] + then + echo "add_inst_tgt += debian/tmp/DEBIAN/postrm" >> rules.pre + fi + + cat setenv.sh >> rules.pre mkdir -p tmp/DEBIAN @@ -226,7 +234,6 @@ then else echo "PACK=version" >> debian/rules.pre fi - cp debian/rules.pre debian/setenv.sh fi if [ $compile -eq 1 -a ! -e debian/$paket.build ] diff --git a/tools/make/rules b/tools/make/rules index 33e72e3..d526237 100755 --- a/tools/make/rules +++ b/tools/make/rules @@ -63,7 +63,7 @@ debian/tmp/DEBIAN/control: debian/control debian/changelog dpkg-gencontrol debian/control: debian/$(paket).control - cp debian/$(paket).control debian/control + sed "s/_DEB_HOST_ARCH/${DEB_HOST_ARCH}/" debian/$(paket).control >> debian/control debian/changelog: debian/$(paket).changelog debian/rules.pre sed "s/%BUILD%/$(build)/" debian/$(paket).changelog > debian/changelog