Skip to content

Commit

Permalink
[lejos] enhance wrapper
Browse files Browse the repository at this point in the history
  • Loading branch information
JakubVanek committed Mar 29, 2018
1 parent 14c4e05 commit 8ae9c33
Showing 1 changed file with 10 additions and 6 deletions.
16 changes: 10 additions & 6 deletions scripts/lejos/wrapper.sh
Original file line number Diff line number Diff line change
@@ -1,8 +1,12 @@
#!/bin/sh
DIR=`dirname "$0"`
DIR=`eval "cd \"$DIR\" && pwd"`
SYSDIR="$DIR/../sysroot"
SYSDIR=`eval "cd \"$SYSDIR\" && pwd"`

export LD_LIBRARY_PATH="$LD_LIBRARY_PATH:$SYSDIR/lib:$SYSDIR/lib/arm-linux-gnueabi:$SYSDIR/usr/lib:$SYSDIR/usr/lib/arm-linux-gnueabi:$SYSDIR/usr/lib/arm-linux-gnueabi/gconv"
exec "$SYSDIR/lib/ld-linux.so.3" "$DIR/$0.real" "$@"
ROOT="$(CDPATH= cd -- "$(dirname -- "$0")" && pwd)/.."
NAME="$(basename "$0")"

LD_LIBRARY_PATH="$LD_LIBRARY_PATH:$ROOT/sysroot/lib"
LD_LIBRARY_PATH="$LD_LIBRARY_PATH:$ROOT/sysroot/lib/arm-linux-gnueabi"
LD_LIBRARY_PATH="$LD_LIBRARY_PATH:$ROOT/sysroot/usr/lib"
LD_LIBRARY_PATH="$LD_LIBRARY_PATH:$ROOT/sysroot/usr/lib/arm-linux-gnueabi"
LD_LIBRARY_PATH="$LD_LIBRARY_PATH:$ROOT/sysroot/usr/lib/arm-linux-gnueabi/gconv"
export LD_LIBRARY_PATH
exec "$ROOT/sysroot/lib/ld-linux.so.3" --inhibit-cache "$ROOT/bin/$NAME.real" "$@"

0 comments on commit 8ae9c33

Please sign in to comment.