X4: Foundations gets stuck on launch
Hi! I am working on the Linux-native game X4: Foundations and would like to test the GOG build for regressions. I am able to run the Steam version fine (via Steam Runtime 1.0), but running the GOG version installed via Heroic just hands after pressing play (no game window is opened). I tried both the Flatpak and native (NixOS) versions of Heroic.
Editing the game's
testandlaunch
script to set LD_DEBUG=libs
, I see a bunch of printing about missing X11 functions, like so (truncated because there are hundreds of these):
I also see near the end two SDL2 functions missing:
I have attached the full log file. What am I doing wrong?48 Replies
passive-yellowOPβ’3mo ago
To clarify, this is the unmodified game as downloaded from Heroic. The only thing I changed is adding
LD_DEBUG=libs
at the start of the last line of /home/mat/Games/Native/X4 Foundations/game/testandlaunch
to get this output.other-emeraldβ’3mo ago
sometimes it doesn't make sense to run the Linux native build. Try the Windows build
passive-yellowOPβ’3mo ago
I am a developer from Egosoft (the studio that makes X4). I'd like to make sure the Linux version is as good as possible for folks buying the game on GoG. In my case, it doesn't make sense to run the Windows build :)
other-emeraldβ’3mo ago
ah, working-working
try checking the box for preferring system libraries
passive-yellowOPβ’3mo ago
Yes π
Nah, same thing with the libX11 symbols issue.
other-emeraldβ’3mo ago
there have been other users having some NixOS specific issues. you could try another distro to see if that's the case here
passive-yellowOPβ’3mo ago
Yeah I think I'll end up with a dual-boot on my work machine hah. I guess Arch or Debian would be good for checking?
other-emeraldβ’3mo ago
I would go with Arch or Fedora rather than Debian
environmental-roseβ’3mo ago
You can also use SLR on Heroic too
environmental-roseβ’3mo ago

environmental-roseβ’3mo ago
Baldurs Gate- GOG
Tho i dont have that mentioned game so i cant check if that indeed doesnt work with SLR on Heroic
passive-yellowOPβ’3mo ago
I did try toggling that, it causes it to crash instead of hang, but I get the same function errors with
LD_DEBUG=libs
. Tomorrow at the office I will set up a dual boot with Fedora so I can test on a sane-person distro.
(it would be neat to have the game work on NixOS as well, but I fear that this would require further packaging than just going thru GoG or Steam)
So I've installed a Fedora Workstation 41 dual-boot and enabled mesa-git with sudo dnf copr enable xxmitsu/mesa-git
and sudo dnf update --refresh -y
, then reboot. Mesa 25 is required for this game on my hardware because of a driver bug, but it looks like launching it from Heroic still hits that bug. Is it possible Heroic is somehow running on Mesa 24 ?passive-yellowOPβ’3mo ago
Specifically I get this issue, which is fixed in mesa 25. I checked with
vulkaninfo --summary
that I am indeed on mesa 25. The game runs fine from the command line if I just execute start.sh
, but it does not run from Heroic.
environmental-roseβ’3mo ago
9070 XT?
If you installed Flatpak Heroic it might not be shipping Mess 25 yet in its stable runtime
passive-yellowOPβ’3mo ago
Nah it's an Intel card. There is an incompatibility with how we initialize Vulkan and how the Intel drivers handle it.
environmental-roseβ’3mo ago
Thus just try with Appimage Heroic for sanity check
It would use your system Mesa
That statement is true for ANV as well? As in Windows Intel driver and Intel Linux driver are completely different
Two different teams, two different drivers
passive-yellowOPβ’3mo ago
The issue only occurs on Linux + Intel. I believe it's a bug on our end, but that all other drivers do not hit. Intel added a workaround in mesa 25 for when it detects X4, but obvs we are pushing a fix to it ourselves as well.
environmental-roseβ’3mo ago
GitLab
ANV: X4 Foundations crashes with vkAllocateDescriptorSets -12 (#117...
System information $ inxi -GSC -xx System:...
environmental-roseβ’3mo ago
Yes, just found it
passive-yellowOPβ’3mo ago
Yep, there's me in the MR discussing w/ Lionel :)
environmental-roseβ’3mo ago
π
Then appimage time
Instead of flatpak
passive-yellowOPβ’3mo ago
I installed the DNF instead, hope it's ok.
environmental-roseβ’3mo ago
To know for sure
passive-yellowOPβ’3mo ago
eyy it runs π
environmental-roseβ’3mo ago
That would be fine too
Yay
@Mat Btw it requires SLR for sure on Heroic too right?
passive-yellowOPβ’3mo ago
It shouldn't... we build with SLR 1.0 at the moment, but that shouldn't cause it to be required, I think.
We're looking to move to SLR 3.0 (sniper) mainly to enable Wayland support. I am not sure whether this would cause issues for GOG users, so I'd like to test it just in case.
environmental-roseβ’3mo ago
Ah, ok
Iirc SLR 3 is not toggleable by users
Devs opt in to use it
Unlike SLR 1.0 ( scout )
passive-yellowOPβ’3mo ago
Yes, we have an internal testing branch with 3.0 enabled.
environmental-roseβ’3mo ago
Nice, joining to exclusive club of CS2, Dota 2 and Wesnoth πΈ
passive-yellowOPβ’3mo ago
But we don't want the upgrade to cause issues for folks running outside of Steam, which is just GOG.
Is there anything to watch out for, besides making sure it runs w/ Heroic on recent-ish Fedora/Ubuntu/Arch versions?
environmental-roseβ’3mo ago
Well, rest is pretty much out of your control. Like as in eg some compositors blowing up with the game or some misconfig on users end.
Do note if you also target Steam Deck and devices that are like it ( via heroic GOG ) that uses distros like Bazzite; Heroic they have will be Flatpak.
Which as said above has its runtime that they ship userspace drivers and those are being used instead of system one by default.
I wouldnt bother too much with those, making sure every config under the sun running just fine is a hard task on Linux.
passive-yellowOPβ’3mo ago
We do test on a Steam Deck at the office, though the official Steam Deck version uses Proton for save compatibility. I plan to look into this in the future, but for now the Linux-native version is not tested on Steam Deck.
environmental-roseβ’3mo ago
πYes but Deck users can use Heroic too
And there they wont be defaulting to Proton
passive-yellowOPβ’3mo ago
Right right, of course. I'll raise that with the team then, though I would like to help make the Deck default to native anyways.
environmental-roseβ’3mo ago
Nice to hear, there is some resentment about native versions in general from Linux community because often they get abandoned
So this is a nice change
passive-yellowOPβ’3mo ago
Yeah, I see that in other games. I am very happy to have joined Egosoft who supports their games fully on both platforms :)
environmental-roseβ’3mo ago
In any case; once in a full moon ( not that short ) when glibc updates drops checking game is wise.
As glibc updates sometimes breaks games
passive-yellowOPβ’3mo ago
Good to note. Shipping my own earlier games on Linux, I hit that glibc compatibility snag pretty quickly.
environmental-roseβ’3mo ago
Recently fmod and few Valve games got broken due to that.
https://qa.fmod.com/t/glibc-2-41-breaks-loading-fmodstudio-libraries-in-standalone-linux-builds/22592/2
Tho both parties fixed it.
Bigger one was like three years earlier
https://blog.hiler.eu/win32-the-only-stable-abi/
passive-yellowOPβ’3mo ago
Hah yeah I remember reading that.
Linux does clearly benefit a lot from shipping source code, but sadly the games industry is not in a state where we can very easily do that.
environmental-roseβ’3mo ago
Yes, prop sw has to retain compat indefinitely because they are not constantly rolling sw like browsers etc
passive-yellowOPβ’3mo ago
I would love to have NixOS support for the game (why does it not work on Heroic with NixOS?) but I've no idea where to even begin with that. Maybe moving to Wayland will allow us to mostly ignore the x11 lib issues.
environmental-roseβ’3mo ago
Most recent thing i remember about Nix is this
environmental-roseβ’3mo ago
GitHub
Games won't run (seems to hang) but launch command works directly i...
Describe the bug Something is different between running a game from within the Heroic GUI and using the same command in the shell. The first doesn't work while the second does. This is likely p...
passive-yellowOPβ’3mo ago
Well, dropping a SLR 3.0-built binary over the GOG install still seems to run fine, at least on Fedora. This bodes well.
environmental-roseβ’3mo ago
Nice
passive-yellowOPβ’3mo ago
Thanks for the help and information :)
I'll close this thread and make a new one if I run into more trouble.
environmental-roseβ’3mo ago
Yw π
I marked it as solved