aboutsummaryrefslogtreecommitdiffhomepage
path: root/Makefile
diff options
context:
space:
mode:
authorAyke van Laethem <[email protected]>2019-01-25 21:36:34 +0100
committerAyke van Laethem <[email protected]>2019-02-01 13:26:32 +0100
commit9bbb233cf02be8f0521bfbc6f96f70c8a0c5c6b8 (patch)
tree76e39cf67277bbd0a28c8a6d0656be17407a1610 /Makefile
parent5b507593d20acbb7e822b7cb28588c9ec383d499 (diff)
downloadtinygo-9bbb233cf02be8f0521bfbc6f96f70c8a0c5c6b8.tar.gz
tinygo-9bbb233cf02be8f0521bfbc6f96f70c8a0c5c6b8.zip
main: include prebuilt compiler-rt libraries in release tarball
This avoids depending on clang-7 to build compiler-rt for the most common ARM microcontrollers.
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile6
1 files changed, 6 insertions, 0 deletions
diff --git a/Makefile b/Makefile
index cc78a2967..c913c92d0 100644
--- a/Makefile
+++ b/Makefile
@@ -117,6 +117,9 @@ release: static gen-device
@mkdir -p build/release/tinygo/lib/CMSIS/CMSIS
@mkdir -p build/release/tinygo/lib/compiler-rt/lib
@mkdir -p build/release/tinygo/lib/nrfx
+ @mkdir -p build/release/tinygo/pkg/armv6m-none-eabi
+ @mkdir -p build/release/tinygo/pkg/armv7m-none-eabi
+ @mkdir -p build/release/tinygo/pkg/armv7em-none-eabi
@cp -p build/tinygo build/release/tinygo/bin
@cp -rp lib/CMSIS/CMSIS/Include build/release/tinygo/lib/CMSIS/CMSIS
@cp -rp lib/CMSIS/README.md build/release/tinygo/lib/CMSIS
@@ -126,6 +129,9 @@ release: static gen-device
@cp -rp lib/nrfx/* build/release/tinygo/lib/nrfx
@cp -rp src build/release/tinygo/src
@cp -rp targets build/release/tinygo/targets
+ ./build/tinygo build-builtins -target=armv6m-none-eabi -o build/release/tinygo/pkg/armv6m-none-eabi/compiler-rt.a
+ ./build/tinygo build-builtins -target=armv7m-none-eabi -o build/release/tinygo/pkg/armv7m-none-eabi/compiler-rt.a
+ ./build/tinygo build-builtins -target=armv7em-none-eabi -o build/release/tinygo/pkg/armv7em-none-eabi/compiler-rt.a
tar -czf build/release.tar.gz -C build/release tinygo
# Binary that can run on the host.