diff options
author | Alexandre Courbot <acourbot@nvidia.com> | 2016-03-23 13:47:37 +0900 |
---|---|---|
committer | Adam Jackson <ajax@redhat.com> | 2016-04-25 15:14:30 -0400 |
commit | 4cc32880737c2d3e568fdb4867b2dba10fb3998a (patch) | |
tree | 4ed14d31562f6d28f0a1b9cd06be92b17daa619a | |
parent | 16e4bce9e5257c50c80c66efee0d07c2483619e1 (diff) |
configure.ac: Keep environment CFLAGS when testing
DRI2 detection could fail if configure is invoked with a sysroot passed
as CFLAGS. Ideally configure should invoke gcc with the sysroot argument
passed to the configure script, but for some reason this is not done by
AC_COMPILE_IFELSE.
Fix this by ensuring CFLAGS are preserved when checking for stuff.
Signed-off-by: Alexandre Courbot <acourbot@nvidia.com>
Reviewed-by: Emil Velikov <emil.velikov@collabora.com>
-rw-r--r-- | configure.ac | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/configure.ac b/configure.ac index 06b6a08dd..db87ff931 100644 --- a/configure.ac +++ b/configure.ac @@ -880,7 +880,7 @@ if test "x$CONFIG_UDEV" = xyes; then fi SAVE_LIBS=$LIBS SAVE_CFLAGS=$CFLAGS - CFLAGS=$UDEV_CFLAGS + CFLAGS="$CFLAGS $UDEV_CFLAGS" LIBS=$UDEV_LIBS AC_CHECK_FUNCS([udev_monitor_filter_add_match_tag]) AC_CHECK_FUNCS([udev_enumerate_add_match_tag]) @@ -1293,7 +1293,7 @@ fi if test "x$DRI2" = xyes; then save_CFLAGS=$CFLAGS - CFLAGS="$GL_CFLAGS $LIBDRM_CFLAGS" + CFLAGS="$CFLAGS $GL_CFLAGS $LIBDRM_CFLAGS" AC_COMPILE_IFELSE([AC_LANG_SOURCE([[#include <GL/gl.h> #include <GL/internal/dri_interface.h> #ifndef __DRI_DRI2 |