]> Gitweb @ Texas Instruments - Open Source Git Repositories - git.TI.com/gitweb - glsdk/libdrm.git/blobdiff - configure.ac
Drop "-Wunsafe-loop-optimizations".
[glsdk/libdrm.git] / configure.ac
index 921dcbd2e691cfba719c14c187a30940923835cf..3eaec74b9c9d8aa002d6d8e627f9b800756ef985 100644 (file)
@@ -20,7 +20,7 @@
 
 AC_PREREQ([2.63])
 AC_INIT([libdrm],
-        [2.4.32],
+        [2.4.37],
         [https://bugs.freedesktop.org/enter_bug.cgi?product=DRI],
         [libdrm])
 
@@ -73,21 +73,26 @@ AC_ARG_ENABLE(radeon,
              [Enable support for radeon's KMS API (default: auto)]),
              [RADEON=$enableval], [RADEON=auto])
 
+AC_ARG_ENABLE(nouveau,
+             AS_HELP_STRING([--disable-nouveau],
+             [Enable support for nouveau's KMS API (default: auto)]),
+             [NOUVEAU=$enableval], [NOUVEAU=auto])
+
 AC_ARG_ENABLE(vmwgfx-experimental-api,
              AS_HELP_STRING([--enable-vmwgfx-experimental-api],
              [Install vmwgfx's experimental kernel API header (default: disabled)]),
              [VMWGFX=$enableval], [VMWGFX=no])
 
-AC_ARG_ENABLE(nouveau-experimental-api,
-             AS_HELP_STRING([--enable-nouveau-experimental-api],
-             [Enable support for nouveau's experimental API (default: disabled)]),
-             [NOUVEAU=$enableval], [NOUVEAU=no])
-
 AC_ARG_ENABLE(omap-experimental-api,
              AS_HELP_STRING([--enable-omap-experimental-api],
              [Enable support for OMAP's experimental API (default: disabled)]),
              [OMAP=$enableval], [OMAP=no])
 
+AC_ARG_ENABLE(exynos-experimental-api,
+             AS_HELP_STRING([--enable-exynos-experimental-api],
+             [Enable support for EXYNOS's experimental API (default: disabled)]),
+             [EXYNOS=$enableval], [EXYNOS=no])
+
 dnl ===========================================================================
 dnl check compiler flags
 AC_DEFUN([LIBDRM_CC_TRY_FLAG], [
@@ -128,7 +133,7 @@ MAYBE_WARN="-Wall -Wextra \
 -Wpointer-arith -Wwrite-strings -Wstrict-prototypes \
 -Wmissing-prototypes -Wmissing-declarations -Wnested-externs \
 -Wpacked -Wswitch-enum -Wmissing-format-attribute \
--Wstrict-aliasing=2 -Winit-self -Wunsafe-loop-optimizations \
+-Wstrict-aliasing=2 -Winit-self \
 -Wdeclaration-after-statement -Wold-style-definition \
 -Wno-missing-field-initializers -Wno-unused-parameter \
 -Wno-attributes -Wno-long-long -Winline"
@@ -191,6 +196,11 @@ if test "x$OMAP" = xyes; then
        AC_DEFINE(HAVE_OMAP, 1, [Have OMAP support])
 fi
 
+AM_CONDITIONAL(HAVE_EXYNOS, [test "x$EXYNOS" = xyes])
+if test "x$EXYNOS" = xyes; then
+       AC_DEFINE(HAVE_EXYNOS, 1, [Have EXYNOS support])
+fi
+
 PKG_CHECK_MODULES(CAIRO, cairo, [HAVE_CAIRO=yes], [HAVE_CAIRO=no])
 if test "x$HAVE_CAIRO" = xyes; then
        AC_DEFINE(HAVE_CAIRO, 1, [Have cairo support])
@@ -204,7 +214,7 @@ if test "x$HAVE_LIBUDEV" = xyes; then
 fi
 AM_CONDITIONAL(HAVE_LIBUDEV, [test "x$HAVE_LIBUDEV" = xyes])
 
-if test "x$INTEL" != "xno" -o "x$RADEON" != "xno"; then
+if test "x$INTEL" != "xno" -o "x$RADEON" != "xno" -o "x$NOUVEAU" != "xno" -o "x$OMAP" != "xno"; then
     # Check for atomic intrinsics
     AC_CACHE_CHECK([for native atomic primitives], drm_cv_atomic_primitives,
     [
@@ -252,7 +262,14 @@ if test "x$INTEL" != "xno" -o "x$RADEON" != "xno"; then
                    AC_MSG_WARN([Disabling libdrm_radeon. It depends on atomic operations, which were not found for your compiler/cpu. Try compiling with -march=native, or install the libatomics-op-dev package.])
                    RADEON=no
            fi
-
+           if test "x$NOUVEAU" != "xauto"; then
+                   if test "x$NOUVEAU" != "xno"; then
+                        AC_MSG_ERROR([libdrm_nouveau depends upon atomic operations, which were not found for your compiler/cpu. Try compiling with -march=native, or install the libatomics-op-dev package, or, failing both of those, disable support for NVIDIA GPUs by passing --disable-nouveau to ./configure])
+                   fi
+           else
+                   AC_MSG_WARN([Disabling libdrm_nouveau. It depends on atomic operations, which were not found for your compiler/cpu. Try compiling with -march=native, or install the libatomics-op-dev package.])
+                   NOUVEAU=no
+           fi
     else
            if test "x$INTEL" != "xno"; then
                    case $host_cpu in
@@ -263,6 +280,9 @@ if test "x$INTEL" != "xno" -o "x$RADEON" != "xno"; then
            if test "x$RADEON" != "xno"; then
                    RADEON=yes
            fi
+           if test "x$NOUVEAU" != "xno"; then
+                   NOUVEAU=yes
+           fi
     fi
 fi
 
@@ -279,6 +299,7 @@ fi
 
 AM_CONDITIONAL(HAVE_INTEL, [test "x$INTEL" != "xno"])
 AM_CONDITIONAL(HAVE_RADEON, [test "x$RADEON" != "xno"])
+AM_CONDITIONAL(HAVE_NOUVEAU, [test "x$NOUVEAU" != "xno"])
 if test "x$RADEON" = xyes; then
        AC_DEFINE(HAVE_RADEON, 1, [Have radeon support])
 fi
@@ -302,6 +323,8 @@ AC_CONFIG_FILES([
        nouveau/libdrm_nouveau.pc
        omap/Makefile
        omap/libdrm_omap.pc
+       exynos/Makefile
+       exynos/libdrm_exynos.pc
        tests/Makefile
        tests/modeprint/Makefile
        tests/modetest/Makefile
@@ -322,4 +345,5 @@ echo "  vmwgfx API     $VMWGFX"
 echo "  Radeon API     $RADEON"
 echo "  Nouveau API    $NOUVEAU"
 echo "  OMAP API       $OMAP"
+echo "  EXYNOS API     $EXYNOS"
 echo ""