ruby-changes:57186
From: Nobuyoshi <ko1@a...>
Date: Tue, 20 Aug 2019 02:18:45 +0900 (JST)
Subject: [ruby-changes:57186] Nobuyoshi Nakada: 588b74e8d8 (master): Check for minimum required OSX version earlier
https://git.ruby-lang.org/ruby.git/commit/?id=588b74e8d8 From 588b74e8d84532d3eb0e4aa06372b7a6b171b9cd Mon Sep 17 00:00:00 2001 From: Nobuyoshi Nakada <nobu@r...> Date: Tue, 20 Aug 2019 01:11:28 +0900 Subject: Check for minimum required OSX version earlier diff --git a/configure.ac b/configure.ac index 8dab046..a6231b6 100644 --- a/configure.ac +++ b/configure.ac @@ -209,6 +209,21 @@ AS_CASE(["$build_os"], https://github.com/ruby/ruby/blob/trunk/configure.ac#L209 ]) test -z "$CXX" || ac_cv_prog_CXX="$CXX" +AS_CASE(["$target_os"], +[darwin*], [ + AC_MSG_CHECKING(if minimum required OS X version is supported) + AC_TRY_CPP([@%:@include <AvailabilityMacros.h> + @%:@if MAC_OS_X_VERSION_MIN_REQUIRED < __MAC_10_5 + @%:@error pre OS X 10.5 + [!<===== pre OS X 10.5 =====>] + @%:@endif + ], + [macosx_min_required=yes], + [AC_MSG_RESULT(no) + AC_MSG_ERROR([Unsupported OS X version is required])]) + AC_MSG_RESULT(${macosx_min_required}) +]) + AC_PROG_CXX RUBY_MINGW32 AC_PROG_GCC_TRADITIONAL @@ -779,20 +794,6 @@ AS_CASE(["$target_os"], https://github.com/ruby/ruby/blob/trunk/configure.ac#L794 ORIG_LIBS="$LIBS" RUBY_PREPEND_OPTION(LIBS, -lobjc) RUBY_APPEND_OPTIONS(CPPFLAGS, -D_XOPEN_SOURCE -D_DARWIN_C_SOURCE -D_DARWIN_UNLIMITED_SELECT -D_REENTRANT) - AC_MSG_CHECKING(for minimum required Mac OS X version) - AC_TRY_CPP([@%:@include <AvailabilityMacros.h> - @%:@if MAC_OS_X_VERSION_MIN_REQUIRED < __MAC_10_5 - @%:@error pre OS X 10.5 - [!<===== pre OS X 10.5 =====>] - @%:@endif - ], - [macosx_min_required=ok], [ - AC_COMPUTE_INT([macosx_min_required], [MAC_OS_X_VERSION_MIN_REQUIRED], - [AC_INCLUDES_DEFAULT([@%:@include <AvailabilityMacros.h>])], - [macosx_min_required=not-found]) - ]) - AC_MSG_RESULT(${macosx_min_required}) - test "${macosx_min_required}" = ok || AC_MSG_ERROR([Unsupported OS X version is required]) AS_IF([test "${target_os@%:@darwin}" -ge 16], [ ac_cv_func___syscall=no ac_cv_func_syscall=no -- cgit v0.10.2 -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/