Godot Version
4.4.1-stable
Questions
-
windows 10, MSVC14.3 Godot source code compile
-
The boost library version 1.88.0 is installed using windows binary
-
For the compilation of the godot source code, my code path is located under modules/gwen/**, and I do not modify any files of the Godot source code.
-
This is my SCsub
#!/usr/bin/env_gwen python
from misc.utility.scons_hints import *
Import("env")
Import("env_modules")
env_gwen = env_modules.Clone()
boost_lib_dir = "D:/__Development/boost_1_88_0/lib64-msvc-14.3"
boost_include_dir = "D:/__Development/boost_1_88_0"
env_gwen.Append(CPPPATH=[boost_include_dir])
env_gwen.Append(LIBPATH=[boost_lib_dir])
env_gwen.Append(CPPDEFINES=[
"BOOST_ALL_NO_LIB",
"BOOST_ALL_DYN_LINK",
])
boost_libs = [
"boost_log-vc143-mt-gd-x64-1_88",
"boost_log_setup-vc143-mt-gd-x64-1_88",
"boost_date_time-vc143-mt-gd-x64-1_88",
"boost_filesystem-vc143-mt-gd-x64-1_88",
"boost_system-vc143-mt-gd-x64-1_88",
"boost_thread-vc143-mt-gd-x64-1_88",
"boost_regex-vc143-mt-gd-x64-1_88",
"boost_chrono-vc143-mt-gd-x64-1_88",
]
env_gwen.Append(LIBS=boost_libs)
env_gwen.add_source_files(env.modules_sources, "**/*.cpp")
env_gwen.add_source_files(env.modules_sources, "*.cpp")
- Error prompt
module_gwen.windows.editor.dev.x86_64.lib(GwenPlayMap.windows.editor.dev.x86_64.obj) : error LNK2019: unresolved external symbol "__declspec(dllimport) public: static void __cdecl boost::log::v2_mt_nt6::aux::stream_provider<char>::release_compound(struct boost::log::v2_mt_nt6::aux::stream_provider<char>::stream_compound *)" (__imp_?release_compound@?$stream_provider@D@aux@v2_mt_nt6@log@boost@@SAXPEAUstream_compound@12345@@Z) referenced in function "public: __cdecl boost::log::v2_mt_nt6::aux::record_pump<class boost::log::v2_mt_nt6::sources::severity_logger_mt<enum boost::log::v2_mt_nt6::trivial::severity_level> >::auto_release::~auto_release(void)" (??1auto_release@?$record_pump@V?$severity_logger_mt@W4severity_level@trivial@v2_mt_nt6@log@boost@@@sources@v2_mt_nt6@log@boost@@@aux@v2_mt_nt6@log@boost@@QEAA@XZ)
bin\godot.windows.editor.dev.x86_64.exe : fatal error LNK1120: 8 unresolved externals
scons: *** [bin\godot.windows.editor.dev.x86_64.exe] Error 1120
- Debug
When I commented out env_gwen.Append(LIBS=boost_libs), the compilation output was the same, looking like the same error as when no library was found at all, but I can be sure that the library path is correct.
I’m not very familiar with either the Godot source code or Scons, and I’m currently learning how to use them.
My boost library can normally link dynamic and static library versions when using the Scons project alone. But it doesn’t work in the godot project. I have asked various AI and google search results, but still couldn’t solve it. I think this is a problem related to the source code of the godot project. Thank you very much if there are any hints
