forked from Zylann/godot_voxel
-
Notifications
You must be signed in to change notification settings - Fork 0
/
SCsub
47 lines (41 loc) · 1.21 KB
/
SCsub
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
Import('env')
Import('env_modules')
env_voxel = env_modules.Clone()
# TODO Exclude editor stuff when building an export template?
files = [
"*.cpp",
"meshers/blocky/*.cpp",
"meshers/transvoxel/*.cpp",
"meshers/dmc/*.cpp",
"meshers/cubes/*.cpp",
"meshers/*.cpp",
"streams/*.cpp",
"storage/*.cpp",
"generators/*.cpp",
"generators/graph/*.cpp",
"util/*.cpp",
"terrain/*.cpp",
"server/*.cpp",
"math/*.cpp",
"edition/*.cpp",
"editor/*.cpp",
"editor/graph/*.cpp",
"editor/terrain/*.cpp",
"thirdparty/lz4/*.c"
]
for f in files:
env_voxel.add_source_files(env.modules_sources, f)
# Ignored clang warnings because Godot's codebase is old and isn't using override yet
if env['platform'] == 'osx' or env['platform'] == 'android':
env_voxel.Append(CXXFLAGS=['-Wno-inconsistent-missing-override'])
# Doesn't work, because reasons
#if env.msvc:
# env_voxel.Append(CXXFLAGS=['/std:c++17'])
#else:
# env_voxel.Append(CXXFLAGS=['-std=c++17'])
# This also doesn't work, since the rest of Godot doesn't use this, linking fails.
# No safe STL boundary checks for you.
#if env['target'] == 'debug':
# if env.msvc:
# # Enable STL bound checks, Godot's master environment doesn't do it
# env_voxel.Append(CXXFLAGS=['/D_DEBUG'])