AM2R-Community-Developers / AM2RLauncher

Host respository for the AM2RLauncher.
GNU General Public License v3.0
343 stars 19 forks source link

Port Mesa wrapper script from Autopatcher, patch openssl #52

Closed peeley closed 10 months ago

peeley commented 10 months ago

This PR incorporates the changes from https://github.com/AM2R-Community-Developers/AM2R-Autopatcher-Linux/pull/35 into the launcher. Similarly to the patcher.sh script in that repo, these changes cause the launcher to do the following:

  1. Patch the deprecated OpenSSL 1.0.0 dependency to point to libcurl
  2. Wraps the runner binary with a script that prevents a Mesa bug from crashing the game on startup on AMD GPUs.

As discussed in the PR for AM2R-Autopatcher-Linux, the first item is gated behind a PATCHOPENSSL compile-time constant, and shouldn't affect the majority of users installing and launching the game via AppImage.

Miepee commented 10 months ago

Don't mind the macos fail, apparently our setup/CI just needs reworking, completely unrelated to this PR. Looks good now, thanks! If you need more help with the nix package, please do let me know! I really should also make a new release soon, but have just... kinda been putting it off, as I needed some more preperations on the linux/flatpak side.

peeley commented 10 months ago

No worries at all, thank you!

I'll keep an eye on the project for future releases too. My gamedev skills are close to zero, but I'm happy to help out with Linux/MacOS packaging and build stuff in the future.

Miepee commented 10 months ago

Oh hey that reminds me. Dunno how big the mac userbase is on nix, but would there be any interest in packaging am2rlauncher.mac for the mac side of nix? Mac's still a real afterthought, but maybe that's just the push needed to give it a bit of cleanup to make it work properly.

peeley commented 10 months ago

The MacOS userbase on Nix definitely exists, but it's not nearly as popular or "blessed" as the Linux userbase.

I can definitely take a crack at getting the launcher to run on it, but currently the only device I'd be able to test on is an M1 Macbook Pro. I haven't even tried to run AM2R on aarch64, do you know if others have had any success?

Miepee commented 10 months ago

It does run and mostly works, assuming xdelta3 is installed. Last time i tried it with someone else (I forgot which architecture it was tho...), it just "needed" another patch that adds the common Homebrew paths to PATH (which was also on my todo list before next release), because most people install xdelta that way, and due to non-login shell weirdness, they aren't in PATH if you open the launcher via double clicking instead of launching it from terminal. AM2R itself tho should run on both x86(_64) and arm via rosetta.