configure: error out when building static XOR shared
[mesa.git] / configure.ac
index 1d719be352f2d462d8823a16c30e4af44d57cc64..33f1c42c8bed48c7d86672fd87b9e1c037b9968b 100644 (file)
@@ -468,12 +468,10 @@ dnl explicitly requested. If both disabled, set to static since shared
 dnl was explicitly requested.
 case "x$enable_static$enable_shared" in
 xyesyes)
-    AC_MSG_WARN([Cannot build static and shared libraries, disabling shared])
-    enable_shared=no
+    AC_MSG_ERROR([Cannot enable both static and shared. Building using --enable-shared is strongly recommended])
     ;;
 xnono)
-    AC_MSG_WARN([Cannot disable both static and shared libraries, enabling shared])
-    enable_shared=yes
+    AC_MSG_ERROR([Cannot disable both static and shared. Building using --enable-shared is strongly recommended])
     ;;
 esac
 
@@ -1585,9 +1583,7 @@ if test "x$enable_shader_cache" = "xyes"; then
 fi
 
 if test "x$enable_dri" = xyes; then
-    if test "$enable_static" = yes; then
-        AC_MSG_ERROR([Cannot use static libraries for DRI drivers])
-    fi
+    require_dri_shared_libs_and_glapi "DRI"
 
     # not a hard requirement as swrast does not depend on it
     if test "x$have_libdrm" = xyes; then