summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 7968c0d)
raw | patch | inline | side by side (parent: 7968c0d)
author | Christian Ehrhardt <christian.ehrhardt@canonical.com> | |
Thu, 17 Aug 2017 11:34:12 +0000 (13:34 +0200) | ||
committer | Christian Ehrhardt <christian.ehrhardt@canonical.com> | |
Thu, 17 Aug 2017 11:43:27 +0000 (13:43 +0200) |
This restores the former behavior of LIBDPDK_CPPFLAGS and now
correctly carries CFLAGS read from pkg-config in its own variable.
Signed-off-by: Christian Ehrhardt <christian.ehrhardt@canonical.com>
correctly carries CFLAGS read from pkg-config in its own variable.
Signed-off-by: Christian Ehrhardt <christian.ehrhardt@canonical.com>
Makefile.am | patch | blob | history | |
configure.ac | patch | blob | history |
diff --git a/Makefile.am b/Makefile.am
index 6d286b3c9231cb583c80fce54032b6dec94aa855..bac7604afe6c694fd4d657c823d9e74c56e07344 100644 (file)
--- a/Makefile.am
+++ b/Makefile.am
pkglib_LTLIBRARIES += dpdkevents.la
dpdkevents_la_SOURCES = src/dpdkevents.c src/utils_dpdk.c src/utils_dpdk.h
dpdkevents_la_CPPFLAGS = $(AM_CPPFLAGS) $(LIBDPDK_CPPFLAGS)
+dpdkevents_la_CFLAGS = $(AM_CFLAGS) $(LIBDPDK_CFLAGS)
dpdkevents_la_LDFLAGS = $(PLUGIN_LDFLAGS) $(LIBDPDK_LDFLAGS)
dpdkevents_la_LIBADD = $(LIBDPDK_LIBS)
endif
pkglib_LTLIBRARIES += dpdkstat.la
dpdkstat_la_SOURCES = src/dpdkstat.c src/utils_dpdk.c src/utils_dpdk.h
dpdkstat_la_CPPFLAGS = $(AM_CPPFLAGS) $(LIBDPDK_CPPFLAGS)
+dpdkstat_la_CFLAGS = $(AM_CFLAGS) $(LIBDPDK_CFLAGS)
dpdkstat_la_LDFLAGS = $(PLUGIN_LDFLAGS) $(LIBDPDK_LDFLAGS)
dpdkstat_la_LIBADD = $(LIBDPDK_LIBS)
endif
diff --git a/configure.ac b/configure.ac
index cd777746212ea569d635199619db088c0c613d7f..667e944b24faac2a99b3bdf7d7cd19096f2611ec 100644 (file)
--- a/configure.ac
+++ b/configure.ac
# --with-libdpdk {{{
AC_ARG_VAR([LIBDPDK_CPPFLAGS], [Preprocessor flags for libdpdk])
+AC_ARG_VAR([LIBDPDK_CFLAGS], [Compiler flags for libdpdk])
AC_ARG_VAR([LIBDPDK_LDFLAGS], [Linker flags for libdpdk])
AC_ARG_VAR([LIBDPDK_LIBS], [Libraries to link for libdpdk])
if test "x$with_libdpdk" != "xno"; then
PKG_CHECK_MODULES([DPDK], [libdpdk])
- if test "x$LIBDPDK_CPPFLAGS" = "x"; then
- if test "x$DPDK_CFLAGS" != "x"; then
- LIBDPDK_CPPFLAGS="$DPDK_CFLAGS"
- else
- LIBDPDK_CPPFLAGS="-I/usr/include/dpdk"
- fi
+ if test "x$LIBDPDK_CFLAGS" = "x"; then
+ LIBDPDK_CFLAGS="$DPDK_CFLAGS"
fi
if test "x$LIBDPDK_LIBS" = "x"; then
if test "x$DPDK_LIBS" != "x"; then
LIBDPDK_LIBS="-ldpdk"
fi
fi
+ if test "x$LIBDPDK_CPPFLAGS" = "x"; then
+ LIBDPDK_CPPFLAGS="-I/usr/include/dpdk"
+ fi
SAVE_CPPFLAGS="$CPPFLAGS"
CPPFLAGS="$LIBDPDK_CPPFLAGS $CPPFLAGS"
+ SAVE_CFLAGS="$CFLAGS"
+ CFLAGS="$LIBDPDK_CFLAGS $CFLAGS"
AC_CHECK_HEADERS([rte_config.h],
[
with_libdpdk="yes"
[with_libdpdk="no (rte_config.h not found)"]
)
CPPFLAGS="$SAVE_CPPFLAGS"
+ CFLAGS="$SAVE_CFLAGS"
fi
if test "x$with_libdpdk" = "xyes"; then