You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Allow using and OS X build of swift to build libraries and binaries for another
platform, only linux-armv7 is supported in this patch. Doesn't currently support
building the tools (llvm, swiftc) or the tests for linux-armv7.
* Added --cross-compile-stdlib-targets to build-script
* Added --cross-compile-sysroot to build-script-impl
* Added --cross-compile-toolchain-bin to build-script-impl
* Set -resource-dir when cross-compiling
* Use BUILD_HOST_TARGET instead of HOST_TARGET, allow it to be empty when
cross-compiling to just build cross target
* Derive PKG_CONFIG_PATH from --cross-compile-sysroot to allow find_package to
work
* Skip cmark and llvm builds completely when --native-*-tools-path flags are set
See instructions in cmake/modules/Toolchain-linux-arm.cmake. To build
linux-armv7 on osx run:
./utils/build-script -R --cross-compile-stdlib-targets linux-armv7 --
--cross-compile-sysroot=$MY_SYSROOT
--cross-compile-toolchain-bin=$MY_TOOLCHAIN_BIN
Copy file name to clipboardExpand all lines: utils/build-script-impl
+83-25Lines changed: 83 additions & 25 deletions
Original file line number
Diff line number
Diff line change
@@ -181,7 +181,9 @@ KNOWN_SETTINGS=(
181
181
install-libdispatch """whether to install libdispatch"
182
182
darwin-install-extract-symbols """whether to extract symbols with dsymutil during installations"
183
183
host-target """The host target. LLVM, Clang, and Swift will be built for this target. The built LLVM and Clang will be used to compile Swift for the cross-compilation targets. **This argument is required**"
184
-
cross-compile-tools-deployment-targets """space-separated list of targets to cross-compile host Swift tools for"
184
+
cross-compile-deployment-targets """space-separated list of targets to cross-compile Swift for"
185
+
cross-compile-sysroot """sysroot to use when cross-compiling"
186
+
cross-compile-toolchain-bin """toolchain binary dir to use when cross-compiling"
185
187
skip-merge-lipo-cross-compile-tools """set to skip running merge-lipo after installing cross-compiled host Swift tools"
186
188
darwin-deployment-version-osx "10.9""minimum deployment target version for OS X"
187
189
darwin-deployment-version-ios "7.0""minimum deployment target version for iOS"
@@ -203,6 +205,7 @@ KNOWN_SETTINGS=(
203
205
build-jobs """The number of parallel build jobs to use"
204
206
darwin-toolchain-alias """Swift alias for toolchain"
205
207
export-compile-commands """set to generate JSON compilation databases for each build product"
208
+
pkg-config-paths """Colon-separate list of paths to add to PKG_CONFIG_PATH"
206
209
)
207
210
208
211
functiontoupper() {
@@ -779,22 +782,24 @@ function cmake_needs_to_specify_standard_computed_defaults() {
779
782
fi
780
783
}
781
784
782
-
# A list of deployment targets to cross-compile the Swift host tools for.
785
+
# A list of deployment targets to cross-compile the Swift host tools/stdlib for.
783
786
# We can't run the resulting binaries on the build machine.
0 commit comments