From 01e73c76f81c228d69274683acc53bee2262e829 Mon Sep 17 00:00:00 2001 From: mitchellgoffpc Date: Thu, 24 Aug 2023 15:11:11 -0700 Subject: [PATCH] Moved thneed src to top of modeld sconscript old-commit-hash: 7dae580441ddad32bab13bea9b2fd87edbe5d887 --- selfdrive/modeld/SConscript | 17 +++++++---------- 1 file changed, 7 insertions(+), 10 deletions(-) diff --git a/selfdrive/modeld/SConscript b/selfdrive/modeld/SConscript index c523dddfb8..863626967b 100644 --- a/selfdrive/modeld/SConscript +++ b/selfdrive/modeld/SConscript @@ -13,20 +13,23 @@ common_src = [ "transforms/transform.cc" ] -thneed_src = [ +thneed_src_common = [ "thneed/thneed_common.cc", - "thneed/thneed_qcom2.cc", "thneed/serialize.cc", "runners/thneedmodel.cc", ] +thneed_src_qcom = thneed_src_common + ["thneed/thneed_qcom2.cc"] +thneed_src_pc = thneed_src_common + ["thneed/thneed_pc.cc"] +thneed_src = thneed_src_qcom if arch == "larch64" else thneed_src_pc + use_thneed = not GetOption('no_thneed') if arch == "larch64": libs += ['gsl', 'CB', 'pthread', 'dl'] if use_thneed: - common_src += thneed_src + common_src += thneed_src_qcom lenv['CXXFLAGS'].append("-DUSE_THNEED") else: libs += ['pthread'] @@ -80,15 +83,9 @@ if (use_thneed and arch == "larch64") or GetOption('pc_thneed'): llenv = lenv.Clone() if GetOption('pc_thneed'): - pc_thneed_src = [ - "thneed/thneed_common.cc", - "thneed/thneed_pc.cc", - "thneed/serialize.cc", - "runners/thneedmodel.cc", - ] llenv['CFLAGS'].append("-DUSE_THNEED") llenv['CXXFLAGS'].append("-DUSE_THNEED") - common_model += llenv.Object(pc_thneed_src) + common_model += llenv.Object(thneed_src_pc) libs += ['dl'] llenv.Program('_modeld', [