2019-12-12 01:04:29 +00:00
|
|
|
diff a/build/unix/compiledata.sh b/build/unix/compiledata.sh
|
2016-08-20 09:32:09 +01:00
|
|
|
--- a/build/unix/compiledata.sh
|
|
|
|
+++ b/build/unix/compiledata.sh
|
2019-12-12 01:04:29 +00:00
|
|
|
@@ -47,7 +47,7 @@ fi
|
2016-08-20 09:32:09 +01:00
|
|
|
|
|
|
|
if [ "$ARCH" = "macosx" ] || [ "$ARCH" = "macosx64" ] || \
|
|
|
|
[ "$ARCH" = "macosxicc" ]; then
|
|
|
|
- macosx_minor=`sw_vers | sed -n 's/ProductVersion://p' | cut -d . -f 2`
|
2019-12-12 01:04:29 +00:00
|
|
|
+ macosx_minor=12
|
2016-08-20 09:32:09 +01:00
|
|
|
SOEXT="so"
|
|
|
|
if [ $macosx_minor -ge 5 ]; then
|
|
|
|
if [ "x`echo $SOFLAGS | grep -- '-install_name'`" != "x" ]; then
|
2019-12-12 01:04:29 +00:00
|
|
|
diff a/cmake/modules/SetUpMacOS.cmake b/cmake/modules/SetUpMacOS.cmake
|
2016-08-20 09:32:09 +01:00
|
|
|
--- a/cmake/modules/SetUpMacOS.cmake
|
|
|
|
+++ b/cmake/modules/SetUpMacOS.cmake
|
2019-12-12 01:04:29 +00:00
|
|
|
@@ -2,17 +2,8 @@ set(ROOT_ARCHITECTURE macosx)
|
|
|
|
set(ROOT_PLATFORM macosx)
|
2016-08-20 09:32:09 +01:00
|
|
|
|
|
|
|
if (CMAKE_SYSTEM_NAME MATCHES Darwin)
|
|
|
|
- EXECUTE_PROCESS(COMMAND sw_vers "-productVersion"
|
|
|
|
- COMMAND cut -d . -f 1-2
|
|
|
|
- OUTPUT_VARIABLE MACOSX_VERSION OUTPUT_STRIP_TRAILING_WHITESPACE)
|
2019-12-12 01:04:29 +00:00
|
|
|
-
|
2016-08-20 09:32:09 +01:00
|
|
|
- MESSAGE(STATUS "Found a Mac OS X System ${MACOSX_VERSION}")
|
|
|
|
-
|
2017-04-26 04:28:13 +01:00
|
|
|
- if(MACOSX_VERSION VERSION_GREATER 10.7 AND ${CMAKE_CXX_COMPILER_ID} MATCHES Clang)
|
2016-08-20 09:32:09 +01:00
|
|
|
set(libcxx ON CACHE BOOL "Build using libc++" FORCE)
|
|
|
|
- endif()
|
|
|
|
|
2019-12-12 01:04:29 +00:00
|
|
|
- if(MACOSX_VERSION VERSION_GREATER 10.4)
|
2016-08-20 09:32:09 +01:00
|
|
|
#TODO: check haveconfig and rpath -> set rpath true
|
|
|
|
#TODO: check Thread, define link command
|
|
|
|
#TODO: more stuff check configure script
|
2019-12-12 01:04:29 +00:00
|
|
|
@@ -25,23 +16,7 @@ if (CMAKE_SYSTEM_NAME MATCHES Darwin)
|
2016-08-20 09:32:09 +01:00
|
|
|
SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -m64")
|
|
|
|
SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -m64")
|
2016-12-31 03:02:50 +00:00
|
|
|
SET(CMAKE_Fortran_FLAGS "${CMAKE_Fortran_FLAGS} -m64")
|
2019-12-12 01:04:29 +00:00
|
|
|
- else()
|
2016-08-20 09:32:09 +01:00
|
|
|
- MESSAGE(STATUS "Found a 32bit system")
|
|
|
|
- SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -m32")
|
|
|
|
- SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -m32")
|
2016-12-31 03:02:50 +00:00
|
|
|
- SET(CMAKE_Fortran_FLAGS "${CMAKE_Fortran_FLAGS} -m32")
|
2019-12-12 01:04:29 +00:00
|
|
|
- endif()
|
2016-08-20 09:32:09 +01:00
|
|
|
- endif()
|
|
|
|
-
|
|
|
|
- if(MACOSX_VERSION VERSION_GREATER 10.6)
|
|
|
|
- set(MACOSX_SSL_DEPRECATED ON)
|
|
|
|
- endif()
|
|
|
|
- if(MACOSX_VERSION VERSION_GREATER 10.7)
|
|
|
|
- set(MACOSX_ODBC_DEPRECATED ON)
|
|
|
|
- endif()
|
|
|
|
- if(MACOSX_VERSION VERSION_GREATER 10.8)
|
|
|
|
- set(MACOSX_GLU_DEPRECATED ON)
|
|
|
|
- endif()
|
2019-12-12 01:04:29 +00:00
|
|
|
+ endif()
|
2016-08-20 09:32:09 +01:00
|
|
|
|
|
|
|
if (CMAKE_COMPILER_IS_GNUCXX)
|
|
|
|
message(STATUS "Found GNU compiler collection")
|
2019-12-12 01:04:29 +00:00
|
|
|
@@ -104,7 +79,6 @@ if (CMAKE_SYSTEM_NAME MATCHES Darwin)
|
2016-08-20 09:32:09 +01:00
|
|
|
endif()
|
|
|
|
|
|
|
|
#---Set Linker flags----------------------------------------------------------------------
|
2019-12-12 01:04:29 +00:00
|
|
|
- set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -mmacosx-version-min=${MACOSX_VERSION}")
|
2016-08-20 09:32:09 +01:00
|
|
|
else (CMAKE_SYSTEM_NAME MATCHES Darwin)
|
2019-12-12 01:04:29 +00:00
|
|
|
MESSAGE(FATAL_ERROR "There is no setup for this this Apple system up to now. Don't know waht to do. Stop cmake at this point.")
|
|
|
|
endif (CMAKE_SYSTEM_NAME MATCHES Darwin)
|
|
|
|
diff a/config/root-config.in b/config/root-config.in
|
2016-08-20 09:32:09 +01:00
|
|
|
--- a/config/root-config.in
|
|
|
|
+++ b/config/root-config.in
|
2019-12-12 01:04:29 +00:00
|
|
|
@@ -306,12 +306,6 @@ macosxicc)
|
|
|
|
auxlibs="-lm -ldl"
|
2016-08-20 09:32:09 +01:00
|
|
|
;;
|
|
|
|
macosx64)
|
2019-12-12 01:04:29 +00:00
|
|
|
- # MacOS X with gcc (GNU cc v4.x) in 64 bit mode
|
2016-08-20 09:32:09 +01:00
|
|
|
- macosx_minor=`sw_vers | sed -n 's/ProductVersion://p' | cut -d . -f 2`
|
2019-12-12 01:04:29 +00:00
|
|
|
- # cannot find the one linked to libGraf if relocated after built
|
|
|
|
- if [ $macosx_minor -le 4 ]; then
|
|
|
|
- rootlibs="$rootlibs -lfreetype"
|
|
|
|
- fi
|
|
|
|
auxcflags="${cxxversionflag} -m64"
|
|
|
|
auxldflags="-m64"
|
|
|
|
auxlibs="-lm -ldl"
|
|
|
|
@@ -375,18 +369,11 @@ freebsd* | openbsd* | linux*)
|
|
|
|
macosx*)
|
|
|
|
for f in $features ; do
|
|
|
|
if test "x$f" = "xthread" ; then
|
|
|
|
- if [ $macosx_minor -ge 5 ]; then
|
|
|
|
auxcflags="-pthread $auxcflags"
|
|
|
|
auxlibs="-lpthread $auxlibs"
|
|
|
|
- else
|
|
|
|
- auxcflags="-D_REENTRANT $auxcflags"
|
|
|
|
- auxlibs="-lpthread $auxlibs"
|
|
|
|
- fi
|
|
|
|
fi
|
|
|
|
if test "x$f" = "xrpath" ; then
|
|
|
|
- if [ $macosx_minor -ge 5 ]; then
|
|
|
|
auxlibs="-Wl,-rpath,$libdir $auxlibs"
|
|
|
|
- fi
|
|
|
|
fi
|
|
|
|
if test "x$f" = "xlibcxx" ; then
|
|
|
|
auxcflags="-stdlib=libc++ $auxcflags"
|