Skip to content

Commit e20185b

Browse files
kateinoigakukunrunner
authored andcommitted
[wasm][test] Force static library to avoid unsupported shared library build
Linking libraries without `-static` flag produces unexpected main function reference error. This is because the linker is trying to link input objects as executable, not as library.
1 parent 6eb4d25 commit e20185b

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

test/lit.cfg

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1846,7 +1846,7 @@ elif run_os == 'wasi':
18461846
config.swift_driver_test_options, swift_execution_tests_extra_flags])
18471847
config.target_codesign = "echo"
18481848
config.target_build_swift_dylib = (
1849-
"%s -parse-as-library -emit-library -o '\\1'"
1849+
"%s -parse-as-library -emit-library -static -o '\\1'"
18501850
% (config.target_build_swift))
18511851
config.target_add_rpath = ''
18521852
config.target_swift_frontend = ' '.join([

0 commit comments

Comments
 (0)