Mercurial > hg > orthanc-stone
comparison Applications/Samples/build-wasm.sh @ 435:e641d3978856 am-vsol-upgrade
WasmWebService now using BaseWebService and supporting cache
author | am@osimis.io |
---|---|
date | Tue, 04 Dec 2018 11:52:43 +0100 |
parents | be2660b6e40a |
children | ee41b6a017d7 3fd8e4e5f93e |
comparison
equal
deleted
inserted
replaced
434:3a8bcc45c221 | 435:e641d3978856 |
---|---|
1 #!/bin/bash | 1 #!/bin/bash |
2 # | |
3 # usage: | |
4 # to build all targets: | |
5 # ./build-wasm.sh | |
6 # | |
7 # to build a single target: | |
8 # ./build-wasm.sh OrthancStoneSingleFrameEditor | |
2 | 9 |
3 set -e | 10 set -e |
11 | |
12 target=${1:-all} | |
4 | 13 |
5 currentDir=$(pwd) | 14 currentDir=$(pwd) |
6 samplesRootDir=$(pwd) | 15 samplesRootDir=$(pwd) |
7 | 16 |
8 mkdir -p $samplesRootDir/build-wasm | 17 mkdir -p $samplesRootDir/build-wasm |
9 cd $samplesRootDir/build-wasm | 18 cd $samplesRootDir/build-wasm |
10 | 19 |
11 source ~/Downloads/emsdk/emsdk_env.sh | 20 source ~/Downloads/emsdk/emsdk_env.sh |
12 cmake -DCMAKE_TOOLCHAIN_FILE=${EMSCRIPTEN}/cmake/Modules/Platform/Emscripten.cmake -DCMAKE_BUILD_TYPE=Release -DSTONE_SOURCES_DIR=$currentDir/../../../orthanc-stone -DORTHANC_FRAMEWORK_SOURCE=path -DORTHANC_FRAMEWORK_ROOT=$currentDir/../../../orthanc -DALLOW_DOWNLOADS=ON .. -DENABLE_WASM=ON | 21 cmake -DCMAKE_TOOLCHAIN_FILE=${EMSCRIPTEN}/cmake/Modules/Platform/Emscripten.cmake -DCMAKE_BUILD_TYPE=Release -DSTONE_SOURCES_DIR=$currentDir/../../../orthanc-stone -DORTHANC_FRAMEWORK_SOURCE=path -DORTHANC_FRAMEWORK_ROOT=$currentDir/../../../orthanc -DALLOW_DOWNLOADS=ON .. -DENABLE_WASM=ON |
13 make -j 5 | 22 make -j 5 $target |
14 | 23 |
15 echo "-- building the web application -- " | 24 echo "-- building the web application -- " |
16 cd $currentDir | 25 cd $currentDir |
17 ./build-web.sh | 26 ./build-web.sh |