Mercurial > games > semicongine
comparison semiconginev2/core/buildconfig.nim @ 1226:c8e3037aca66 compiletime-tests
add: contrib stuff
author | sam <sam@basx.dev> |
---|---|
date | Wed, 17 Jul 2024 23:41:51 +0700 |
parents | 55896320c8bf |
children |
comparison
equal
deleted
inserted
replaced
1225:27cd1c21290e | 1226:c8e3037aca66 |
---|---|
10 assert false, "trying to build on unsupported platform" | 10 assert false, "trying to build on unsupported platform" |
11 | 11 |
12 # build configuration | 12 # build configuration |
13 # ===================== | 13 # ===================== |
14 | 14 |
15 # compile-time defines, usefull for build-dependent settings | |
16 # can be overriden with compiler flags, e.g. -d:Foo=42 -d:Bar=false | |
17 # pramas: {.intdefine.} {.strdefine.} {.booldefine.} | |
18 | |
19 # root of where settings files will be searched | |
20 # must be relative (to the directory of the binary) | |
21 const DEBUG* {.booldefine.} = not defined(release) | |
22 const CONFIGROOT* {.strdefine.}: string = "." | |
23 assert not isAbsolute(CONFIGROOT) | |
24 | |
25 const CONFIGEXTENSION* {.strdefine.}: string = "ini" | |
26 | |
27 # by default enable hot-reload of runtime-configuration only in debug builds | |
28 const CONFIGHOTRELOAD* {.booldefine.}: bool = DEBUG | |
29 | |
30 # milliseconds to wait between checks for settings hotreload | |
31 const CONFIGHOTRELOADINTERVAL* {.intdefine.}: int = 1000 | |
32 | |
33 # log level | 15 # log level |
34 const LOGLEVEL {.strdefine.}: string = "Warn" | 16 const LOGLEVEL {.strdefine.}: string = "Warn" |
35 const ENGINE_LOGLEVEL* = parseEnum[Level]("lvl" & LOGLEVEL) | 17 const ENGINE_LOGLEVEL* = parseEnum[Level]("lvl" & LOGLEVEL) |
36 | 18 |
37 # resource bundleing settings, need to be configured per project | 19 # resource bundleing settings, need to be configured per project |