1 diff -ur gpgme.org/configure.ac gpgme/configure.ac
2 --- configure.ac 2017-02-16 15:18:45.051417378 +0100
3 +++ configure.ac~ 2017-02-16 15:20:03.635059285 +0100
5 # decimalized short revision number, a beta version string, and a flag
6 # indicating a development version (mym4_isgit). Note that the m4
7 # processing is done by autoconf and not during the configure run.
8 +m4_define([m4_chomp_all],
9 +[m4_format([[%.*s]], m4_bregexp(m4_translit([[$1]], [
10 +/], [/ ]), [/*$]), [$1])])
12 +m4_define([m4_esyscmd_s], [m4_chomp_all(m4_esyscmd([$1]))])
13 m4_define(mym4_version,
14 [mym4_version_major.mym4_version_minor.mym4_version_micro])
15 m4_define([mym4_revision],
17 AC_CONFIG_MACRO_DIR([m4])
18 AC_CONFIG_SRCDIR(src/gpgme.h.in)
19 AC_CONFIG_HEADER(config.h)
20 -AM_INIT_AUTOMAKE([serial-tests dist-bzip2 no-dist-gzip])
22 +dnl Initialize automake. automake < 1.12 didn't have serial-tests and
23 +dnl gives an error if it sees this, but for automake >= 1.13
24 +dnl serial-tests is required so we have to include it. Solution is to
25 +dnl test for the version of automake (by running an external command)
26 +dnl and provide it if necessary. Note we have to do this entirely using
27 +dnl m4 macros since automake queries this macro by running
28 +dnl 'autoconf --trace ...'.
29 +m4_define([serial_tests], [
30 + m4_esyscmd([automake --version |
32 + awk '{split ($NF,a,"."); if (a[1] == 1 && a[2] >= 12) { print "serial-tests" }}'
35 +AM_INIT_AUTOMAKE(foreign serial_tests dist-bzip2 no-dist-gzip) dnl NB: Do not [quote] this parameter.