diff options
author | Fabio Alessandrelli <fabio.alessandrelli@gmail.com> | 2019-05-16 11:50:29 +0200 |
---|---|---|
committer | Fabio Alessandrelli <fabio.alessandrelli@gmail.com> | 2019-05-16 12:08:39 +0200 |
commit | 599ed98f6cb956d5189ec4b4905dbc2a8a1b5d9a (patch) | |
tree | 34c78fa5e627d35b9302618724dfbb7ff0e5e77c /SConstruct | |
parent | f5ebac451987b1e9d052025abdab5af57f480f9e (diff) | |
download | fork-godot-webrtc-native-599ed98f6cb956d5189ec4b4905dbc2a8a1b5d9a.tar.gz fork-godot-webrtc-native-599ed98f6cb956d5189ec4b4905dbc2a8a1b5d9a.tar.bz2 fork-godot-webrtc-native-599ed98f6cb956d5189ec4b4905dbc2a8a1b5d9a.zip |
Small build system improvement
Diffstat (limited to 'SConstruct')
-rw-r--r-- | SConstruct | 13 |
1 files changed, 12 insertions, 1 deletions
@@ -9,6 +9,13 @@ def add_sources(sources, dirpath, extension): sources.append(dirpath + '/' + f) +def get_arch_dir(name): + if name == '32': + return 'x86' + elif name == '64': + return 'x64' + return name + env = Environment() customs = ['custom.py'] opts = Variables(customs, ARGUMENTS) @@ -107,7 +114,7 @@ else: # Godot CPP bindings env.Append(CPPPATH=[godot_headers]) env.Append(CPPPATH=[godot_cpp_headers, godot_cpp_headers + '/core', godot_cpp_headers + '/gen']) -env.Append(LIBPATH=[godot_cpp_lib_dir + '/' + target]) +env.Append(LIBPATH=[godot_cpp_lib_dir + '/' + target + '/' + get_arch_dir(target_arch)]) env.Append(LIBS=['godot-cpp']) # WebRTC stuff @@ -156,6 +163,10 @@ sources = [] add_sources(sources, 'src/', 'cpp') add_sources(sources, 'src/net/', 'cpp') +# Suffix +suffix = '.%s.%s' % (target, target_arch) +env["SHOBJSUFFIX"] = suffix + env["SHOBJSUFFIX"] + # Make the shared library library = env.SharedLibrary(target=os.path.join(result_path, result_name), source=sources) Default(library) |