annotate Makefile @ 463:91544fc1afe5

did: hello world triangle, a bit of code organization
author Sam <sam@basx.dev>
date Mon, 19 Dec 2022 10:41:20 +0700
parents 0bc8643cfe25
children 5d54ef652619
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
461
59d861a6a5c4 add: initial version
Sam <sam@basx.dev>
parents:
diff changeset
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
59d861a6a5c4 add: initial version
Sam <sam@basx.dev>
parents:
diff changeset
5
59d861a6a5c4 add: initial version
Sam <sam@basx.dev>
parents:
diff changeset
6 build/debug/linux:
59d861a6a5c4 add: initial version
Sam <sam@basx.dev>
parents:
diff changeset
7 mkdir -p $@
59d861a6a5c4 add: initial version
Sam <sam@basx.dev>
parents:
diff changeset
8 build/debug/linux/test: build/debug/linux ${SOURCES}
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
461
59d861a6a5c4 add: initial version
Sam <sam@basx.dev>
parents:
diff changeset
10
59d861a6a5c4 add: initial version
Sam <sam@basx.dev>
parents:
diff changeset
11 build/release/linux:
59d861a6a5c4 add: initial version
Sam <sam@basx.dev>
parents:
diff changeset
12 mkdir -p $@
59d861a6a5c4 add: initial version
Sam <sam@basx.dev>
parents:
diff changeset
13 build/release/linux/test: build/release/linux ${SOURCES}
463
91544fc1afe5 did: hello world triangle, a bit of code organization
Sam <sam@basx.dev>
parents: 462
diff changeset
14 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
15
91544fc1afe5 did: hello world triangle, a bit of code organization
Sam <sam@basx.dev>
parents: 462
diff changeset
16 # not working yet, need to implement windows window-API
91544fc1afe5 did: hello world triangle, a bit of code organization
Sam <sam@basx.dev>
parents: 462
diff changeset
17 # build/debug/windows:
91544fc1afe5 did: hello world triangle, a bit of code organization
Sam <sam@basx.dev>
parents: 462
diff changeset
18 # mkdir -p $@
91544fc1afe5 did: hello world triangle, a bit of code organization
Sam <sam@basx.dev>
parents: 462
diff changeset
19 # build/debug/windows/test: build/debug/windows ${SOURCES}
91544fc1afe5 did: hello world triangle, a bit of code organization
Sam <sam@basx.dev>
parents: 462
diff changeset
20 # nim c ${COMPILE_OPTIONS} ${DEBUG_OPTIONS} -d:mingw -o:$@ examples/test.nim
91544fc1afe5 did: hello world triangle, a bit of code organization
Sam <sam@basx.dev>
parents: 462
diff changeset
21 # build/release/windows:
91544fc1afe5 did: hello world triangle, a bit of code organization
Sam <sam@basx.dev>
parents: 462
diff changeset
22 # mkdir -p $@
91544fc1afe5 did: hello world triangle, a bit of code organization
Sam <sam@basx.dev>
parents: 462
diff changeset
23 # build/release/windows/test: build/release/windows ${SOURCES}
91544fc1afe5 did: hello world triangle, a bit of code organization
Sam <sam@basx.dev>
parents: 462
diff changeset
24 # nim c ${COMPILE_OPTIONS} ${DEBUG_OPTIONS} -d:mingw -o:$@ examples/test.nim
91544fc1afe5 did: hello world triangle, a bit of code organization
Sam <sam@basx.dev>
parents: 462
diff changeset
25