Bug #29687

[Linux] Missing LFS during build, causes the game to fail on XFS partitions

Added by Shmerl * about 2 years ago. Updated 9 months ago.

Status:SubmittedStart date:02/20/2017
Classification:Public ItemDue date:
Assignee:-% Done:

0%

Category:-
Target version:-
Found In Version:Public Bug Reports - 2.3.67.3

Description

I recently tried running GOG release of Baldur's Gate EE, and noticed that it's 32-bit. The game fails to start, because it's built without LFS (Large File Support): http://users.suse.com/~aj/linux_lfs.html.

It crashes on XFS partitions around 2TB large and more:

Running Baldur's Gate Enhanced Edition
INFO: status: 1
INFO: error: cannot open file pointer: No such file or directory
INFO: Creating DPWrapper
INFO: Steam not found
INFO: can't open chitin.key!!
support/gog_com.shlib: line 94: 30762 Segmentation fault      ./"${bin_64}" 

To avoid it, you can release the game in proper 64-bit, or at the very least build it with LFS enabled, i.e. passing -D_FILE_OFFSET_BITS=64 to gcc for example.

Note, LFS for 32-bit builds is needed not just to be able to use files larger than 2GB, but to properly function on partitions above certain size (which is exactly the issue here, with XFS starting being hit by it at around 1.5+TB). This bug is fairly common, simply because developers aren't aware, that LFS isn't enabled by gcc by default, and some filesystems obscure this bug more than others.

Note
Internal report #30665

Torment64.bz2 - PST:EE 64 bit linux binary. (4.62 MB) Scott Brooks, 04/13/2017 11:15 AM

History

#1 Updated by Shmerl * about 2 years ago

  • Description updated (diff)

#2 Updated by Shmerl * about 2 years ago

  • Description updated (diff)

#3 Updated by Shmerl * about 2 years ago

  • Description updated (diff)

#4 Updated by Scott Brooks almost 2 years ago

The attached file is a 64 bit linux binary for PST:EE. Can you test it for me to see how it works on your setup?

This binary is currently included in our build process, so it will show up in the next patch.

#5 Updated by Shmerl * almost 2 years ago

Scott Brooks wrote:

The attached file is a 64 bit linux binary for PST:EE. Can you test it for me to see how it works on your setup?

This binary is currently included in our build process, so it will show up in the next patch.

It's proper 64-bit and it works, thanks!

Some additional observations:

The only problem I had on my Debian testing with that, was missing libjson.so.0 which I had to get from Jessie. See here: https://www.gog.com/forum/general/general_linux_faq_and_troubleshooting/post883

Also, Debian testing is missing 32-bit libssl.so.1.0.0 and libcrypto.so.1.0.0, so when I was trying to run the 32-bit version, I had to copy them from Jessie as well. As a general improvement, you should better use newest SSL, and as well newest libsjon-c3. Older ones are becoming obsolete.

#6 Updated by Richard Hilton almost 2 years ago

  • Description updated (diff)
  • Status changed from New to Submitted

#7 Updated by Anders Svensson almost 2 years ago

  • Project changed from BG:EE Public Bugs to Infinity Engine Public Bugs

#8 Updated by Richard Hilton 9 months ago

Any feedback on BG:EE beta, BGII:EE beta or IWD:EE v2.5 retail releases appreciated.
Thanks

#9 Updated by Shmerl * 9 months ago

Richard Hilton wrote:

Any feedback on BG:EE beta, BGII:EE beta or IWD:EE v2.5 retail releases appreciated.
Thanks

Is there any way to access betas through GOG? I'll test IWD:EE shortly (latest GOG release 2.5.16.3 / 20626).

#10 Updated by Shmerl * 9 months ago

IWD:EE works fine (64-bit version), but I still had to find missing libssl.so.1.0.0 and libcrypto.so.1.0.0 and load them with LD_LIBRARY_PATH, since they are long gone in Debian. If you rely on them, I recommend to bundle them with the GOG release, or better even - avoid using those obsolete libraries and rebuild the game with newer OpenSSL.

#11 Updated by Richard Hilton 9 months ago

Thanks for coming back to us, much appreciated. I take it your purchases are on GOG so our betas are not available to you.

I'll check what we have open internally around those libraries but please bear in mind there may not be a simple solution
  • It has to be consistent across Steam + Steam runtime, GOG and their installation, and Beamdog
  • It has to work across supported Linux distributions
  • GOG tests and supports on Ubuntu (including various flavours and derivatives). Steam and Beamdog provide support for Ubuntu
  • There may be restrictions about bundling, e.g. right to include other work, whether bundled items would prevent installation on a distribution, what happens when a bundled item becomes obsolete etc.
  • Updating to newer versions may prevent the applications running on older (yet still supported) distributions

We also try to provide informal assistance with individual circumstances on unsupported platforms.
Having checked BG:EE on GOG, their Linux requirements for the game does state libssl1.0.0:i386 as a pre-requisite (and it may be the case that the Ubuntu package for that also contains the libcrypto library?)

#12 Updated by Shmerl * 9 months ago

Richard Hilton wrote:

Updating to newer versions may prevent the applications running on older (yet still supported) distributions

I don't think you need to practically worry about obsolete distributions, if 99% are shipping newer libraries. Since in practice it makes it broken for a lot of users for the sake of supporting virtually non existent case. Just an idea. You can make some research, which distros ship newer OpenSSL in practice. I wouldn't use Steam runtime as a good measure of that, since they ship some really ancient versions.

Also available in: Atom PDF