From 800ba0d58b65f1ba0fd412f6d0ba2febe9be3eb0 Mon Sep 17 00:00:00 2001 From: Yureka Date: Tue, 3 Aug 2021 20:23:29 +0200 Subject: [PATCH] emscripten: generate libembind*.a Previously building applications/libraries with "--bind" would not be covered by the cache. --- pkgs/development/compilers/emscripten/default.nix | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/pkgs/development/compilers/emscripten/default.nix b/pkgs/development/compilers/emscripten/default.nix index 47ae2f76b750..84520ca52e08 100644 --- a/pkgs/development/compilers/emscripten/default.nix +++ b/pkgs/development/compilers/emscripten/default.nix @@ -92,9 +92,11 @@ stdenv.mkDerivation rec { # wasm2c doesn't work with PIC $out/bin/emcc -s WASM2C -s STANDALONE_WASM $LTO test.c - for MT in "" "-s USE_PTHREADS"; do - for RELOCATABLE in "" "-s RELOCATABLE"; do - $out/bin/emcc $RELOCATABLE $MT $LTO test.c + for BIND in "" "--bind"; do + for MT in "" "-s USE_PTHREADS"; do + for RELOCATABLE in "" "-s RELOCATABLE"; do + $out/bin/emcc $RELOCATABLE $BIND $MT $LTO test.c + done done done done