Skip to content

Commit

Permalink
debian: Check for accurate Debian changelog version at build time too.
Browse files Browse the repository at this point in the history
When we increment the Open vSwitch version number, we tend to forget to
update it in debian/changelog at the same time.  Right now this gets
fixed up automatically at "make dist" time, but it's even better if we can
always have it be correct in the repository.  This commit should help with
that, by making both "make" and "make dist" refuse to proceed if the
version number is out of sync.
  • Loading branch information
blp committed Jul 21, 2010
1 parent 7454ec7 commit c92647a
Show file tree
Hide file tree
Showing 6 changed files with 12 additions and 47 deletions.
1 change: 0 additions & 1 deletion Makefile.am
Expand Up @@ -69,7 +69,6 @@ SUFFIXES =
noinst_HEADERS += $(EXTRA_DIST)

EXTRA_DIST += \
build-aux/update-debian-changelog \
soexpand.pl

ro_c = echo '/* -*- mode: c; buffer-read-only: t -*- */'
Expand Down
4 changes: 0 additions & 4 deletions boot.sh
@@ -1,6 +1,2 @@
#! /bin/sh
autoreconf --install --force

# Ensure that debian/changelog is up-to-date.
VERSION=`autom4te --language=autoconf -t 'AC_INIT:$2' configure.ac`
build-aux/update-debian-changelog debian/changelog "$VERSION"
37 changes: 0 additions & 37 deletions build-aux/update-debian-changelog

This file was deleted.

1 change: 1 addition & 0 deletions configure.ac
Expand Up @@ -27,6 +27,7 @@ AM_PROG_CC_C_O
AC_PROG_CPP
AC_PROG_RANLIB
AC_PROG_MKDIR_P
AC_PROG_FGREP

AC_ARG_VAR([PERL], [path to Perl interpreter])
AC_PATH_PROG([PERL], perl, no)
Expand Down
14 changes: 10 additions & 4 deletions debian/automake.mk
Expand Up @@ -62,7 +62,13 @@ EXTRA_DIST += \
debian/rules \
debian/rules.modules

dist-hook-debian-changelog:
$(srcdir)/build-aux/update-debian-changelog '$(distdir)/debian/changelog' '$(VERSION)'
DIST_HOOKS += dist-hook-debian-changelog
EXTRA_DIST += build-aux/update-debian-changelog
check-debian-changelog-version:
@if $(FGREP) '($(VERSION))' $(srcdir)/debian/changelog >/dev/null; \
then \
:; \
else \
echo "Update debian/changelog to mention version $(VERSION)"; \
exit 1; \
fi
ALL_LOCAL += check-debian-changelog-version
DIST_HOOKS += check-debian-changelog-version
2 changes: 1 addition & 1 deletion debian/changelog
@@ -1,4 +1,4 @@
openvswitch (1.0.0) unstable; urgency=low
openvswitch (1.0.1) unstable; urgency=low

* New upstream version.

Expand Down

0 comments on commit c92647a

Please sign in to comment.