This repository has been archived on 2026-09-06. You can view files and clone it. You cannot open issues or pull requests or push a commit.
Files
Volodymyr Shymanskyy 6b8bcb1e07
publish / wasm3-strace-win-x64 (push) Canceled after 0s
publish / wasm3-win-x86 (push) Canceled after 0s
publish / wasm3-win-x64 (push) Canceled after 0s
publish / wasm3-linux-x64 (push) Canceled after 0s
publish / wasm3-cosmopolitan (push) Canceled after 0s
publish / wasm3-wasi (push) Canceled after 0s
publish / wasm3-android-coremark (push) Canceled after 0s
tests / linux-clang-no-uvwasi (push) Canceled after 0s
tests / linux-clang-no-uvwasi-debug (push) Canceled after 0s
tests / linux-clang-x86 (push) Canceled after 0s
tests / linux-clang (push) Canceled after 0s
tests / linux-gcc-no-uvwasi (push) Canceled after 0s
tests / linux-gcc-debug (push) Canceled after 0s
tests / linux-gcc (push) Canceled after 0s
tests / linux-alpine (push) Canceled after 0s
tests / macos-no-uvwasi (push) Canceled after 0s
tests / macos-uvwasi (push) Canceled after 0s
tests / windows-clang-x86-no-uvwasi (push) Canceled after 0s
tests / windows-msvc-x86-no-uvwasi (push) Canceled after 0s
tests / windows-clang-x64-no-uvwasi (push) Canceled after 0s
tests / windows-msvc-x64-no-uvwasi (push) Canceled after 0s
tests / windows-clang-x86 (push) Canceled after 0s
tests / windows-msvc-x86 (push) Canceled after 0s
tests / windows-clang-x64 (push) Canceled after 0s
tests / windows-msvc-x64 (push) Canceled after 0s
tests / wasi (push) Canceled after 0s
tests / ios (push) Canceled after 0s
tests / android (push) Canceled after 0s
tests / python (push) Canceled after 0s
tests / cosmopolitan (push) Canceled after 0s
tests / cross-qemu-aarch64 (u64 slots) (push) Canceled after 0s
tests / cross-qemu-aarch64 (push) Canceled after 0s
tests / cross-qemu-alpha (push) Canceled after 0s
tests / cross-qemu-arm (u64 slots) (push) Canceled after 0s
tests / cross-qemu-arm (push) Canceled after 0s
tests / cross-qemu-armhf (push) Canceled after 0s
tests / cross-qemu-mips (push) Canceled after 0s
tests / cross-qemu-mips64 (push) Canceled after 0s
tests / cross-qemu-mips64el (push) Canceled after 0s
tests / cross-qemu-mipsel (push) Canceled after 0s
tests / cross-qemu-ppc (u64 slots) (push) Canceled after 0s
tests / cross-qemu-ppc (push) Canceled after 0s
tests / cross-qemu-ppc64 (u64 slots) (push) Canceled after 0s
tests / cross-qemu-ppc64 (push) Canceled after 0s
tests / cross-qemu-riscv64 (push) Canceled after 0s
tests / cross-qemu-s390x (push) Canceled after 0s
tests / cross-qemu-sparc64 (push) Canceled after 0s
tests / platformio (push) Canceled after 0s
tests / platformio-arm (push) Canceled after 0s
tests / platformio-riscv (push) Canceled after 0s
tests / particle (push) Canceled after 0s
tests / esp32-idf (push) Canceled after 0s
tests / cpp (push) Canceled after 0s
tests / maintenance (build as C++) (push) Canceled after 0s
tests / maintenance (debug logs) (push) Canceled after 0s
tests / maintenance (preprocess ops) (push) Canceled after 0s
tests / spellcheck (push) Canceled after 0s
Fix build
2021-06-02 13:40:14 +03:00

40 lines
1.2 KiB
Makefile

.PHONY: format
all:
format:
# Convert tabs to spaces
find ./source -type f -iname '*.[cpp\|c\|h]' -exec bash -c 'expand -t 4 "$$0" | sponge "$$0"' {} \;
# Remove trailing whitespaces
find ./source -type f -iname '*.[cpp\|c\|h]' -exec sed -i 's/ *$$//' {} \;
preprocess: preprocess_restore
cp ./source/m3_exec.h ./source/m3_exec.h.bak
cp ./source/m3_compile.c ./source/m3_compile.c.bak
awk 'BEGIN {RS=""}{gsub(/\\\n/,"\\\n__NL__ ")}1' ./source/m3_exec.h | sponge ./source/m3_exec.h
cpp -I./source -P ./source/m3_compile.c | sponge ./source/m3_compile.c
awk '{gsub(/__NL__/,"\n")}1' ./source/m3_compile.c | sponge ./source/m3_compile.c
mv ./source/m3_exec.h.bak ./source/m3_exec.h
preprocess_restore:
-mv source/m3_compile.c.bak source/m3_compile.c
touch source/m3_compile.c
test_rv64:
riscv64-linux-gnu-gcc -DDEBUG -Dd_m3HasWASI \
-I./source ./source/*.c ./platforms/app/main.c \
-O3 -g0 -flto -lm -static \
-o wasm3-rv64
cd test; python3 run-wasi-test.py --fast --exec "qemu-riscv64-static ../wasm3-rv64"
rm ./wasm3-rv64
test_cpp:
clang -xc++ -Dd_m3HasWASI \
-I./source ./source/*.c ./platforms/app/main.c \
-O3 -g0 -flto -lm -static \
-o wasm3-cpp
cd test; python3 run-wasi-test.py --fast --exec "../wasm3-cpp"
rm ./wasm3-cpp