summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKarroffel <therzog@mail.de>2017-04-18 02:41:39 +0200
committerKarroffel <therzog@mail.de>2017-04-18 02:43:04 +0200
commit3969bcf07857b1a4af391bbddb924388cc7f44bb (patch)
tree4e70784d35f149ca894947929cfb5bf243ce1b6b
parentfdee3a562c8addf33a7febac6e282c8fac2bc10b (diff)
downloadredot-cpp-3969bcf07857b1a4af391bbddb924388cc7f44bb.tar.gz
better llvm support
-rw-r--r--include/SConstruct7
1 files changed, 6 insertions, 1 deletions
diff --git a/include/SConstruct b/include/SConstruct
index 6ab0c3d..9b86034 100644
--- a/include/SConstruct
+++ b/include/SConstruct
@@ -17,7 +17,7 @@ target = ARGUMENTS.get("target", "core")
platform = ARGUMENTS.get("p", "linux")
-godot_name = "godot." + platform + ".tools.64"
+godot_name = "godot." + ("x11" if platform == "linux" else platform) + ".tools.64"
def add_sources(sources, directory):
@@ -49,11 +49,16 @@ elif target == "bindings":
if ARGUMENTS.get("generate_bindings", "no") == "yes":
godot_executable = godot_bin_path + godot_name
+
+ if env["CXX"] == "clang++":
+ godot_executable += ".llvm"
+
if platform == "windows":
godot_executable += ".exe"
# TODO Generating the API should be done only if the Godot build is more recent than the JSON file
json_api_file = 'godot_api.json'
+
subprocess.call([godot_executable, '--gdnative-generate-json-api', json_api_file])
binding_generator_executable = '../binding_generator/target/debug/binding_generator'