Skip to content

Commit 40e3290

Browse files
committed
autogen.sh: Delete all trailing blank lines at end of configure.
Same as in tcpslice and libpcap.
1 parent a51c3a8 commit 40e3290

File tree

2 files changed

+11
-0
lines changed

2 files changed

+11
-0
lines changed

CHANGES

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -66,6 +66,7 @@ DayOfTheWeek, Month DD, YYYY / The Tcpdump Group
6666
.devel file does not exists.
6767
tests: On HP-UX use "diff -c" by default.
6868
autogen.sh: Allow to configure Autoconf warnings.
69+
autogen.sh: Delete all trailing blank lines at end of configure.
6970
Documentation:
7071
man: Clarify the "any" pseudo-interface further.
7172

autogen.sh

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,3 +29,13 @@ echo "$AUTORECONF identification: $AUTORECONFVERSION"
2929
# the branch) amount of noise to the build matrix output, so provide a means
3030
# to silence that.
3131
env ${AUTOCONF_WARNINGS:+WARNINGS="$AUTOCONF_WARNINGS"} "$AUTORECONF" -f
32+
33+
# Autoconf 2.71 adds a blank line after the final "exit 0" on Linux, but not
34+
# on OpenBSD. Remove this difference to make it easier to compare the result
35+
# of "make releasetar" across different platforms. From sed one-liners:
36+
# "delete all trailing blank lines at end of file (works on all seds)". Don't
37+
# use mktemp(1) because AIX does not have it.
38+
CONFIGURE_NEW="configure.new$$"
39+
sed -e :a -e '/^\n*$/{$d;N;ba' -e '}' <configure >"$CONFIGURE_NEW"
40+
cmp -s configure "$CONFIGURE_NEW" || cat "$CONFIGURE_NEW" >configure
41+
rm -f "$CONFIGURE_NEW"

0 commit comments

Comments
 (0)