-
Notifications
You must be signed in to change notification settings - Fork 3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
1 changed file
with
4 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -1205,10 +1205,11 @@ def generate_build_tree( | |
raise BuildError("unknown python arch") | ||
elif is_macOS(): | ||
for kvp in cmake_extra_args: | ||
Check warning Code scanning / lintrunner RUFF/B007 Warning
Loop control variable kvp not used within loop body.
See https://docs.astral.sh/ruff/rules/unused-loop-control-variable Check failure Code scanning / CodeQL Suspicious unused loop iteration variable Error
For loop variable 'kvp' is not used in the loop body.
|
||
key,value = s.split('=') | ||
if key == CMAKE_OSX_ARCHITECTURES and len(value.split(';')) == 2: | ||
key, value = s.split("=") | ||
Check failure Code scanning / lintrunner RUFF/F821 Error
Undefined name s.
See https://docs.astral.sh/ruff/rules/undefined-name |
||
if key == "CMAKE_OSX_ARCHITECTURES" and len(value.split(";")) == 2: | ||
triplet = "universal2-osx" | ||
if triplet: | ||
log.info(f"setting target triplet to {triplet}") | ||
add_default_definition(cmake_extra_defines, "VCPKG_TARGET_TRIPLET", triplet) | ||
|
||
# By default on Windows we currently support only cross compiling for ARM/ARM64 | ||
|
@@ -1391,7 +1392,7 @@ def generate_build_tree( | |
raise BuildError("You must set dml_path or dml_external_project when building with the GDK.") | ||
|
||
if is_macOS() and not args.android: | ||
cmake_args += ["-DCMAKE_OSX_ARCHITECTURES=" + args.osx_arch] | ||
add_default_definition(cmake_extra_defines, "CMAKE_OSX_ARCHITECTURES", args.osx_arch) | ||
if args.apple_deploy_target: | ||
cmake_args += ["-DCMAKE_OSX_DEPLOYMENT_TARGET=" + args.apple_deploy_target] | ||
# Code sign the binaries, if the code signing development identity and/or team id are provided | ||
|