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
SR-648: Allow swiftpm to statically link binaries on Linux
- If --build-swift-static-stdlib option is used then also produce
static versions of libXCTest.a and libdispatch.a and put them
into the lib/swift_static/linux/ toolchain directory.
libFoundation.a is already being built and deployed there.
- Binaries with the swift libs statically linked in can then be
built with using the command:
swift build -Xswiftc -static-stdlib -Xlinker -lcurl -Xlinker -l:libxml2.a -Xlinker -llzma -Xlinker /lib/x86_64-linux-gnu/libz.so.1 -Xlinker -lbsd -Xlinker --allow-multiple-definition
Note: This is a dynamic binary with the libswiftCore,
libFoundation and libdispatch libraries statically linked in.
- Further fixes should reduce the complexity of the above command.
0 commit comments