summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThomas Haller <thaller@redhat.com>2018-05-30 11:13:41 +0200
committerThomas Haller <thaller@redhat.com>2018-05-31 15:59:38 +0200
commit82b088ab5f8b619cbbd187d1906e196deaf759ef (patch)
treea78cebbd08e00411eafc6d8435cf024680caaf97
parentcdbd99c5d5b5a62c5d4bf4d5e7a49e97e307d987 (diff)
downloadNetworkManager-82b088ab5f8b619cbbd187d1906e196deaf759ef.tar.gz
build: don't add shared/nm-utils directory to include search path
All users are supposed to include files from nm-utils by fully specifying the path. -I.*shared/nm-utils is wrong. Only, systemd code likes to include "siphash24.h" directly. Instead of adding "-Ishared/nm-utils" to the search path, add an intermediary header to sd-adapt. Note, that in the meantime we anyway should rework siphash24 to use shared/c-siphash instead. This also fixes build for meson, which was broken recently.
-rw-r--r--Makefile.am3
-rw-r--r--shared/meson.build1
-rw-r--r--src/systemd/sd-adapt/siphash24.h3
-rw-r--r--src/systemd/sd-adapt/unaligned.h3
4 files changed, 8 insertions, 2 deletions
diff --git a/Makefile.am b/Makefile.am
index 75283d47ae..a16501007c 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -1258,7 +1258,6 @@ src_libsystemd_nm_la_cppflags = \
-I$(builddir)/libnm-core \
-I$(srcdir)/src \
-I$(srcdir)/src/systemd/sd-adapt \
- -I$(srcdir)/shared/nm-utils \
-I$(srcdir)/src/systemd/src/systemd \
-I$(srcdir)/src/systemd/src/basic \
-I$(srcdir)/src/systemd/src/shared \
@@ -1301,10 +1300,12 @@ src_libsystemd_nm_la_SOURCES = \
src/systemd/sd-adapt/procfs-util.h \
src/systemd/sd-adapt/raw-clone.h \
src/systemd/sd-adapt/sd-daemon.h \
+ src/systemd/sd-adapt/siphash24.h \
src/systemd/sd-adapt/stat-util.h \
src/systemd/sd-adapt/terminal-util.h \
src/systemd/sd-adapt/udev-util.h \
src/systemd/sd-adapt/udev.h \
+ src/systemd/sd-adapt/unaligned.h \
src/systemd/sd-adapt/user-util.h \
src/systemd/sd-adapt/virt.h \
src/systemd/src/basic/alloc-util.c \
diff --git a/shared/meson.build b/shared/meson.build
index a812b5882a..98243435da 100644
--- a/shared/meson.build
+++ b/shared/meson.build
@@ -64,7 +64,6 @@ shared_dep = declare_dependency(
include_directories: [
top_inc,
shared_inc,
- include_directories('nm-utils')
],
dependencies: glib_dep
)
diff --git a/src/systemd/sd-adapt/siphash24.h b/src/systemd/sd-adapt/siphash24.h
new file mode 100644
index 0000000000..ac6e5a1d13
--- /dev/null
+++ b/src/systemd/sd-adapt/siphash24.h
@@ -0,0 +1,3 @@
+#pragma once
+
+#include "nm-utils/siphash24.h"
diff --git a/src/systemd/sd-adapt/unaligned.h b/src/systemd/sd-adapt/unaligned.h
new file mode 100644
index 0000000000..17dc04446c
--- /dev/null
+++ b/src/systemd/sd-adapt/unaligned.h
@@ -0,0 +1,3 @@
+#pragma once
+
+#include "nm-utils/unaligned.h"