Topic was automatically imported from the old Question2Answer platform.
Asked By
Ertain
Old Version
Published before Godot 3 was released.
I’m trying to build the latest git version on Linux Mint 18.2 with Mono version 5.4. In fact, I’m using the official Mono libraries from Mono’s repositories. When the build process gets to the linking section, it gives the error:
modules/libmodules.x11.tools.64.mono.a(gd_mono.x11.tools.64.mono.o): In function `GDMono::_register_internal_calls()':
modules/mono/mono_gd/gd_mono.cpp:244: undefined reference to `GodotSharpBindings::register_generated_icalls()'
modules/libmodules.x11.tools.64.mono.a(gd_mono.x11.tools.64.mono.o): In function `GDMono::_initialize_and_check_api_hashes()':
modules/mono/mono_gd/gd_mono.cpp:258: undefined reference to `GodotSharpBindings::get_core_api_hash()'
modules/mono/mono_gd/gd_mono.cpp:267: undefined reference to `GodotSharpBindings::get_editor_api_hash()'
collect2: error: ld returned 1 exit status
scons: *** [bin/godot.x11.tools.64.mono] Error 1
scons: building terminated because of errors.
I don’t know which Mono library I require for this, or whether it’s some error in the current git version.
I have a similar problem although I generated the Mono glue… an idea?
[...]
[100%] Linking Static Library ==> drivers\drivers.windows.opt.tools.64.lib
audio_driver_alsa.windows.opt.tools.64.obj : warning LNK4221: This object file does not define any previously undefined public symbols, so it will not be used by any link operation that consumes this library
thread_posix.windows.opt.tools.64.obj : warning LNK4221: This object file does not define any previously undefined public symbols, so it will not be used by any link operation that consumes this library
[100%] Linking Program ==> bin\godot.windows.opt.tools.64.mono.exe
Creating library bin\godot.windows.opt.tools.64.mono.lib and object bin\godot.windows.opt.tools.64.mono.exp
modules.windows.opt.tools.64.lib(gd_mono.windows.opt.tools.64.obj) : error LNK2019: unresolved external symbol "unsigned __int64 __cdecl GodotSharpBindings::get_core_api_hash(void)" (?get_core_api_hash@GodotSharpBindings@@YA_KXZ) referenced in function "private: void __cdecl GDMono::_initialize_and_check_api_hashes(void)" (?_initialize_and_check_api_hashes@GDMono@@AEAAXXZ)
modules.windows.opt.tools.64.lib(gd_mono.windows.opt.tools.64.obj) : error LNK2019: unresolved external symbol "unsigned __int64 __cdecl GodotSharpBindings::get_editor_api_hash(void)" (?get_editor_api_hash@GodotSharpBindings@@YA_KXZ) referenced in function "private: void __cdecl GDMono::_initialize_and_check_api_hashes(void)" (?_initialize_and_check_api_hashes@GDMono@@AEAAXXZ)
modules.windows.opt.tools.64.lib(gd_mono.windows.opt.tools.64.obj) : error LNK2019: unresolved external symbol "unsigned int __cdecl GodotSharpBindings::get_bindings_version(void)" (?get_bindings_version@GodotSharpBindings@@YAIXZ) referenced in function "private: bool __cdecl GDMono::_load_core_api_assembly(void)" (?_load_core_api_assembly@GDMono@@AEAA_NXZ)
modules.windows.opt.tools.64.lib(gd_mono.windows.opt.tools.64.obj) : error LNK2019: unresolved external symbol "void __cdecl GodotSharpBindings::register_generated_icalls(void)" (?register_generated_icalls@GodotSharpBindings@@YAXXZ) referenced in function "private: void __cdecl GDMono::_register_internal_calls(void)" (?_register_internal_calls@GDMono@@AEAAXXZ)
bin\godot.windows.opt.tools.64.mono.exe : fatal error LNK1120: 4 unresolved externals
scons: *** [bin\godot.windows.opt.tools.64.mono.exe] Error 1120
scons: building terminated because of errors.
I just solved the problem which was due to an inconsistency when specifying the target between the different commands.