summaryrefslogtreecommitdiff
path: root/Makefile.am
diff options
context:
space:
mode:
authorThomas Haller <thaller@redhat.com>2020-02-21 10:01:49 +0100
committerThomas Haller <thaller@redhat.com>2020-02-21 10:07:54 +0100
commit16df1c179d6d3861042e182346b9ca6d75a64c51 (patch)
tree3889a9fe085c9d795635973ddf7ac3f633fef4b9 /Makefile.am
parent1bc5a7c778a86d359e9ef1427f051d64d6e09a9d (diff)
downloadNetworkManager-16df1c179d6d3861042e182346b9ca6d75a64c51.tar.gz
build/autotools: fix passing AM_CFLAGS when building libnm-core
With `./configure --enable-more-asserts`, we add extra -W flags to AM_CFLAGS. This variable is only used, if the per-library override libnm_core_libnm_core_la_CFLAGS is unspecified ([1]). Usually we avoid this problem be never specifying library_CFLAGS, but placing all our per-library flags to library_CPPFLAGS. While that is a bit of a hack and misuse of CPPFLAGS, it works well (enough). This was broken recently. The effect was, that libnm-core was not build with AM_CFLAGS flags. Fix it. [1] https://www.gnu.org/software/automake/manual/html_node/Flag-Variables-Ordering.html Fixes: d2d6a6869755 ('build: use -fcommon when building libnm-core')
Diffstat (limited to 'Makefile.am')
-rw-r--r--Makefile.am2
1 files changed, 1 insertions, 1 deletions
diff --git a/Makefile.am b/Makefile.am
index b9813f3aba..84a4589292 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -1084,7 +1084,7 @@ libnm_core_libnm_core_la_CPPFLAGS = \
if WITH_JSON_VALIDATION
libnm_core_libnm_core_la_CPPFLAGS += $(JANSSON_CFLAGS)
-libnm_core_libnm_core_la_CFLAGS = -fcommon
+libnm_core_libnm_core_la_CPPFLAGS += -fcommon
endif
libnm_core_libnm_core_la_SOURCES = \