Ken Thomases : configure: Only enable the Mac driver on Mac OS X 10. 6 or later.

Alexandre Julliard julliard at winehq.org
Fri Dec 21 11:05:21 CST 2012


Module: wine
Branch: master
Commit: 10c6f8436c28f75c03bc57c2e7c3ee9246e2bb62
URL:    http://source.winehq.org/git/wine.git/?a=commit;h=10c6f8436c28f75c03bc57c2e7c3ee9246e2bb62

Author: Ken Thomases <ken at codeweavers.com>
Date:   Thu Dec 20 19:02:00 2012 -0600

configure: Only enable the Mac driver on Mac OS X 10.6 or later.

---

 configure    |   16 ++++++++++++++--
 configure.ac |   12 ++++++++++--
 2 files changed, 24 insertions(+), 4 deletions(-)

diff --git a/configure b/configure
index 976bd9b..063c25d 100755
--- a/configure
+++ b/configure
@@ -6669,12 +6669,24 @@ done
     else
         as_fn_append wine_notices "|QuickTime ${notice_platform}development files not found, video decoding won't be supported."
     fi
-        if test "$ac_cv_header_Carbon_Carbon_h" = "yes"
+    if test "$ac_cv_header_Carbon_Carbon_h" = "yes"
     then
         CARBONLIB="-framework Carbon"
 
-        enable_winemac_drv=${enable_winemac_drv:-yes}
     fi
+
+        if test "$ac_cv_header_ApplicationServices_ApplicationServices_h" = "yes"
+    then
+        ac_save_LIBS="$LIBS"
+        LIBS="$LIBS $APPLICATIONSERVICESLIB"
+        ac_fn_c_check_func "$LINENO" "CGDisplayModeGetWidth" "ac_cv_func_CGDisplayModeGetWidth"
+if test "x$ac_cv_func_CGDisplayModeGetWidth" = xyes; then :
+  enable_winemac_drv=${enable_winemac_drv:-yes}
+fi
+
+        LIBS="$ac_save_LIBS"
+    fi
+
         if test "x$enable_win16" = "xyes"
     then
         { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether 16-bit code can be built correctly" >&5
diff --git a/configure.ac b/configure.ac
index 5e59e90..2a0a1b6 100644
--- a/configure.ac
+++ b/configure.ac
@@ -796,12 +796,20 @@ case $host_os in
     else
         WINE_NOTICE([QuickTime ${notice_platform}development files not found, video decoding won't be supported.])
     fi
-    dnl Enable Mac driver on Mac OS X
     if test "$ac_cv_header_Carbon_Carbon_h" = "yes"
     then
         AC_SUBST(CARBONLIB,"-framework Carbon")
-        enable_winemac_drv=${enable_winemac_drv:-yes}
     fi
+
+    dnl Enable Mac driver on Mac OS X 10.6 or later
+    if test "$ac_cv_header_ApplicationServices_ApplicationServices_h" = "yes"
+    then
+        ac_save_LIBS="$LIBS"
+        LIBS="$LIBS $APPLICATIONSERVICESLIB"
+        AC_CHECK_FUNC(CGDisplayModeGetWidth,enable_winemac_drv=${enable_winemac_drv:-yes})
+        LIBS="$ac_save_LIBS"
+    fi
+
     dnl Check for Xcode 3.x broken 16-bit support
     if test "x$enable_win16" = "xyes"
     then




More information about the wine-cvs mailing list