Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

8257758: Allow building of JavaFX native libs for Apple Silicon #363

Closed
wants to merge 2 commits into from
Closed
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 10 additions & 1 deletion buildSrc/mac.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,11 @@ ext.MAC = [:]
MAC.canBuild = IS_MAC && IS_64
if (!MAC.canBuild) return;

def TARGET_ARCH = "x86_64"
if (hasProperty('targetArch')) {
kevinrushforth marked this conversation as resolved.
Show resolved Hide resolved
TARGET_ARCH = ext.targetArch
}

// All desktop related packages should be built
MAC.compileSwing = true;
MAC.compileSWT = true;
Expand Down Expand Up @@ -119,7 +124,11 @@ def commonParams = [
"-mmacosx-version-min=$MACOSX_MIN_VERSION",
"-isysroot", "$MACOSX_SDK_PATH",
"-iframework$MACOSX_SDK_PATH/System/Library/Frameworks",
"-arch", "x86_64"]
"-arch", "$TARGET_ARCH"]

if (hasProperty('targetArch')) {
commonParams = ["-target", "$TARGET_ARCH-apple-macos-11", commonParams]
kevinrushforth marked this conversation as resolved.
Show resolved Hide resolved
}

def ccBaseFlags = [
commonParams,
Expand Down