From 76adea11a0a9ea7f1c1ca28988d8ff3c2d9cde04 Mon Sep 17 00:00:00 2001 From: Alexandre Julliard Date: Wed, 21 May 2008 14:48:33 +0200 Subject: [PATCH] configure: Added an ERROR_WITH macro for packages that we can't do without. --- aclocal.m4 | 6 ++++++ configure | 7 ++----- configure.ac | 2 +- 3 files changed, 9 insertions(+), 6 deletions(-) diff --git a/aclocal.m4 b/aclocal.m4 index dcbe78b4ce..0f36122871 100644 --- a/aclocal.m4 +++ b/aclocal.m4 @@ -178,6 +178,12 @@ AC_DEFUN([WINE_WARNING_WITH],[AS_IF([$2],[case "x$with_$1" in This is an error since --with-$1 was requested.]) ;; esac])]) +AC_DEFUN([WINE_ERROR_WITH],[AS_IF([$2],[case "x$with_$1" in + xno) ;; + *) AC_MSG_ERROR([$3 +Use the --without-$1 option if you really want this.]) ;; +esac])]) + AC_DEFUN([WINE_PRINT_MESSAGES],[ac_save_IFS="$IFS" IFS="|" if test "x$wine_notices != "x; then diff --git a/configure b/configure index e572c7fb43..26899f1e84 100755 --- a/configure +++ b/configure @@ -11563,18 +11563,15 @@ else fi if test "x$XLIB" = "x"; then case "x$with_x" in - x) wine_warnings="$wine_warnings|X development files not found. Wine will be built -without X support, which probably isn't what you want. You will need to install -development packages of Xlib/Xfree86 at the very least." ;; xno) ;; *) { { echo "$as_me:$LINENO: error: X development files not found. Wine will be built without X support, which probably isn't what you want. You will need to install development packages of Xlib/Xfree86 at the very least. -This is an error since --with-x was requested." >&5 +Use the --without-x option if you really want this." >&5 echo "$as_me: error: X development files not found. Wine will be built without X support, which probably isn't what you want. You will need to install development packages of Xlib/Xfree86 at the very least. -This is an error since --with-x was requested." >&2;} +Use the --without-x option if you really want this." >&2;} { (exit 1); exit 1; }; } ;; esac fi diff --git a/configure.ac b/configure.ac index fc81d92a9c..942d989b6e 100644 --- a/configure.ac +++ b/configure.ac @@ -781,7 +781,7 @@ else X_CFLAGS="" X_LIBS="" fi -WINE_WARNING_WITH(x,[test "x$XLIB" = "x"],[X development files not found. Wine will be built +WINE_ERROR_WITH(x,[test "x$XLIB" = "x"],[X development files not found. Wine will be built without X support, which probably isn't what you want. You will need to install development packages of Xlib/Xfree86 at the very least.])