Mercurial > hg > orthanc-stone
annotate Applications/Samples/rt-viewer-demo/build-wasm.sh @ 1307:8a28a9bf8876 broker
ViewportController now gets a ref to its parent viewport for proper lock usage
author | Benjamin Golinvaux <bgo@osimis.io> |
---|---|
date | Wed, 04 Mar 2020 10:07:37 +0100 |
parents | 1d9deb4ee84c |
children |
rev | line source |
---|---|
549
1d9deb4ee84c
Added RTSTRUCT demo viewer based on captain + fix in dev.h (wrong override signature)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
1 #!/bin/bash |
1d9deb4ee84c
Added RTSTRUCT demo viewer based on captain + fix in dev.h (wrong override signature)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
2 # |
1d9deb4ee84c
Added RTSTRUCT demo viewer based on captain + fix in dev.h (wrong override signature)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
3 # usage: |
1d9deb4ee84c
Added RTSTRUCT demo viewer based on captain + fix in dev.h (wrong override signature)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
4 # build-wasm BUILD_TYPE |
1d9deb4ee84c
Added RTSTRUCT demo viewer based on captain + fix in dev.h (wrong override signature)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
5 # where BUILD_TYPE is Debug, RelWithDebInfo or Release |
1d9deb4ee84c
Added RTSTRUCT demo viewer based on captain + fix in dev.h (wrong override signature)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
6 |
1d9deb4ee84c
Added RTSTRUCT demo viewer based on captain + fix in dev.h (wrong override signature)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
7 set -e |
1d9deb4ee84c
Added RTSTRUCT demo viewer based on captain + fix in dev.h (wrong override signature)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
8 |
1d9deb4ee84c
Added RTSTRUCT demo viewer based on captain + fix in dev.h (wrong override signature)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
9 buildType=${1:-Debug} |
1d9deb4ee84c
Added RTSTRUCT demo viewer based on captain + fix in dev.h (wrong override signature)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
10 |
1d9deb4ee84c
Added RTSTRUCT demo viewer based on captain + fix in dev.h (wrong override signature)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
11 currentDir=$(pwd) |
1d9deb4ee84c
Added RTSTRUCT demo viewer based on captain + fix in dev.h (wrong override signature)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
12 currentDirAbs=$(realpath $currentDir) |
1d9deb4ee84c
Added RTSTRUCT demo viewer based on captain + fix in dev.h (wrong override signature)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
13 |
1d9deb4ee84c
Added RTSTRUCT demo viewer based on captain + fix in dev.h (wrong override signature)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
14 mkdir -p build-wasm |
1d9deb4ee84c
Added RTSTRUCT demo viewer based on captain + fix in dev.h (wrong override signature)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
15 cd build-wasm |
1d9deb4ee84c
Added RTSTRUCT demo viewer based on captain + fix in dev.h (wrong override signature)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
16 |
1d9deb4ee84c
Added RTSTRUCT demo viewer based on captain + fix in dev.h (wrong override signature)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
17 source ~/apps/emsdk/emsdk_env.sh |
1d9deb4ee84c
Added RTSTRUCT demo viewer based on captain + fix in dev.h (wrong override signature)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
18 cmake -G Ninja -DCMAKE_TOOLCHAIN_FILE=${EMSCRIPTEN}/cmake/Modules/Platform/Emscripten.cmake \ |
1d9deb4ee84c
Added RTSTRUCT demo viewer based on captain + fix in dev.h (wrong override signature)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
19 -DCMAKE_BUILD_TYPE=$buildType -DSTONE_SOURCES_DIR=$currentDirAbs/../../../../orthanc-stone \ |
1d9deb4ee84c
Added RTSTRUCT demo viewer based on captain + fix in dev.h (wrong override signature)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
20 -DORTHANC_FRAMEWORK_SOURCE=path -DORTHANC_FRAMEWORK_ROOT=$currentDirAbs/../../../../orthanc \ |
1d9deb4ee84c
Added RTSTRUCT demo viewer based on captain + fix in dev.h (wrong override signature)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
21 -DALLOW_DOWNLOADS=ON .. -DENABLE_WASM=ON |
1d9deb4ee84c
Added RTSTRUCT demo viewer based on captain + fix in dev.h (wrong override signature)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
22 |
1d9deb4ee84c
Added RTSTRUCT demo viewer based on captain + fix in dev.h (wrong override signature)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
23 ninja $target |
1d9deb4ee84c
Added RTSTRUCT demo viewer based on captain + fix in dev.h (wrong override signature)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
24 |
1d9deb4ee84c
Added RTSTRUCT demo viewer based on captain + fix in dev.h (wrong override signature)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
25 echo "-- building the web application -- " |
1d9deb4ee84c
Added RTSTRUCT demo viewer based on captain + fix in dev.h (wrong override signature)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
26 cd $currentDir |
1d9deb4ee84c
Added RTSTRUCT demo viewer based on captain + fix in dev.h (wrong override signature)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
27 ./build-web.sh |
1d9deb4ee84c
Added RTSTRUCT demo viewer based on captain + fix in dev.h (wrong override signature)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
28 |
1d9deb4ee84c
Added RTSTRUCT demo viewer based on captain + fix in dev.h (wrong override signature)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
29 echo "Launch start-serving-files.sh to access the web sample application locally" |