aboutsummaryrefslogtreecommitdiffhomepage
path: root/GNUmakefile
diff options
context:
space:
mode:
authorAyke van Laethem <[email protected]>2024-03-04 20:27:05 +0100
committerRon Evans <[email protected]>2024-03-26 12:20:50 +0100
commit7c546525ea979025c17973a6e248a2119024acbb (patch)
tree00a906fae573e4de6e14b75c4bce6b69d3be2c86 /GNUmakefile
parentd628e3e2cb6f767dc5367bc43fb14751a509404a (diff)
downloadtinygo-7c546525ea979025c17973a6e248a2119024acbb.tar.gz
tinygo-7c546525ea979025c17973a6e248a2119024acbb.zip
wasm-unknown: add math and memory builtins that LLVM needs
This new library is needed for wasm targets that aren't WASI and don't need/want a libc, but still need some intrinsics that are generated by LLVM.
Diffstat (limited to 'GNUmakefile')
-rw-r--r--GNUmakefile14
1 files changed, 12 insertions, 2 deletions
diff --git a/GNUmakefile b/GNUmakefile
index 3e0549ec1..96d8e0deb 100644
--- a/GNUmakefile
+++ b/GNUmakefile
@@ -821,7 +821,9 @@ build/release: tinygo gen-device wasi-libc $(if $(filter 1,$(USE_SYSTEM_BINARYEN
@mkdir -p build/release/tinygo/lib/nrfx
@mkdir -p build/release/tinygo/lib/picolibc/newlib/libc
@mkdir -p build/release/tinygo/lib/picolibc/newlib/libm
- @mkdir -p build/release/tinygo/lib/wasi-libc
+ @mkdir -p build/release/tinygo/lib/wasi-libc/libc-bottom-half/headers
+ @mkdir -p build/release/tinygo/lib/wasi-libc/libc-top-half/musl/arch
+ @mkdir -p build/release/tinygo/lib/wasi-libc/libc-top-half/musl/src
@mkdir -p build/release/tinygo/pkg/thumbv6m-unknown-unknown-eabi-cortex-m0
@mkdir -p build/release/tinygo/pkg/thumbv6m-unknown-unknown-eabi-cortex-m0plus
@mkdir -p build/release/tinygo/pkg/thumbv7em-unknown-unknown-eabi-cortex-m4
@@ -872,7 +874,15 @@ endif
@cp -rp lib/picolibc/newlib/libm/common build/release/tinygo/lib/picolibc/newlib/libm
@cp -rp lib/picolibc/newlib/libm/math build/release/tinygo/lib/picolibc/newlib/libm
@cp -rp lib/picolibc-stdio.c build/release/tinygo/lib
- @cp -rp lib/wasi-libc/sysroot build/release/tinygo/lib/wasi-libc/sysroot
+ @cp -rp lib/wasi-libc/libc-bottom-half/headers/public build/release/tinygo/lib/wasi-libc/libc-bottom-half/headers
+ @cp -rp lib/wasi-libc/libc-top-half/musl/arch/generic build/release/tinygo/lib/wasi-libc/libc-top-half/musl/arch
+ @cp -rp lib/wasi-libc/libc-top-half/musl/arch/wasm32 build/release/tinygo/lib/wasi-libc/libc-top-half/musl/arch
+ @cp -rp lib/wasi-libc/libc-top-half/musl/src/include build/release/tinygo/lib/wasi-libc/libc-top-half/musl/src
+ @cp -rp lib/wasi-libc/libc-top-half/musl/src/internal build/release/tinygo/lib/wasi-libc/libc-top-half/musl/src
+ @cp -rp lib/wasi-libc/libc-top-half/musl/src/math build/release/tinygo/lib/wasi-libc/libc-top-half/musl/src
+ @cp -rp lib/wasi-libc/libc-top-half/musl/src/string build/release/tinygo/lib/wasi-libc/libc-top-half/musl/src
+ @cp -rp lib/wasi-libc/libc-top-half/musl/include build/release/tinygo/lib/wasi-libc/libc-top-half/musl
+ @cp -rp lib/wasi-libc/sysroot build/release/tinygo/lib/wasi-libc/sysroot
@cp -rp llvm-project/compiler-rt/lib/builtins build/release/tinygo/lib/compiler-rt-builtins
@cp -rp llvm-project/compiler-rt/LICENSE.TXT build/release/tinygo/lib/compiler-rt-builtins
@cp -rp src build/release/tinygo/src