0
0
Fork 1
mirror of https://mau.dev/maunium/synapse.git synced 2024-12-12 21:23:22 +01:00

Fix deb build script to set prerelease flag correctly (#10500)

This commit is contained in:
Richard van der Hoff 2021-08-01 10:47:36 +01:00 committed by GitHub
parent c167e09fe5
commit 2afdb5c984
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 5 additions and 5 deletions

1
changelog.d/10500.misc Normal file
View file

@ -0,0 +1 @@
Fix a bug which caused production debian packages to be incorrectly marked as 'prerelease'.

View file

@ -11,10 +11,6 @@ DIST=`cut -d ':' -f2 <<< $distro`
cp -aT /synapse/source /synapse/build
cd /synapse/build
# add an entry to the changelog for this distribution
dch -M -l "+$DIST" "build for $DIST"
dch -M -r "" --force-distribution --distribution "$DIST"
# if this is a prerelease, set the Section accordingly.
#
# When the package is later added to the package repo, reprepro will use the
@ -23,11 +19,14 @@ dch -M -r "" --force-distribution --distribution "$DIST"
DEB_VERSION=`dpkg-parsechangelog -SVersion`
case $DEB_VERSION in
*rc*|*a*|*b*|*c*)
*~rc*|*~a*|*~b*|*~c*)
sed -ie '/^Section:/c\Section: prerelease' debian/control
;;
esac
# add an entry to the changelog for this distribution
dch -M -l "+$DIST" "build for $DIST"
dch -M -r "" --force-distribution --distribution "$DIST"
dpkg-buildpackage -us -uc