annotate Applications/Samples/build-web.sh @ 353:92a159481900 am-2

removed useless variable
author Sebastien Jodogne <s.jodogne@gmail.com>
date Mon, 29 Oct 2018 11:53:34 +0100
parents 612238b3f3e8
children e641d3978856
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
295
b04b13810540 unified CMakeLists.txt into a single file for WASM/Native + bootstrap Command (to rework) + doc
am@osimis.io
parents:
diff changeset
1 #!/bin/bash
b04b13810540 unified CMakeLists.txt into a single file for WASM/Native + bootstrap Command (to rework) + doc
am@osimis.io
parents:
diff changeset
2
307
be2660b6e40a wip: commands + status update
am@osimis.io
parents: 295
diff changeset
3 set -e
be2660b6e40a wip: commands + status update
am@osimis.io
parents: 295
diff changeset
4
319
daa04d15192c new SimpleViewer sample that has been split in multiple files to be able to scale it
am@osimis.io
parents: 307
diff changeset
5 # this script currently assumes that the wasm code has been built on its side and is availabie in build-wasm/
295
b04b13810540 unified CMakeLists.txt into a single file for WASM/Native + bootstrap Command (to rework) + doc
am@osimis.io
parents:
diff changeset
6
b04b13810540 unified CMakeLists.txt into a single file for WASM/Native + bootstrap Command (to rework) + doc
am@osimis.io
parents:
diff changeset
7 currentDir=$(pwd)
b04b13810540 unified CMakeLists.txt into a single file for WASM/Native + bootstrap Command (to rework) + doc
am@osimis.io
parents:
diff changeset
8 samplesRootDir=$(pwd)
b04b13810540 unified CMakeLists.txt into a single file for WASM/Native + bootstrap Command (to rework) + doc
am@osimis.io
parents:
diff changeset
9
b04b13810540 unified CMakeLists.txt into a single file for WASM/Native + bootstrap Command (to rework) + doc
am@osimis.io
parents:
diff changeset
10 outputDir=$samplesRootDir/build-web/
b04b13810540 unified CMakeLists.txt into a single file for WASM/Native + bootstrap Command (to rework) + doc
am@osimis.io
parents:
diff changeset
11 mkdir -p $outputDir
b04b13810540 unified CMakeLists.txt into a single file for WASM/Native + bootstrap Command (to rework) + doc
am@osimis.io
parents:
diff changeset
12
319
daa04d15192c new SimpleViewer sample that has been split in multiple files to be able to scale it
am@osimis.io
parents: 307
diff changeset
13 # files used by all single files samples
295
b04b13810540 unified CMakeLists.txt into a single file for WASM/Native + bootstrap Command (to rework) + doc
am@osimis.io
parents:
diff changeset
14 cp $samplesRootDir/Web/index.html $outputDir
b04b13810540 unified CMakeLists.txt into a single file for WASM/Native + bootstrap Command (to rework) + doc
am@osimis.io
parents:
diff changeset
15 cp $samplesRootDir/Web/samples-styles.css $outputDir
b04b13810540 unified CMakeLists.txt into a single file for WASM/Native + bootstrap Command (to rework) + doc
am@osimis.io
parents:
diff changeset
16
319
daa04d15192c new SimpleViewer sample that has been split in multiple files to be able to scale it
am@osimis.io
parents: 307
diff changeset
17 # build simple-viewer-single-file (obsolete project)
daa04d15192c new SimpleViewer sample that has been split in multiple files to be able to scale it
am@osimis.io
parents: 307
diff changeset
18 cp $samplesRootDir/Web/simple-viewer-single-file.html $outputDir
326
612238b3f3e8 all 4 samples now working in Qt, SDL and wasm
am@osimis.io
parents: 319
diff changeset
19 tsc --allowJs --project $samplesRootDir/Web/simple-viewer-single-file.tsconfig.json
319
daa04d15192c new SimpleViewer sample that has been split in multiple files to be able to scale it
am@osimis.io
parents: 307
diff changeset
20 cp $currentDir/build-wasm/OrthancStoneSimpleViewerSingleFile.js $outputDir
daa04d15192c new SimpleViewer sample that has been split in multiple files to be able to scale it
am@osimis.io
parents: 307
diff changeset
21 cp $currentDir/build-wasm/OrthancStoneSimpleViewerSingleFile.wasm $outputDir
daa04d15192c new SimpleViewer sample that has been split in multiple files to be able to scale it
am@osimis.io
parents: 307
diff changeset
22
326
612238b3f3e8 all 4 samples now working in Qt, SDL and wasm
am@osimis.io
parents: 319
diff changeset
23 # build single-frame
612238b3f3e8 all 4 samples now working in Qt, SDL and wasm
am@osimis.io
parents: 319
diff changeset
24 cp $samplesRootDir/Web/single-frame.html $outputDir
612238b3f3e8 all 4 samples now working in Qt, SDL and wasm
am@osimis.io
parents: 319
diff changeset
25 tsc --allowJs --project $samplesRootDir/Web/single-frame.tsconfig.json
612238b3f3e8 all 4 samples now working in Qt, SDL and wasm
am@osimis.io
parents: 319
diff changeset
26 cp $currentDir/build-wasm/OrthancStoneSingleFrame.js $outputDir
612238b3f3e8 all 4 samples now working in Qt, SDL and wasm
am@osimis.io
parents: 319
diff changeset
27 cp $currentDir/build-wasm/OrthancStoneSingleFrame.wasm $outputDir
612238b3f3e8 all 4 samples now working in Qt, SDL and wasm
am@osimis.io
parents: 319
diff changeset
28
612238b3f3e8 all 4 samples now working in Qt, SDL and wasm
am@osimis.io
parents: 319
diff changeset
29 # build single-frame-editor
612238b3f3e8 all 4 samples now working in Qt, SDL and wasm
am@osimis.io
parents: 319
diff changeset
30 cp $samplesRootDir/Web/single-frame-editor.html $outputDir
612238b3f3e8 all 4 samples now working in Qt, SDL and wasm
am@osimis.io
parents: 319
diff changeset
31 tsc --allowJs --project $samplesRootDir/Web/single-frame-editor.tsconfig.json
612238b3f3e8 all 4 samples now working in Qt, SDL and wasm
am@osimis.io
parents: 319
diff changeset
32 cp $currentDir/build-wasm/OrthancStoneSingleFrameEditor.js $outputDir
612238b3f3e8 all 4 samples now working in Qt, SDL and wasm
am@osimis.io
parents: 319
diff changeset
33 cp $currentDir/build-wasm/OrthancStoneSingleFrameEditor.wasm $outputDir
612238b3f3e8 all 4 samples now working in Qt, SDL and wasm
am@osimis.io
parents: 319
diff changeset
34
319
daa04d15192c new SimpleViewer sample that has been split in multiple files to be able to scale it
am@osimis.io
parents: 307
diff changeset
35 # build simple-viewer project
daa04d15192c new SimpleViewer sample that has been split in multiple files to be able to scale it
am@osimis.io
parents: 307
diff changeset
36 mkdir -p $outputDir/simple-viewer/
daa04d15192c new SimpleViewer sample that has been split in multiple files to be able to scale it
am@osimis.io
parents: 307
diff changeset
37 cp $samplesRootDir/SimpleViewer/Wasm/simple-viewer.html $outputDir/simple-viewer/
daa04d15192c new SimpleViewer sample that has been split in multiple files to be able to scale it
am@osimis.io
parents: 307
diff changeset
38 cp $samplesRootDir/SimpleViewer/Wasm/styles.css $outputDir/simple-viewer/
daa04d15192c new SimpleViewer sample that has been split in multiple files to be able to scale it
am@osimis.io
parents: 307
diff changeset
39 tsc --allowJs --project $samplesRootDir/SimpleViewer/Wasm/tsconfig-simple-viewer.json
daa04d15192c new SimpleViewer sample that has been split in multiple files to be able to scale it
am@osimis.io
parents: 307
diff changeset
40 cp $currentDir/build-wasm/OrthancStoneSimpleViewer.js $outputDir/simple-viewer/
daa04d15192c new SimpleViewer sample that has been split in multiple files to be able to scale it
am@osimis.io
parents: 307
diff changeset
41 cp $currentDir/build-wasm/OrthancStoneSimpleViewer.wasm $outputDir/simple-viewer/
295
b04b13810540 unified CMakeLists.txt into a single file for WASM/Native + bootstrap Command (to rework) + doc
am@osimis.io
parents:
diff changeset
42
b04b13810540 unified CMakeLists.txt into a single file for WASM/Native + bootstrap Command (to rework) + doc
am@osimis.io
parents:
diff changeset
43 cd $currentDir