-
Notifications
You must be signed in to change notification settings - Fork 185
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Script changes for building static SDK with swift-foundation (#403)
* Fix Job Count Flag Hooking up the job count flag to set the number of parallel jobs and if there is an unknown flag, emit an error message saying that the flag is instead of just printing out the usage info. * Skip cmake bootstrap The cmake bootstrap is slower than using the installed CMake to build the new CMake since it has to build a limited CMake first and then use that for the full CMake. This uses the existing CMake 3.22 from the container to build the CMake from the Swift checkout with SSL disabled, testing disabled, and the interactive curses UI disabled to improve the overall build times. * Fixing flags for static SDK build Updating the C++ compiler flags. - `-stdlib=libc++`: modifies the stdlib header search paths, so that needs to be on the cxx call. - `-unwindlib=libunwind`: should only be needed on the link job, but one of the dependencies was complaining about missing unwind symbols without it, so I'm guessing they're using the wrong variable in their build system. - CMAKE_TRY_COMPILE_TARGET_TYPE=STATIC_LIBARARY: The cmake try-compile was trying to dynamically link and complaining about the missing crtbeginS.o and crtendS.o, which we shouldn't need since this is only for statically linking. One thing to note is that this will cause CMake symbol checks to emit the wrong result, saying that the symbol is always available. https://gitlab.kitware.com/cmake/cmake/-/issues/18121 Fixing the variable name in the toolchain file to specify the triple correctly. Also adding flags for hooking up the Swift-Foundation library sources. * More cleanups This patch is just general clean-ups that make iterating with the script locally a bit easier.
- Loading branch information
Showing
2 changed files
with
33 additions
and
19 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 |
---|---|---|
|
@@ -91,7 +91,3 @@ RUN groupadd -g 998 build-user && \ | |
USER build-user | ||
|
||
WORKDIR /home/build-user | ||
|
||
|
||
|
||
|
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