summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEric Blake <eblake@redhat.com>2019-01-04 13:47:44 -0600
committerEric Blake <eblake@redhat.com>2019-01-07 16:46:55 -0600
commit1862a554625e9e25b00e2ff85de5f576c1a66c8a (patch)
tree8b1dabad49166f25fd1d7cf891adbd2c073943be
parent7a879323a96514ca53b69f25bd944bb55f69343f (diff)
downloadlibvirt-1862a554625e9e25b00e2ff85de5f576c1a66c8a.tar.gz
maint: Prefer AM_CPPFLAGS over INCLUDES
Our use of INCLUDES in Makefile.am hearkens back to when we had to cater to automake 1.9.6 (thanks, RHEL 5) which lacked AM_CPPFLAGS. Modern Automake flags a warning that INCLUDES is deprecated, and now that we mandate RHEL 7 or better (see commit c1bc9c66), we no longer have to cater to the old spelling. This change will also make it easier to do per-binary CPPFLAGS. Signed-off-by: Eric Blake <eblake@redhat.com> Reviewed-by: Ján Tomko <jtomko@redhat.com>
-rw-r--r--examples/Makefile.am3
-rw-r--r--src/Makefile.am2
-rw-r--r--tests/Makefile.am4
-rw-r--r--tools/Makefile.am2
4 files changed, 6 insertions, 5 deletions
diff --git a/examples/Makefile.am b/examples/Makefile.am
index 5b1f6a0523..61cf2af4a5 100644
--- a/examples/Makefile.am
+++ b/examples/Makefile.am
@@ -33,7 +33,8 @@ EXTRA_DIST = \
$(wildcard $(srcdir)/xml/test/*.xml)
-INCLUDES = -I$(top_builddir)/include -I$(top_srcdir)/include -I$(top_srcdir) \
+AM_CPPFLAGS = \
+ -I$(top_builddir)/include -I$(top_srcdir)/include -I$(top_srcdir) \
-I$(top_builddir)/gnulib/lib -I$(top_srcdir)/gnulib/lib
LDADD = $(STATIC_BINARIES) $(WARN_CFLAGS) $(COVERAGE_LDFLAGS) \
$(top_builddir)/src/libvirt.la $(top_builddir)/gnulib/lib/libgnu.la \
diff --git a/src/Makefile.am b/src/Makefile.am
index 3ac6dcad16..d3e8a1b572 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -25,7 +25,7 @@ abs_topsrcdir = $(shell cd $(top_srcdir) && pwd)
# No libraries with the exception of LIBXML should be listed
# here. List them against the individual XXX_la_CFLAGS targets
# that actually use them.
-INCLUDES = -I../gnulib/lib \
+AM_CPPFLAGS = -I../gnulib/lib \
-I$(top_srcdir)/gnulib/lib \
-I$(top_srcdir) \
-I../include \
diff --git a/tests/Makefile.am b/tests/Makefile.am
index 69dd45728d..f74d8463b6 100644
--- a/tests/Makefile.am
+++ b/tests/Makefile.am
@@ -24,7 +24,7 @@ abs_topsrcdir = $(shell cd $(top_srcdir) && pwd)
SHELL = $(PREFERABLY_POSIX_SHELL)
-INCLUDES = \
+AM_CPPFLAGS = \
-I$(top_builddir) -I$(top_srcdir) \
-I$(top_builddir)/gnulib/lib -I$(top_srcdir)/gnulib/lib \
-I$(top_builddir)/include -I$(top_srcdir)/include \
@@ -63,7 +63,7 @@ QEMULIB_LDFLAGS = \
-rpath /evil/libtool/hack/to/force/shared/lib/creation \
$(MINGW_EXTRA_LDFLAGS)
-INCLUDES += \
+AM_CPPFLAGS += \
-DTEST_DRIVER_DIR=\"$(top_builddir)/src/.libs\"
PROBES_O =
diff --git a/tools/Makefile.am b/tools/Makefile.am
index fadd09977e..613c9a77f0 100644
--- a/tools/Makefile.am
+++ b/tools/Makefile.am
@@ -15,7 +15,7 @@
## License along with this library. If not, see
## <http://www.gnu.org/licenses/>.
-INCLUDES = \
+AM_CPPFLAGS = \
-I$(top_builddir)/include -I$(top_srcdir)/include \
-I$(top_builddir)/gnulib/lib -I$(top_srcdir)/gnulib/lib \
-I$(top_builddir)/src -I$(top_srcdir)/src \