pull/640/head
Sy Brand 4 months ago
parent 8225def9ec
commit 10168e3c32

@ -157,6 +157,7 @@ jobs:
build-only-sysroot:
name: Build only sysroot - ${{ matrix.name }}
runs-on: ubuntu-24.04
needs: build # Add dependency
strategy:
matrix:
include:
@ -170,10 +171,16 @@ jobs:
- uses: ./.github/actions/checkout
- uses: ./.github/actions/install-deps
- run: cargo install wasm-component-ld@0.5.21
- run: sudo apt-get update -y && sudo apt-get install -y clang-20 lld-20
- uses: actions/download-artifact@v4
with:
name: dist-x86_64-linux
path: dist-x86_64-linux
- run: ./ci/merge-artifacts.sh
- run: tar xf dist/wasi-sdk-*.tar.gz
- run: |
WASI_SDK_DIR=$(ls -d ./wasi-sdk-* | head -1)
cmake -G Ninja -B build -S . \
-DCMAKE_C_COMPILER=/usr/lib/llvm-20/bin/clang \
-DCMAKE_C_COMPILER=$WASI_SDK_DIR/bin/clang \
-DCMAKE_SYSTEM_NAME=WASI \
-DWASI_SDK_INCLUDE_TESTS=ON \
-DWASI_SDK_CPU_CFLAGS="" \

@ -133,8 +133,12 @@ function(define_wasi_libc_sub target target_suffix lto)
get_property(directory_cflags DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR} PROPERTY COMPILE_OPTIONS)
set(extra_cflags_list "${WASI_SDK_CPU_CFLAGS} ${CMAKE_C_FLAGS} ${directory_cflags}")
if(${target} MATCHES p2 OR ${target} MATCHES p3)
# Always enable `-fPIC` for the `wasm32-wasip2` and `wasm32-wasip3` targets. This makes `libc.a`
if(${target} MATCHES p3)
list(APPEND extra_cmake_args -DBUILD_SHARED=OFF)
endif()
if(${target} MATCHES p2)
# Always enable `-fPIC` for the `wasm32-wasip2` targets. This makes `libc.a`
# more flexible and usable in dynamic linking situations.
list(APPEND extra_cflags_list -fPIC)
endif()
@ -205,7 +209,7 @@ execute_process(
OUTPUT_STRIP_TRAILING_WHITESPACE)
function(define_libcxx_sub target target_suffix extra_target_flags extra_libdir_suffix)
if(${target} MATCHES threads)
if(${target} MATCHES threads OR ${target} MATCHES p3)
set(pic OFF)
set(target_flags -pthread)
else()

@ -1 +1 @@
Subproject commit 36ea1dfb7e24cdbcc4d8fb5bacd1d22dd0f470c3
Subproject commit c8d54204f931757599092965975da00eb218a9fd

@ -1 +1 @@
Subproject commit 5b95b096c157ad5a201150f146bc1d1ea2817650
Subproject commit 36d2c170d7d71daf2cae71727d446a1fc5211b18

@ -83,7 +83,7 @@ function(add_testcase runwasi test)
endif()
# Apply target-specific options.
if(target MATCHES threads)
if(target MATCHES threads OR target MATCHES p3)
target_compile_options(${target_name} PRIVATE -pthread)
target_link_options(${target_name} PRIVATE -pthread)
endif()
@ -102,7 +102,7 @@ function(add_testcase runwasi test)
if(WASI_SDK_EXCEPTIONS)
set(runner "${runner} -Wexceptions")
endif()
if(target MATCHES "wasip3")
if(target MATCHES p3)
set(runner "${runner} -Wcomponent-model-async -Wcomponent-model-threading -Sp3")
endif()
endif()

@ -1,7 +1,7 @@
Error: failed to run main module `abort.c.---.wasm`
Caused by:
0: failed to invoke ---
1: error while executing at wasm backtrace:
note: using the `WASMTIME_BACKTRACE_DETAILS=1` environment variable may show more debugging information
2: wasm trap: wasm `unreachable` instruction executed
0: error while executing at wasm backtrace:
note: using the `WASMTIME_BACKTRACE_DETAILS=1` environment variable may show more debugging information
1: wasm trap: wasm `unreachable` instruction executed

@ -2,7 +2,7 @@ Assertion failed: false (assert-fail.c: main: 9)
Error: failed to run main module `assert-fail.c.---.wasm`
Caused by:
0: failed to invoke ---
1: error while executing at wasm backtrace:
note: using the `WASMTIME_BACKTRACE_DETAILS=1` environment variable may show more debugging information
2: wasm trap: wasm `unreachable` instruction executed
0: error while executing at wasm backtrace:
note: using the `WASMTIME_BACKTRACE_DETAILS=1` environment variable may show more debugging information
1: wasm trap: wasm `unreachable` instruction executed

@ -3,4 +3,4 @@ Program received fatal signal: Aborted
Error: failed to run main module `sigabrt.c.---.wasm`
Caused by:
0: failed to invoke ---
0: error while executing at wasm backtrace:

Loading…
Cancel
Save