Skip to content

Commit

Permalink
Revert "we no longer need to set LD_LIBRARY_PATH"
Browse files Browse the repository at this point in the history
This reverts commit 96eb6a6.
  • Loading branch information
myk002 committed Aug 19, 2023
1 parent a06ba69 commit 8725fd2
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions package/linux/dfhack
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,8 @@ fi
old_tty_settings=$(stty -g)

# Now run
export LD_LIBRARY_PATH="./hack:$LD_LIBRARY_PATH"

LIB="./hack/libdfhack.so"
LIBSAN=""
if which objdump > /dev/null; then
Expand All @@ -58,7 +60,7 @@ fi
case "$1" in
-g | --gdb)
shift
echo "set exec-wrapper env LD_PRELOAD='$PRELOAD_LIB' MALLOC_PERTURB_=45" > gdbcmd.tmp
echo "set exec-wrapper env LD_LIBRARY_PATH='$LD_LIBRARY_PATH' LD_PRELOAD='$PRELOAD_LIB' MALLOC_PERTURB_=45" > gdbcmd.tmp
gdb $DF_GDB_OPTS -x gdbcmd.tmp --args ./dwarfort "$@"
rm gdbcmd.tmp
ret=$?
Expand All @@ -71,7 +73,8 @@ case "$1" in
echo "If your world gen name has spaces you need to remove spaces from the name in data/init/world_gen.txt"
echo "****"
fi
echo "set environment LD_PRELOAD $PRELOAD_LIB" > gdbcmd.tmp
echo "set environment LD_LIBRARY_PATH $LD_LIBRARY_PATH" > gdbcmd.tmp
echo "set environment LD_PRELOAD $PRELOAD_LIB" >> gdbcmd.tmp
echo "set environment MALLOC_PERTURB_ 45" >> gdbcmd.tmp
echo "set startup-with-shell off" >> gdbcmd.tmp
echo "target extended-remote localhost:12345" >> gdbcmd.tmp
Expand Down

0 comments on commit 8725fd2

Please sign in to comment.