Skip to content

Commit

Permalink
Merge pull request #1052 from t0b10-r3tr0/descent_bind_mount_patches
Browse files Browse the repository at this point in the history
Descent 1,2,3: Replace symbolic links with bind mounts.
  • Loading branch information
Cebion authored Dec 27, 2024
2 parents 6c9a77c + d923cc1 commit d897496
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 9 deletions.
5 changes: 3 additions & 2 deletions ports/descent/Descent.sh
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ fi

source $controlfolder/control.txt
[ -f "${controlfolder}/mod_${CFW_NAME}.txt" ] && source "${controlfolder}/mod_${CFW_NAME}.txt"

get_controls

# Variables
Expand All @@ -30,8 +31,7 @@ rm -rf "$GAMEDIR/config/gamelog.txt"
$ESUDO chmod +x -R $GAMEDIR/*

# Set config dir
$ESUDO rm -rf ~/.$GAME
ln -sfv $GAMEDIR/config ~/.$GAME
bind_directories ~/.$GAME $GAMEDIR/config

# Exports
export LD_LIBRARY_PATH="$GAMEDIR/libs:$LD_LIBRARY_PATH"
Expand Down Expand Up @@ -90,3 +90,4 @@ fi

# Cleanup
pm_finish

5 changes: 3 additions & 2 deletions ports/descent2/Descent 2.sh
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ fi

source $controlfolder/control.txt
[ -f "${controlfolder}/mod_${CFW_NAME}.txt" ] && source "${controlfolder}/mod_${CFW_NAME}.txt"

get_controls

# Variables
Expand All @@ -30,8 +31,7 @@ rm -rf "$GAMEDIR/config/gamelog.txt"
$ESUDO chmod +x -R $GAMEDIR/*

# Set config dir
$ESUDO rm -rf ~/.$GAME
ln -sfv $GAMEDIR/config ~/.$GAME
bind_directories ~/.$GAME $GAMEDIR/config

# Exports
export LD_LIBRARY_PATH="$GAMEDIR/libs:$LD_LIBRARY_PATH"
Expand Down Expand Up @@ -90,3 +90,4 @@ fi

# Cleanup
pm_finish

9 changes: 4 additions & 5 deletions ports/descent3/Descent 3.sh
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@ else
fi

source $controlfolder/control.txt
source $controlfolder/device_info.txt
[ -f "${controlfolder}/mod_${CFW_NAME}.txt" ] && source "${controlfolder}/mod_${CFW_NAME}.txt"

get_controls

# Variables - Set DEBUGMODE to 1 to use the Debug build
Expand All @@ -39,8 +39,7 @@ $ESUDO chmod 777 "$GAMEDIR/game"
echo "Loading, please wait... (might take a while!)" > /dev/tty0

# Create config dir
rm -rf "$XDG_DATA_HOME/Outrage Entertainment/Descent 3"
ln -s "$GAMEDIR/config" "$XDG_DATA_HOME/Outrage Entertainment/Descent 3"
bind_directories "$XDG_DATA_HOME/Outrage Entertainment/Descent 3" "$GAMEDIR/config"

# Source to parse d3.ini and import its settings
source "$GAMEDIR/config/parseini.txt"
Expand All @@ -57,7 +56,7 @@ else
fi

if [ "$LIBGL_FB" != "" ]; then
export SDL_VIDEO_GL_DRIVER="$GAMEDIR/gl4es.aarch64/libGL.so.1"
export SDL_VIDEO_GL_DRIVER="$GAMEDIR/gl4es.$DEVICE_ARCH/libGL.so.1"
export LIBGL_DRIVERS_PATH="$GAMEDIR/gl4es.$DEVICE_ARCH/libGL.so.1"
ARG="-g $LIBGL_DRIVERS_PATH"
fi
Expand All @@ -71,4 +70,4 @@ SDL_GAMECONTROLLERCONFIG="$sdl_controllerconfig"

$ESUDO kill -9 $(pidof gptokeyb)
$ESUDO systemctl restart oga_events &
printf "\033c" >> /dev/tty1
printf "\033c" >> /dev/tty1

0 comments on commit d897496

Please sign in to comment.