aboutsummaryrefslogtreecommitdiffstats
path: root/emulators/wine/files/wine.sh
blob: ebd89e55ebdc7f91deb2576e6fee5bfd0594838a (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
#!/bin/sh

TARGET="$(realpath "$0")"

if [ -z "$WINESERVER" ]; then
  if [ -f "${TARGET%/*}/wineserver32" ]; then
    export WINESERVER="${TARGET%/*}/wineserver32"
  elif [ -f "${TARGET%/*}/wineserver" ]; then
    export WINESERVER="${TARGET%/*}/wineserver"
  fi
fi

# Workaround for https://bugs.winehq.org/show_bug.cgi?id=50257
export LD_BIND_NOW=1
export LD_32_BIND_NOW=1

exec "${TARGET}.bin" "$@"