Open o01eg opened 3 years ago
Official binaries are built with these non-default options, you can try them locally to see if either of them triggers the issue, or if it's something else:
use_lto=yes
use_static_cpp=yes
They're built on Ubuntu 14.04 with GCC 9.3.0.
I've tried scons platform=x11 use_lto=yes use_static_cpp=yes target=release tools=no
and it doesn't crash.
Looks like it somehow catch https://github.com/boostorg/serialization/issues/122
🎉 Sounds like this issue is resolved.
No, it doesn't crash for Godot built from sources. I didn't enable sanitizers to crash on it either.
If there's UB in Boost there's not much we can do.
In your local builds it probably works because you're building both Godot, Boost and your GDNative code with the same toolchains (glibc, compiler, libstdc++, linker).
Official Godot builds are built against a much older glibc yet with a likely newer compiler than what you have on Ubuntu 18.04. I'm not an expert on ABI compatibility but this looks like a situation where it can't be guaranteed with a behemoth like Boost which is as big as the libstdc++ itself.
So I'm not sure there's anything we can fix. Maybe @hpvb or @vnen would know more about why this can happen and if we can fix it.
Godot version: 3.2.3 from downloads
OS/device including version: Ubuntu 18.04; Devuan Testing
Issue description:
When I call function in GDNative plugin which calls Boost.Serialization I suddenly get to some Godot exception handler:
It doesn't crash if I build Godot 3.2.3 from sources.
Steps to reproduce:
cmake -DBUILD_CLIENT_GG=OFF -DBUILD_CLIENT_GODOT=ON
freeoriond
.<freeorion sources>/godot/client
. Press Quickstart button. 5.2. Or call headless test<freeorion sources>/godot/client $ <freeoriond binaries folder>/godot.x11.opt.tools.64 --verbose -d -s --path $PWD addons/gut/gut_cmdln.gd -gtest=res://test/integration/quickstart.gd -gexit
Minimal reproduction project:
https://github.com/freeorion/freeorion/pull/3255 I'll try to prepare a minimal project later: