diff options
author | William A. Kennington III <wak@google.com> | 2019-03-15 14:14:07 -0700 |
---|---|---|
committer | Patrick Venture <venture@google.com> | 2019-03-19 07:29:29 -0700 |
commit | 374350d7446aa56c57bc9f92c58fd946bc12da5b (patch) | |
tree | a3a0511732b5214fc4980c354995520ea251f65d | |
parent | de8a16e2e85f49e142461b7e6fe901d3f8740fdf (diff) | |
download | phosphor-ipmi-blobs-374350d7446aa56c57bc9f92c58fd946bc12da5b.tar.gz phosphor-ipmi-blobs-374350d7446aa56c57bc9f92c58fd946bc12da5b.zip |
autotools: Fix for autoconf-archive 2019.01.19
The code coverage macros from the archive changed in a backward
incompatible way. This adds a workaround to autodetect either version
and do the right thing.
Change-Id: I09b88e6b4792c99140a73a4ceb11d2896ee13562
Signed-off-by: William A. Kennington III <wak@google.com>
-rw-r--r-- | .gitignore | 1 | ||||
-rw-r--r-- | Makefile.am | 8 | ||||
-rw-r--r-- | configure.ac | 7 | ||||
-rw-r--r-- | test/Makefile.am | 1 |
4 files changed, 14 insertions, 3 deletions
@@ -22,6 +22,7 @@ Makefile.in /autoscan.log /autoscan-*.log /aclocal.m4 +/aminclude_static.am /compile /config.guess /config.h.in diff --git a/Makefile.am b/Makefile.am index d777c20..853bcce 100644 --- a/Makefile.am +++ b/Makefile.am @@ -27,6 +27,14 @@ CODE_COVERAGE_GENHTML_OPTIONS += --config-file $(abs_srcdir)/.lcovrc CODE_COVERAGE_GENHTML_OPTIONS += --prefix $(abs_srcdir) --prefix $(abs_builddir) export CODE_COVERAGE_GENHTML_OPTIONS +if AUTOCONF_CODE_COVERAGE_2019_01_06 +include $(top_srcdir)/aminclude_static.am +clean-local: code-coverage-clean +distclean-local: code-coverage-dist-clean +else +@CODE_COVERAGE_RULES@ +endif + libblobcmdsdir = ${libdir}/ipmid-providers libblobcmds_LTLIBRARIES = libblobcmds.la libblobcmds_la_SOURCES = \ diff --git a/configure.ac b/configure.ac index 31f9416..0b46133 100644 --- a/configure.ac +++ b/configure.ac @@ -4,7 +4,7 @@ AC_INIT([phosphor-ipmi-blobs], [1.0], [https://github.com/openbmc/phosphor-ipmi- AC_LANG([C++]) AC_CONFIG_HEADERS([config.h]) AC_CONFIG_MACRO_DIRS([m4]) -AM_INIT_AUTOMAKE([subdir-objects -Wall -Werror foreign dist-xz]) +AM_INIT_AUTOMAKE([subdir-objects -Wall -Wno-portability -Werror foreign dist-xz]) AM_SILENT_RULES([yes]) # Make sure the default CFLAGS of `-O2 -g` don't override CODE_COVERAGE_CFLAGS @@ -133,10 +133,13 @@ m4_foreach([vgtool], [valgrind_tool_list], # Code coverage AX_CODE_COVERAGE -AM_EXTRA_RECURSIVE_TARGETS([check-code-coverage]) AS_IF([test "x$CODE_COVERAGE_ENABLED" = "xyes"], [ AX_APPEND_COMPILE_FLAGS([-DHAVE_GCOV], [CODE_COVERAGE_CPPFLAGS]) ]) +m4_ifdef([_AX_CODE_COVERAGE_RULES], + [AM_CONDITIONAL(AUTOCONF_CODE_COVERAGE_2019_01_06, [true])], + [AM_CONDITIONAL(AUTOCONF_CODE_COVERAGE_2019_01_06, [false])]) +AX_ADD_AM_MACRO_STATIC([]) # Add --enable-oe-sdk flag to configure script AC_ARG_ENABLE([oe-sdk], diff --git a/test/Makefile.am b/test/Makefile.am index de6bea5..dc862c4 100644 --- a/test/Makefile.am +++ b/test/Makefile.am @@ -1,5 +1,4 @@ @VALGRIND_CHECK_RULES@ -@CODE_COVERAGE_RULES@ AM_CPPFLAGS = \ -I$(top_srcdir)/ \ |