comparison Applications/Samples/WebAssembly/docker-internal.sh @ 1538:d1806b4e4839

moving OrthancStone/Samples/ as Applications/Samples/
author Sebastien Jodogne <s.jodogne@gmail.com>
date Tue, 11 Aug 2020 13:24:38 +0200
parents OrthancStone/Samples/WebAssembly/docker-internal.sh@3eca4f9c2827
children 6e0da8370270
comparison
equal deleted inserted replaced
1537:de8cf5859e84 1538:d1806b4e4839
1 #!/bin/bash
2 set -ex
3
4 source /opt/emsdk/emsdk_env.sh
5
6 # Use a folder that is writeable by non-root users for the Emscripten cache
7 export EM_CACHE=/tmp/emscripten-cache
8
9 # Get the Orthanc framework
10 cd /tmp/
11 hg clone https://hg.orthanc-server.com/orthanc/
12
13 # Make a copy of the read-only folder containing the source code into
14 # a writeable folder, because of "DownloadPackage.cmake" that writes
15 # to the "ThirdPartyDownloads" folder next to the "CMakeLists.txt"
16 cd /source
17 hg clone /source /tmp/source-writeable
18
19 mkdir /tmp/build
20 cd /tmp/build
21
22 cmake /tmp/source-writeable/OrthancStone/Samples/WebAssembly \
23 -DCMAKE_BUILD_TYPE=$1 \
24 -DCMAKE_INSTALL_PREFIX=/target \
25 -DCMAKE_TOOLCHAIN_FILE=${EMSDK}/upstream/emscripten/cmake/Modules/Platform/Emscripten.cmake \
26 -DORTHANC_FRAMEWORK_ROOT=/tmp/orthanc/OrthancFramework/Sources \
27 -DSTATIC_BUILD=ON \
28 -G Ninja
29
30 ninja -j2 install