From cf5b073acc5d49f03a491a8c6dca62d4792282cc Mon Sep 17 00:00:00 2001 From: Ian Jackson Date: Sat, 26 Sep 2015 01:41:39 +0000 Subject: [PATCH] Debian build: ./newVersion updates debian/changelog too. Also, tidy up the debian/changelog. Signed-off-by: Ian Jackson --- debian/.gitignore | 1 + debian/changelog | 4 ++-- newVersion | 19 +++++++++++++++++++ 3 files changed, 22 insertions(+), 2 deletions(-) diff --git a/debian/.gitignore b/debian/.gitignore index 5145e9a..9b065a4 100644 --- a/debian/.gitignore +++ b/debian/.gitignore @@ -8,3 +8,4 @@ libwiringpi-dev files *.postinst.debhelper *.postrm.debhelper +changelog.new diff --git a/debian/changelog b/debian/changelog index e784367..6d579fe 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,4 +1,4 @@ -wiringpi (2.28~iwj1) unstable; urgency=medium +wiringpi (2.28-1) RASPBIAN; urgency=medium * Make `./build debian' do a true Debian source package based build; provide the old style build as `./build debian-template' @@ -27,7 +27,7 @@ wiringpi (2.28~iwj1) unstable; urgency=medium * ./newVersion updates debian/changelog too. * Remove the +x bit from maxdetect.[ch] and examples/PiFace/ladder.c. - -- + -- Ian Jackson Sat, 26 Sep 2015 02:53:46 +0100 wiringpi (2.26~iwj) rpi-unstable; urgency=low diff --git a/newVersion b/newVersion index bab6dc5..e89ae7e 100755 --- a/newVersion +++ b/newVersion @@ -41,3 +41,22 @@ Description: The wiringPi libraries, headers and gpio command Libraries to allow GPIO access on a Raspberry Pi from C and C++ programs as well as from the command-line EOF + +changelog=$(dpkg-parsechangelog) +olddebversion=$(printf "%s" "$changelog" | + sed -n '/^Version: / { s/^Version: //; p; q }') +newversion=`cat VERSION` + +if [ x"$olddebversion" != x"$newversion" ]; then + clog=debian/changelog + datestamp=$(date -R) + cat <$clog.new +wiringpi ($newversion) RASPBIAN; urgency=medium + + * New upstream version + + -- Gordon Henderson $datestamp + +END + mv -f $clog.new $clog +fi -- 2.30.2