Mercurial > games > semicongine
annotate Makefile @ 466:1dd9e2393a9e
add: structure code for crossplatform, add some input handling + bugfixes
| author | Sam <sam@basx.dev> | 
|---|---|
| date | Thu, 22 Dec 2022 00:06:40 +0700 | 
| parents | 7cae1900c9a7 | 
| children | 1134f41a49e9 | 
| rev | line source | 
|---|---|
| 461 | 1 SOURCES := $(shell find src -name '*.nim') | 
| 
463
 
91544fc1afe5
did: hello world triangle, a bit of code organization
 
Sam <sam@basx.dev> 
parents: 
462 
diff
changeset
 | 
2 COMPILE_OPTIONS := --path:src --mm:orc --experimental:strictEffects --threads:on | 
| 
 
91544fc1afe5
did: hello world triangle, a bit of code organization
 
Sam <sam@basx.dev> 
parents: 
462 
diff
changeset
 | 
3 DEBUG_OPTIONS := --debugger:native --checks:on --assertions:on | 
| 
 
91544fc1afe5
did: hello world triangle, a bit of code organization
 
Sam <sam@basx.dev> 
parents: 
462 
diff
changeset
 | 
4 RELEASE_OPTIONS := -d:release --checks:off --assertions:off | 
| 461 | 5 | 
| 
466
 
1dd9e2393a9e
add: structure code for crossplatform, add some input handling + bugfixes
 
Sam <sam@basx.dev> 
parents: 
464 
diff
changeset
 | 
6 # build | 
| 
 
1dd9e2393a9e
add: structure code for crossplatform, add some input handling + bugfixes
 
Sam <sam@basx.dev> 
parents: 
464 
diff
changeset
 | 
7 build/debug/linux/test: ${SOURCES} | 
| 
 
1dd9e2393a9e
add: structure code for crossplatform, add some input handling + bugfixes
 
Sam <sam@basx.dev> 
parents: 
464 
diff
changeset
 | 
8 mkdir -p $$( dirname $@ ) | 
| 
463
 
91544fc1afe5
did: hello world triangle, a bit of code organization
 
Sam <sam@basx.dev> 
parents: 
462 
diff
changeset
 | 
9 nim c ${COMPILE_OPTIONS} ${DEBUG_OPTIONS} -o:$@ examples/test.nim | 
| 
466
 
1dd9e2393a9e
add: structure code for crossplatform, add some input handling + bugfixes
 
Sam <sam@basx.dev> 
parents: 
464 
diff
changeset
 | 
10 build/release/linux/test: ${SOURCES} | 
| 
 
1dd9e2393a9e
add: structure code for crossplatform, add some input handling + bugfixes
 
Sam <sam@basx.dev> 
parents: 
464 
diff
changeset
 | 
11 mkdir -p $$( dirname $@ ) | 
| 
 
1dd9e2393a9e
add: structure code for crossplatform, add some input handling + bugfixes
 
Sam <sam@basx.dev> 
parents: 
464 
diff
changeset
 | 
12 nim c ${COMPILE_OPTIONS} ${RELEASE_OPTIONS} -o:$@ examples/test.nim | 
| 
 
1dd9e2393a9e
add: structure code for crossplatform, add some input handling + bugfixes
 
Sam <sam@basx.dev> 
parents: 
464 
diff
changeset
 | 
13 build/debug/windows/test: ${SOURCES} | 
| 
 
1dd9e2393a9e
add: structure code for crossplatform, add some input handling + bugfixes
 
Sam <sam@basx.dev> 
parents: 
464 
diff
changeset
 | 
14 mkdir -p $$( dirname $@ ) | 
| 
 
1dd9e2393a9e
add: structure code for crossplatform, add some input handling + bugfixes
 
Sam <sam@basx.dev> 
parents: 
464 
diff
changeset
 | 
15 nim c ${COMPILE_OPTIONS} ${DEBUG_OPTIONS} -o:$@ examples/test.nim | 
| 
 
1dd9e2393a9e
add: structure code for crossplatform, add some input handling + bugfixes
 
Sam <sam@basx.dev> 
parents: 
464 
diff
changeset
 | 
16 build/release/windows/test: ${SOURCES} | 
| 
 
1dd9e2393a9e
add: structure code for crossplatform, add some input handling + bugfixes
 
Sam <sam@basx.dev> 
parents: 
464 
diff
changeset
 | 
17 mkdir -p $$( dirname $@ ) | 
| 
463
 
91544fc1afe5
did: hello world triangle, a bit of code organization
 
Sam <sam@basx.dev> 
parents: 
462 
diff
changeset
 | 
18 nim c ${COMPILE_OPTIONS} ${RELEASE_OPTIONS} -o:$@ examples/test.nim | 
| 
 
91544fc1afe5
did: hello world triangle, a bit of code organization
 
Sam <sam@basx.dev> 
parents: 
462 
diff
changeset
 | 
19 | 
| 
466
 
1dd9e2393a9e
add: structure code for crossplatform, add some input handling + bugfixes
 
Sam <sam@basx.dev> 
parents: 
464 
diff
changeset
 | 
20 build_all: build/debug/linux/test build/release/linux/test build/debug/windows/test build/release/windows/test | 
| 
 
1dd9e2393a9e
add: structure code for crossplatform, add some input handling + bugfixes
 
Sam <sam@basx.dev> 
parents: 
464 
diff
changeset
 | 
21 | 
| 
 
1dd9e2393a9e
add: structure code for crossplatform, add some input handling + bugfixes
 
Sam <sam@basx.dev> 
parents: 
464 
diff
changeset
 | 
22 # publish | 
| 
 
1dd9e2393a9e
add: structure code for crossplatform, add some input handling + bugfixes
 
Sam <sam@basx.dev> 
parents: 
464 
diff
changeset
 | 
23 publish_linux_debug: build/debug/linux/test | 
| 
 
1dd9e2393a9e
add: structure code for crossplatform, add some input handling + bugfixes
 
Sam <sam@basx.dev> 
parents: 
464 
diff
changeset
 | 
24 scp $< basx.dev:/var/www/public.basx.dev/joni/linux/debug/ | 
| 
 
1dd9e2393a9e
add: structure code for crossplatform, add some input handling + bugfixes
 
Sam <sam@basx.dev> 
parents: 
464 
diff
changeset
 | 
25 publish_linux_release: build/release/linux/test | 
| 
 
1dd9e2393a9e
add: structure code for crossplatform, add some input handling + bugfixes
 
Sam <sam@basx.dev> 
parents: 
464 
diff
changeset
 | 
26 scp $< basx.dev:/var/www/public.basx.dev/joni/linux/release/ | 
| 
 
1dd9e2393a9e
add: structure code for crossplatform, add some input handling + bugfixes
 
Sam <sam@basx.dev> 
parents: 
464 
diff
changeset
 | 
27 publish_windows_debug: build/debug/linux/test | 
| 
 
1dd9e2393a9e
add: structure code for crossplatform, add some input handling + bugfixes
 
Sam <sam@basx.dev> 
parents: 
464 
diff
changeset
 | 
28 scp $< basx.dev:/var/www/public.basx.dev/joni/windows/debug/ | 
| 
 
1dd9e2393a9e
add: structure code for crossplatform, add some input handling + bugfixes
 
Sam <sam@basx.dev> 
parents: 
464 
diff
changeset
 | 
29 publish_windows_release: build/release/linux/test | 
| 
 
1dd9e2393a9e
add: structure code for crossplatform, add some input handling + bugfixes
 
Sam <sam@basx.dev> 
parents: 
464 
diff
changeset
 | 
30 scp $< basx.dev:/var/www/public.basx.dev/joni/windows/release/ | 
| 
 
1dd9e2393a9e
add: structure code for crossplatform, add some input handling + bugfixes
 
Sam <sam@basx.dev> 
parents: 
464 
diff
changeset
 | 
31 | 
| 
 
1dd9e2393a9e
add: structure code for crossplatform, add some input handling + bugfixes
 
Sam <sam@basx.dev> 
parents: 
464 
diff
changeset
 | 
32 publish_all: publish_linux_debug publish_linux_release publish_windows_debug publish_windows_release | 
| 
 
1dd9e2393a9e
add: structure code for crossplatform, add some input handling + bugfixes
 
Sam <sam@basx.dev> 
parents: 
464 
diff
changeset
 | 
33 | 
| 
 
1dd9e2393a9e
add: structure code for crossplatform, add some input handling + bugfixes
 
Sam <sam@basx.dev> 
parents: 
464 
diff
changeset
 | 
34 | 
| 
 
1dd9e2393a9e
add: structure code for crossplatform, add some input handling + bugfixes
 
Sam <sam@basx.dev> 
parents: 
464 
diff
changeset
 | 
35 # download thirdparty-libraries | 
| 
463
 
91544fc1afe5
did: hello world triangle, a bit of code organization
 
Sam <sam@basx.dev> 
parents: 
462 
diff
changeset
 | 
36 | 
| 
466
 
1dd9e2393a9e
add: structure code for crossplatform, add some input handling + bugfixes
 
Sam <sam@basx.dev> 
parents: 
464 
diff
changeset
 | 
37 thirdparty/lib/glslang/linux_debug: | 
| 
 
1dd9e2393a9e
add: structure code for crossplatform, add some input handling + bugfixes
 
Sam <sam@basx.dev> 
parents: 
464 
diff
changeset
 | 
38 mkdir -p $@ | 
| 
 
1dd9e2393a9e
add: structure code for crossplatform, add some input handling + bugfixes
 
Sam <sam@basx.dev> 
parents: 
464 
diff
changeset
 | 
39 wget --directory-prefix=$@ https://github.com/KhronosGroup/glslang/releases/download/master-tot/glslang-master-linux-Debug.zip | 
| 
 
1dd9e2393a9e
add: structure code for crossplatform, add some input handling + bugfixes
 
Sam <sam@basx.dev> 
parents: 
464 
diff
changeset
 | 
40 uzip glslang-master-linux-Debug.zip | 
| 
 
1dd9e2393a9e
add: structure code for crossplatform, add some input handling + bugfixes
 
Sam <sam@basx.dev> 
parents: 
464 
diff
changeset
 | 
41 thirdparty/lib/glslang/linux_release: | 
| 
 
1dd9e2393a9e
add: structure code for crossplatform, add some input handling + bugfixes
 
Sam <sam@basx.dev> 
parents: 
464 
diff
changeset
 | 
42 mkdir -p $@ | 
| 
 
1dd9e2393a9e
add: structure code for crossplatform, add some input handling + bugfixes
 
Sam <sam@basx.dev> 
parents: 
464 
diff
changeset
 | 
43 wget --directory-prefix=$@ https://github.com/KhronosGroup/glslang/releases/download/master-tot/glslang-master-linux-Release.zip | 
| 
 
1dd9e2393a9e
add: structure code for crossplatform, add some input handling + bugfixes
 
Sam <sam@basx.dev> 
parents: 
464 
diff
changeset
 | 
44 unzip glslang-master-linux-Release.zip | 
| 
 
1dd9e2393a9e
add: structure code for crossplatform, add some input handling + bugfixes
 
Sam <sam@basx.dev> 
parents: 
464 
diff
changeset
 | 
45 thirdparty/lib/glslang/windows_debug: | 
| 
 
1dd9e2393a9e
add: structure code for crossplatform, add some input handling + bugfixes
 
Sam <sam@basx.dev> 
parents: 
464 
diff
changeset
 | 
46 mkdir -p $@ | 
| 
 
1dd9e2393a9e
add: structure code for crossplatform, add some input handling + bugfixes
 
Sam <sam@basx.dev> 
parents: 
464 
diff
changeset
 | 
47 wget --directory-prefix=$@ https://github.com/KhronosGroup/glslang/releases/download/master-tot/glslang-master-windows-x64-Debug.zip | 
| 
 
1dd9e2393a9e
add: structure code for crossplatform, add some input handling + bugfixes
 
Sam <sam@basx.dev> 
parents: 
464 
diff
changeset
 | 
48 unzip glslang-master-windows-x64-Debug.zip | 
| 
 
1dd9e2393a9e
add: structure code for crossplatform, add some input handling + bugfixes
 
Sam <sam@basx.dev> 
parents: 
464 
diff
changeset
 | 
49 thirdparty/lib/glslang/windows_release: | 
| 
 
1dd9e2393a9e
add: structure code for crossplatform, add some input handling + bugfixes
 
Sam <sam@basx.dev> 
parents: 
464 
diff
changeset
 | 
50 mkdir -p $@ | 
| 
 
1dd9e2393a9e
add: structure code for crossplatform, add some input handling + bugfixes
 
Sam <sam@basx.dev> 
parents: 
464 
diff
changeset
 | 
51 wget --directory-prefix=$@ https://github.com/KhronosGroup/glslang/releases/download/master-tot/glslang-master-windows-x64-Release.zip | 
| 
 
1dd9e2393a9e
add: structure code for crossplatform, add some input handling + bugfixes
 
Sam <sam@basx.dev> 
parents: 
464 
diff
changeset
 | 
52 unzip glslang-master-windows-x64-Release.zip | 
| 
464
 
7cae1900c9a7
add: skeleton to download thirdparty builds
 
Sam <sam@basx.dev> 
parents: 
463 
diff
changeset
 | 
53 | 
| 
466
 
1dd9e2393a9e
add: structure code for crossplatform, add some input handling + bugfixes
 
Sam <sam@basx.dev> 
parents: 
464 
diff
changeset
 | 
54 thirdparty/lib/spirv-tools/linux_debug: | 
| 
 
1dd9e2393a9e
add: structure code for crossplatform, add some input handling + bugfixes
 
Sam <sam@basx.dev> 
parents: 
464 
diff
changeset
 | 
55 mkdir -p $@ | 
| 
 
1dd9e2393a9e
add: structure code for crossplatform, add some input handling + bugfixes
 
Sam <sam@basx.dev> 
parents: 
464 
diff
changeset
 | 
56 wget --directory-prefix=$@ https://storage.googleapis.com/spirv-tools/artifacts/prod/graphics_shader_compiler/spirv-tools/linux-gcc-debug/continuous/1899/20221216-081758/install.tgz | 
| 
 
1dd9e2393a9e
add: structure code for crossplatform, add some input handling + bugfixes
 
Sam <sam@basx.dev> 
parents: 
464 
diff
changeset
 | 
57 tar -xf $@/install.tgz | 
| 
 
1dd9e2393a9e
add: structure code for crossplatform, add some input handling + bugfixes
 
Sam <sam@basx.dev> 
parents: 
464 
diff
changeset
 | 
58 thirdparty/lib/spirv-tools/linux_release: | 
| 
 
1dd9e2393a9e
add: structure code for crossplatform, add some input handling + bugfixes
 
Sam <sam@basx.dev> 
parents: 
464 
diff
changeset
 | 
59 mkdir -p $@ | 
| 
 
1dd9e2393a9e
add: structure code for crossplatform, add some input handling + bugfixes
 
Sam <sam@basx.dev> 
parents: 
464 
diff
changeset
 | 
60 wget --directory-prefix=$@ https://storage.googleapis.com/spirv-tools/artifacts/prod/graphics_shader_compiler/spirv-tools/linux-gcc-release/continuous/1889/20221216-081754/install.tgz | 
| 
 
1dd9e2393a9e
add: structure code for crossplatform, add some input handling + bugfixes
 
Sam <sam@basx.dev> 
parents: 
464 
diff
changeset
 | 
61 tar -xf $@/install.tgz | 
| 
 
1dd9e2393a9e
add: structure code for crossplatform, add some input handling + bugfixes
 
Sam <sam@basx.dev> 
parents: 
464 
diff
changeset
 | 
62 thirdparty/lib/spirv-tools/windows_debug: | 
| 
 
1dd9e2393a9e
add: structure code for crossplatform, add some input handling + bugfixes
 
Sam <sam@basx.dev> 
parents: 
464 
diff
changeset
 | 
63 mkdir -p $@ | 
| 
 
1dd9e2393a9e
add: structure code for crossplatform, add some input handling + bugfixes
 
Sam <sam@basx.dev> 
parents: 
464 
diff
changeset
 | 
64 wget --directory-prefix=$@ https://storage.googleapis.com/spirv-tools/artifacts/prod/graphics_shader_compiler/spirv-tools/windows-msvc-2017-debug/continuous/1599/20221216-081803/install.zip | 
| 
 
1dd9e2393a9e
add: structure code for crossplatform, add some input handling + bugfixes
 
Sam <sam@basx.dev> 
parents: 
464 
diff
changeset
 | 
65 unzip $@/install.zip | 
| 
 
1dd9e2393a9e
add: structure code for crossplatform, add some input handling + bugfixes
 
Sam <sam@basx.dev> 
parents: 
464 
diff
changeset
 | 
66 thirdparty/lib/spirv-tools/windows_release: | 
| 
 
1dd9e2393a9e
add: structure code for crossplatform, add some input handling + bugfixes
 
Sam <sam@basx.dev> 
parents: 
464 
diff
changeset
 | 
67 mkdir -p $@ | 
| 
 
1dd9e2393a9e
add: structure code for crossplatform, add some input handling + bugfixes
 
Sam <sam@basx.dev> 
parents: 
464 
diff
changeset
 | 
68 wget --directory-prefix=$@ https://storage.googleapis.com/spirv-tools/artifacts/prod/graphics_shader_compiler/spirv-tools/windows-msvc-2017-release/continuous/1885/20221216-081805/install.zip | 
| 
 
1dd9e2393a9e
add: structure code for crossplatform, add some input handling + bugfixes
 
Sam <sam@basx.dev> 
parents: 
464 
diff
changeset
 | 
69 unzip $@/install.zip | 
