diff options
author | jan.nijtmans <nijtmans@users.sourceforge.net> | 2022-04-20 11:27:34 (GMT) |
---|---|---|
committer | jan.nijtmans <nijtmans@users.sourceforge.net> | 2022-04-20 11:27:34 (GMT) |
commit | 8837a1f1bb385b66b875d760a427bcb66b8f8a73 (patch) | |
tree | e0d2699fe06f4845c72ebe6439519730fafff8f0 /macosx | |
parent | b80552437af293244ff1d5c1418ae376c4efd9bd (diff) | |
download | tcl-8837a1f1bb385b66b875d760a427bcb66b8f8a73.zip tcl-8837a1f1bb385b66b875d760a427bcb66b8f8a73.tar.gz tcl-8837a1f1bb385b66b875d760a427bcb66b8f8a73.tar.bz2 |
Fix [https://core.tcl-lang.org/tk/tktview?name=bf0f4808d7|bf0f4808d7]: macOS Aqua : CFLAGS_OPTIMIZE
Diffstat (limited to 'macosx')
-rw-r--r-- | macosx/README | 11 | ||||
-rw-r--r-- | macosx/Tcl-Release.xcconfig | 2 | ||||
-rw-r--r-- | macosx/Tcl.xcode/project.pbxproj | 16 | ||||
-rw-r--r-- | macosx/Tcl.xcodeproj/project.pbxproj | 20 |
4 files changed, 22 insertions, 27 deletions
diff --git a/macosx/README b/macosx/README index 3035bc8..9b8ecb8 100644 --- a/macosx/README +++ b/macosx/README @@ -118,13 +118,10 @@ your ${USER}.pbxuser file (located inside the Tcl.xcodeproj bundle directory) with a text editor. - To build universal binaries outside of the Xcode IDE, set CFLAGS as follows: - export CFLAGS="-arch i386 -arch x86_64 -arch ppc" -This requires Mac OS X 10.4 and Xcode 2.4 (or Xcode 2.2 if -arch x86_64 is -omitted, but _not_ Xcode 2.1) and will work on any architecture (on PowerPC -Tiger you need to add "-isysroot /Developer/SDKs/MacOSX10.4u.sdk"). + export CFLAGS="-arch x86_64 -arch arm64e" +This requires Mac OS X 10.4 and Xcode 2.4 and will work on any architecture. Note that configure requires CFLAGS to contain a least one architecture that can -be run on the build machine (i.e. ppc on G3/G4, ppc or ppc64 on G5, ppc or i386 -on Core and ppc, i386 or x86_64 on Core2/Xeon). +be run on the build machine (i.e. x86_64 on Core2/Xeon). Universal builds of Tcl TEA extensions are also possible with CFLAGS set as above, they will be [load]able by universal as well as thin binaries of Tcl. @@ -141,7 +138,7 @@ If you are building from CVS, omit this step (CVS source tree names usually do not contain a version number). - Setup environment variables as desired, e.g. for a universal build on 10.5: - CFLAGS="-arch i386 -arch x86_64 -arch ppc -mmacosx-version-min=10.5" + CFLAGS="-arch x86_64 -arch arm64e -mmacosx-version-min=10.5" export CFLAGS - Change to the directory containing the Tcl source tree and build: diff --git a/macosx/Tcl-Release.xcconfig b/macosx/Tcl-Release.xcconfig index d960a52..867ee78 100644 --- a/macosx/Tcl-Release.xcconfig +++ b/macosx/Tcl-Release.xcconfig @@ -14,7 +14,7 @@ DEBUG_INFORMATION_FORMAT = dwarf-with-dsym DEAD_CODE_STRIPPING = YES DEPLOYMENT_POSTPROCESSING = YES -GCC_OPTIMIZATION_LEVEL = s +GCC_OPTIMIZATION_LEVEL = 2 GCC_PREPROCESSOR_DEFINITIONS = NDEBUG $(TCL_DEFS) $(GCC_PREPROCESSOR_DEFINITIONS) CONFIGURE_ARGS = --disable-symbols $(TCL_CONFIGURE_ARGS) $(CONFIGURE_ARGS) MAKE_TARGET = deploy diff --git a/macosx/Tcl.xcode/project.pbxproj b/macosx/Tcl.xcode/project.pbxproj index 0746261..09e5e8b 100644 --- a/macosx/Tcl.xcode/project.pbxproj +++ b/macosx/Tcl.xcode/project.pbxproj @@ -2133,8 +2133,8 @@ isa = XCBuildConfiguration; baseConfigurationReference = F97AE82B0B65C69B00310EA2 /* Tcl-Release.xcconfig */; buildSettings = { - ARCHS = "$(ARCHS_STANDARD_32_64_BIT)"; - CFLAGS = "-arch i386 -arch x86_64 -arch ppc $(CFLAGS)"; + ARCHS = "$(ARCHS_STANDARD_64_BIT)"; + CFLAGS = "-arch x86_64 -arch arm64e $(CFLAGS)"; MACOSX_DEPLOYMENT_TARGET = 10.5; PREBINDING = NO; }; @@ -2598,8 +2598,8 @@ isa = XCBuildConfiguration; baseConfigurationReference = F97AE82B0B65C69B00310EA2 /* Tcl-Release.xcconfig */; buildSettings = { - ARCHS = "$(ARCHS_STANDARD_32_64_BIT)"; - CFLAGS = "-arch i386 -arch x86_64 -arch ppc $(CFLAGS)"; + ARCHS = "$(ARCHS_STANDARD_64_BIT)"; + CFLAGS = "-arch x86_64 -arch arm64e $(CFLAGS)"; GCC_VERSION = 4.0; MACOSX_DEPLOYMENT_TARGET = 10.5; PREBINDING = NO; @@ -2636,8 +2636,8 @@ isa = XCBuildConfiguration; baseConfigurationReference = F97AE82B0B65C69B00310EA2 /* Tcl-Release.xcconfig */; buildSettings = { - ARCHS = "$(ARCHS_STANDARD_32_64_BIT)"; - CFLAGS = "-arch i386 -arch x86_64 -arch ppc $(CFLAGS)"; + ARCHS = "$(ARCHS_STANDARD_64_BIT)"; + CFLAGS = "-arch x86_64 -arch arm64e $(CFLAGS)"; DEBUG_INFORMATION_FORMAT = dwarf; GCC = "llvm-gcc"; GCC_OPTIMIZATION_LEVEL = 4; @@ -2790,8 +2790,8 @@ isa = XCBuildConfiguration; baseConfigurationReference = F97AE82B0B65C69B00310EA2 /* Tcl-Release.xcconfig */; buildSettings = { - ARCHS = "$(ARCHS_STANDARD_32_64_BIT)"; - CFLAGS = "-arch i386 -arch x86_64 -arch ppc $(CFLAGS)"; + ARCHS = "$(ARCHS_STANDARD_64_BIT)"; + CFLAGS = "-arch x86_64 -arch arm64e $(CFLAGS)"; CPPFLAGS = "-isysroot $(SDKROOT) $(CPPFLAGS)"; MACOSX_DEPLOYMENT_TARGET = 10.5; PREBINDING = NO; diff --git a/macosx/Tcl.xcodeproj/project.pbxproj b/macosx/Tcl.xcodeproj/project.pbxproj index 6bb3417..da673a4 100644 --- a/macosx/Tcl.xcodeproj/project.pbxproj +++ b/macosx/Tcl.xcodeproj/project.pbxproj @@ -2131,8 +2131,8 @@ isa = XCBuildConfiguration; baseConfigurationReference = F97AE82B0B65C69B00310EA2 /* Tcl-Release.xcconfig */; buildSettings = { - ARCHS = "$(ARCHS_STANDARD_32_64_BIT)"; - CFLAGS = "-arch i386 -arch x86_64 -arch ppc $(CFLAGS)"; + ARCHS = "$(ARCHS_STANDARD_64_BIT)"; + CFLAGS = "-arch x86_64 -arch arm64e $(CFLAGS)"; MACOSX_DEPLOYMENT_TARGET = 10.6; PREBINDING = NO; }; @@ -2596,8 +2596,8 @@ isa = XCBuildConfiguration; baseConfigurationReference = F97AE82B0B65C69B00310EA2 /* Tcl-Release.xcconfig */; buildSettings = { - ARCHS = "$(ARCHS_STANDARD_32_64_BIT)"; - CFLAGS = "-arch i386 -arch x86_64 -arch ppc $(CFLAGS)"; + ARCHS = "$(ARCHS_STANDARD_64_BIT)"; + CFLAGS = "-arch x86_64 -arch arm64e $(CFLAGS)"; GCC_VERSION = 4.0; MACOSX_DEPLOYMENT_TARGET = 10.6; PREBINDING = NO; @@ -2634,12 +2634,11 @@ isa = XCBuildConfiguration; baseConfigurationReference = F97AE82B0B65C69B00310EA2 /* Tcl-Release.xcconfig */; buildSettings = { - ARCHS = "$(ARCHS_STANDARD_32_64_BIT)"; - CFLAGS = "-arch i386 -arch x86_64 -arch ppc $(CFLAGS)"; + ARCHS = "$(ARCHS_STANDARD_64_BIT)"; + CFLAGS = "-arch x86_64 -arch arm64e $(CFLAGS)"; DEBUG_INFORMATION_FORMAT = dwarf; GCC = "llvm-gcc"; GCC_OPTIMIZATION_LEVEL = 4; - "GCC_OPTIMIZATION_LEVEL[arch=ppc]" = s; GCC_VERSION = com.apple.compilers.llvmgcc42; MACOSX_DEPLOYMENT_TARGET = 10.6; PREBINDING = NO; @@ -2817,9 +2816,8 @@ buildSettings = { ARCHS = ( "$(NATIVE_ARCH_64_BIT)", - "$(NATIVE_ARCH_32_BIT)", ); - CFLAGS = "-arch i386 -arch x86_64 $(CFLAGS)"; + CFLAGS = "-arch x86_64 -arch arm64e $(CFLAGS)"; DEBUG_INFORMATION_FORMAT = dwarf; GCC = clang; GCC_OPTIMIZATION_LEVEL = 4; @@ -2885,8 +2883,8 @@ isa = XCBuildConfiguration; baseConfigurationReference = F97AE82B0B65C69B00310EA2 /* Tcl-Release.xcconfig */; buildSettings = { - ARCHS = "$(ARCHS_STANDARD_32_64_BIT)"; - CFLAGS = "-arch i386 -arch x86_64 -arch ppc $(CFLAGS)"; + ARCHS = "$(ARCHS_STANDARD_64_BIT)"; + CFLAGS = "-arch x86_64 -arch arm64e $(CFLAGS)"; CPPFLAGS = "-isysroot $(SDKROOT) $(CPPFLAGS)"; MACOSX_DEPLOYMENT_TARGET = 10.5; PREBINDING = NO; |