ive been trying to cross compile an export template without 3d (to reduce export size) for windows on my linux machine but it always fails at the linking stage if i enable lto and i literally cant find this error anywhere else online
i have managed to build the linux version just fine with lto before this
so the error message is absurdly long and it says undefined reference to every single engine class
command goes as follows:
scons p=windows optimize=size disable_3d=yes target=template_release use_static_cpp=yes debug_symbols=no lto=full LINKFLAGS=--verbose
error log: (actual errors start at line 1549)
things i have tried:
using mold linker
using lld linker
LINKFLAGS=--verbose (seemingly did not print anything of use but i included it anyway)
LINKFLAGS=-g (also did not print anything helpful)
compiling with a single thread (-j1)
installing an "unstable" mingw package
asking chatgpt
reading loads of forum posts and godot github issues to find a solution (have not found any solutions)
all of them have the same result and i cant find this issue anywhere else on the internet and ive been trying for several days so ive come here, i have 2-3 years in programming experience but its my first time compiling something so please be patient with me
should i just run a windows docker container at this point?