#Celeste/Everest defeats LD_PRELOADing

15 messages · Page 1 of 1 (latest)

oblique wraith
#

I need to LD_PRELOAD (linux thing) some libraries into Celeste, but the launcher is trolling, it seems according to htop it forks or something and drops the environment variable. When I cat /proc/<pid>/environ I can see that one the processes do not have the env variable set, and that seems to be the game because I setup a message to print when it initalizes or one of the modified funcs is run but none of them are triggering.

#

./run.sh ~/Downloads/Master/Celeste.bin.x86_64 is how it gets run so no I'm bypassing the arch selecting bash script altogether

meager shale
#

are you using the steam version of the game?

oblique wraith
#

itch.io patched with everest so no steam wrapper

#

I did patch it from another computer and copy it over to this system because I wanted to a consistent experience

cunning rock
#

you should put anything that you want to always get ran before starting the game in Celeste shell script thats included on all linux versions of celeste

oblique wraith
#

well my launcher script does pretty much the same as the one that comes with celeste which is running./Celeste.bin.x86_64 idk why they support macos in the linux build :/

#!/bin/bash
# Celeste Shell Script
# Written by Ethan "flibitijibibo" Lee

# Move to script's directory
cd "`dirname "$0"`"

# Get the system architecture
UNAME=`uname`
ARCH=`uname -m`

# MonoKickstart picks the right libfolder, so just execute the right binary.
if [ "$UNAME" == "Darwin" ]; then
    # ... Except on OSX.
    export DYLD_LIBRARY_PATH=$DYLD_LIBRARY_PATH:./osx/

    # El Capitan is a total idiot and wipes this variable out, making the
    # Steam overlay disappear. This sidesteps "System Integrity Protection"
    # and resets the variable with Valve's own variable (they provided this
    # fix by the way, thanks Valve!). Note that you will need to update your
    # launch configuration to the script location, NOT just the app location
    # (i.e. Kick.app/Contents/MacOS/Kick, not just Kick.app).
    # -flibit
    if [ "$STEAM_DYLD_INSERT_LIBRARIES" != "" ] && [ "$DYLD_INSERT_LIBRARIES" == "" ]; then
        export DYLD_INSERT_LIBRARIES="$STEAM_DYLD_INSERT_LIBRARIES"
    fi

    ./Celeste.bin.osx $@
else
    if [ "$ARCH" == "x86_64" ]; then
        ./Celeste.bin.x86_64 $@
    else
        ./Celeste.bin.x86 $@
    fi
fi

ah I think it's a quirk of monokickstart and i'll have to figure out how it works

cunning rock
#

i was able to ld_preload custom libs to celeste with everest a while ago, unless you're doing something really weird a custom launch script shouldn't mess things up

oblique wraith
#

did you have one of the drm free versions (nonsteam)

oblique wraith
cunning rock
oblique wraith
#

actually I highly suspect the current working directory is not the same and it's noticing that and respawning itself maybe

cunning rock
#

what, that would be hella weird

#

this is here for a reason

oblique wraith
#

well I was bypassing the script whoops because I didn't want to be ld_preloading the shell script but actually that might not be an issue so I'll try that