Brendan Shanks : configure: Remove DiskArbitration.framework check (always present on macOS).
Module: wine Branch: master Commit: c8f9ee0bf059fa4ba8278d25e4a3f0e4436cf4b3 URL: https://gitlab.winehq.org/wine/wine/-/commit/c8f9ee0bf059fa4ba8278d25e4a3f0e... Author: Brendan Shanks <bshanks(a)codeweavers.com> Date: Wed Nov 9 15:26:20 2022 -0800 configure: Remove DiskArbitration.framework check (always present on macOS). --- configure | 25 +++++++++---------------- configure.ac | 15 ++++++--------- dlls/mountmgr.sys/diskarb.c | 8 ++++---- include/config.h.in | 4 ---- 4 files changed, 19 insertions(+), 33 deletions(-) diff --git a/configure b/configure index 2574923cc01..4de5e53629d 100755 --- a/configure +++ b/configure @@ -745,12 +745,12 @@ METAL_LIBS OPENCL_LIBS COREAUDIO_LIBS SECURITY_LIBS -DISKARBITRATION_LIBS SYSTEMCONFIGURATION_LIBS APPKIT_LIBS CORESERVICES_LIBS APPLICATIONSERVICES_LIBS IOKIT_LIBS +DISKARBITRATION_LIBS COREFOUNDATION_LIBS CARBON_LIBS ac_ct_OBJC @@ -7849,12 +7849,6 @@ if test "x$ac_cv_header_CL_cl_h" = xyes then : printf "%s\n" "#define HAVE_CL_CL_H 1" >>confdefs.h -fi -ac_fn_c_check_header_compile "$LINENO" "DiskArbitration/DiskArbitration.h" "ac_cv_header_DiskArbitration_DiskArbitration_h" "$ac_includes_default" -if test "x$ac_cv_header_DiskArbitration_DiskArbitration_h" = xyes -then : - printf "%s\n" "#define HAVE_DISKARBITRATION_DISKARBITRATION_H 1" >>confdefs.h - fi ac_fn_c_check_header_compile "$LINENO" "EGL/egl.h" "ac_cv_header_EGL_egl_h" "$ac_includes_default" if test "x$ac_cv_header_EGL_egl_h" = xyes @@ -9794,6 +9788,8 @@ ac_compiler_gnu=$ac_cv_c_compiler_gnu COREFOUNDATION_LIBS="-framework CoreFoundation" + DISKARBITRATION_LIBS="-framework DiskArbitration -framework CoreFoundation" + IOKIT_LIBS="-framework IOKit -framework CoreFoundation" APPLICATIONSERVICES_LIBS="-framework ApplicationServices" @@ -9933,11 +9929,6 @@ fi as_fn_append wine_warnings "|can't build Wine preloader; many programs won't work" fi - if test "$ac_cv_header_DiskArbitration_DiskArbitration_h" = "yes" - then - DISKARBITRATION_LIBS="-framework DiskArbitration -framework CoreFoundation" - - fi if test "$ac_cv_header_Security_Security_h" = "yes" then SECURITY_LIBS="-framework Security -framework CoreFoundation" @@ -16124,8 +16115,9 @@ fi CPPFLAGS=$ac_save_CPPFLAGS fi -if test "x$ac_cv_lib_soname_dbus_1" = "x" -a \ - "x$ac_cv_header_DiskArbitration_DiskArbitration_h" != "xyes" +case $host_os in + darwin*|macosx*) ;; + *) if test "x$ac_cv_lib_soname_dbus_1" = "x" then : case "x$with_dbus" in x) as_fn_append wine_notices "|libdbus ${notice_platform}development files not found, no dynamic device support." ;; @@ -16134,7 +16126,8 @@ then : This is an error since --with-dbus was requested." "$LINENO" 5 ;; esac -fi +fi ;; +esac if test "x$with_gnutls" != "xno" then @@ -23248,12 +23241,12 @@ OBJCFLAGS = $OBJCFLAGS ac_ct_OBJC = $ac_ct_OBJC CARBON_LIBS = $CARBON_LIBS COREFOUNDATION_LIBS = $COREFOUNDATION_LIBS +DISKARBITRATION_LIBS = $DISKARBITRATION_LIBS IOKIT_LIBS = $IOKIT_LIBS APPLICATIONSERVICES_LIBS = $APPLICATIONSERVICES_LIBS CORESERVICES_LIBS = $CORESERVICES_LIBS APPKIT_LIBS = $APPKIT_LIBS SYSTEMCONFIGURATION_LIBS = $SYSTEMCONFIGURATION_LIBS -DISKARBITRATION_LIBS = $DISKARBITRATION_LIBS SECURITY_LIBS = $SECURITY_LIBS COREAUDIO_LIBS = $COREAUDIO_LIBS OPENCL_LIBS = $OPENCL_LIBS diff --git a/configure.ac b/configure.ac index 56743a14e0d..a80310fee3b 100644 --- a/configure.ac +++ b/configure.ac @@ -407,7 +407,6 @@ AC_SYS_LARGEFILE() AC_CHECK_HEADERS(\ AL/al.h \ CL/cl.h \ - DiskArbitration/DiskArbitration.h \ EGL/egl.h \ IOKit/IOKitLib.h \ IOKit/hid/IOHIDLib.h \ @@ -682,6 +681,7 @@ case $host_os in dnl declare needed frameworks AC_SUBST(CARBON_LIBS,"-framework Carbon") AC_SUBST(COREFOUNDATION_LIBS,"-framework CoreFoundation") + AC_SUBST(DISKARBITRATION_LIBS,"-framework DiskArbitration -framework CoreFoundation") AC_SUBST(IOKIT_LIBS,"-framework IOKit -framework CoreFoundation") AC_SUBST(APPLICATIONSERVICES_LIBS,"-framework ApplicationServices") AC_SUBST(CORESERVICES_LIBS,"-framework CoreServices") @@ -710,11 +710,6 @@ case $host_os in WINE_WARNING([can't build Wine preloader; many programs won't work]) fi - if test "$ac_cv_header_DiskArbitration_DiskArbitration_h" = "yes" - then - dnl DiskArbitration API is not public on Darwin < 8.0, use it only if header found - AC_SUBST(DISKARBITRATION_LIBS,"-framework DiskArbitration -framework CoreFoundation") - fi if test "$ac_cv_header_Security_Security_h" = "yes" then AC_SUBST(SECURITY_LIBS,"-framework Security -framework CoreFoundation") @@ -1428,9 +1423,11 @@ then [WINE_CHECK_SONAME(dbus-1, dbus_connection_close,,[DBUS_CFLAGS=""],[$DBUS_LIBS])], [DBUS_CFLAGS=""])]) fi -WINE_NOTICE_WITH(dbus,[test "x$ac_cv_lib_soname_dbus_1" = "x" -a \ - "x$ac_cv_header_DiskArbitration_DiskArbitration_h" != "xyes"], - [libdbus ${notice_platform}development files not found, no dynamic device support.]) +case $host_os in + darwin*|macosx*) ;; + *) WINE_NOTICE_WITH(dbus,[test "x$ac_cv_lib_soname_dbus_1" = "x"], + [libdbus ${notice_platform}development files not found, no dynamic device support.]) ;; +esac dnl **** Check for libgnutls **** if test "x$with_gnutls" != "xno" diff --git a/dlls/mountmgr.sys/diskarb.c b/dlls/mountmgr.sys/diskarb.c index 4bcd72c8916..18d4b65a625 100644 --- a/dlls/mountmgr.sys/diskarb.c +++ b/dlls/mountmgr.sys/diskarb.c @@ -31,7 +31,7 @@ #include <stdio.h> #include <unistd.h> #include <sys/ioctl.h> -#ifdef HAVE_DISKARBITRATION_DISKARBITRATION_H +#ifdef __APPLE__ #include <DiskArbitration/DiskArbitration.h> #endif #if defined(HAVE_SYSTEMCONFIGURATION_SCDYNAMICSTORECOPYDHCPINFO_H) && defined(HAVE_SYSTEMCONFIGURATION_SCNETWORKCONFIGURATION_H) @@ -50,7 +50,7 @@ WINE_DEFAULT_DEBUG_CHANNEL(mountmgr); -#ifdef HAVE_DISKARBITRATION_DISKARBITRATION_H +#ifdef __APPLE__ typedef struct { @@ -218,14 +218,14 @@ void run_diskarbitration_loop(void) CFRelease( session ); } -#else /* HAVE_DISKARBITRATION_DISKARBITRATION_H */ +#else /* __APPLE__ */ void run_diskarbitration_loop(void) { TRACE( "Skipping, Disk Arbitration support not compiled in\n" ); } -#endif /* HAVE_DISKARBITRATION_DISKARBITRATION_H */ +#endif /* __APPLE__ */ #if defined(HAVE_SYSTEMCONFIGURATION_SCDYNAMICSTORECOPYDHCPINFO_H) && defined(HAVE_SYSTEMCONFIGURATION_SCNETWORKCONFIGURATION_H) diff --git a/include/config.h.in b/include/config.h.in index e2b123e9049..3c42a13525e 100644 --- a/include/config.h.in +++ b/include/config.h.in @@ -36,10 +36,6 @@ /* Define to 1 if you have the <cups/ppd.h> header file. */ #undef HAVE_CUPS_PPD_H -/* Define to 1 if you have the <DiskArbitration/DiskArbitration.h> header - file. */ -#undef HAVE_DISKARBITRATION_DISKARBITRATION_H - /* Define to 1 if you have the `dlinfo' function. */ #undef HAVE_DLINFO
participants (1)
-
Alexandre Julliard