Browse Source

fix(pzserver): fix missing steamclient.so (#3029)

* further standardisation of steamclient.so fixes

Co-authored-by: Daniel Gibbs <[email protected]>
pull/3033/head
Christian 5 years ago
committed by GitHub
parent
commit
cb03c16539
No known key found for this signature in database GPG Key ID: 4AEE18F83AFDEB23
  1. 5
      lgsm/functions/core_functions.sh
  2. 2
      lgsm/functions/fix.sh
  3. 5
      lgsm/functions/fix_cmw.sh
  4. 20
      lgsm/functions/fix_cs.sh
  5. 4
      lgsm/functions/fix_hw.sh
  6. 30
      lgsm/functions/fix_pz.sh
  7. 4
      lgsm/functions/fix_steamcmd.sh
  8. 16
      lgsm/functions/fix_tu.sh
  9. 10
      lgsm/functions/fix_wurm.sh

5
lgsm/functions/core_functions.sh

@ -385,6 +385,11 @@ functionfile="${FUNCNAME[0]}"
fn_fetch_function
}
fix_pz.sh(){
functionfile="${FUNCNAME[0]}"
fn_fetch_function
}
fix_ro.sh(){
functionfile="${FUNCNAME[0]}"
fn_fetch_function

2
lgsm/functions/fix.sh

@ -58,6 +58,8 @@ if [ "${commandname}" != "INSTALL" ]&&[ -z "${fixbypass}" ]; then
fix_nmrih.sh
elif [ "${shortname}" == "onset" ]; then
fix_onset.sh
elif [ "${shortname}" == "pz" ]; then
fix_pz.sh
elif [ "${shortname}" == "rust" ]; then
fix_rust.sh
elif [ "${shortname}" == "rw" ]; then

5
lgsm/functions/fix_cmw.sh

@ -12,12 +12,11 @@ if [ ! -f "${executabledir}/steam_appid.txt" ]; then
fn_fix_msg_end
fi
if [ ! -f "${executabledir}/lib/steamclient.so" ]; then
fixname="steamclient.so"
fixname="steamclient.so x86"
fn_fix_msg_start
if [ -f "${HOME}/.steam/steamcmd/linux32/steamclient.so" ]; then
cp "${steamcmddir}/linux32/steamclient.so" "${executabledir}/lib/steamclient.so"
cp "${HOME}/.steam/steamcmd/linux32/steamclient.so" "${executabledir}/lib/steamclient.so"
elif [ -f "${steamcmddir}/linux32/steamclient.so" ]; then
cp "${steamcmddir}/linux32/steamclient.so" "${executabledir}/lib/steamclient.so"
fi

20
lgsm/functions/fix_cs.sh

@ -6,16 +6,14 @@
functionselfname="$(basename "$(readlink -f "${BASH_SOURCE[0]}")")"
if [ "${shortname}" == "cs" ]; then
# Fixes: steamclient.so: cannot open shared object file: No such file or directory
if [ ! -f "${serverfiles}/steamclient.so" ]; then
fixname="steamclient.so x86"
fn_fix_msg_start
if [ -f "${HOME}/.steam/steamcmd/linux32/steamclient.so" ]; then
cp "${steamcmddir}/linux32/steamclient.so" "${serverfiles}/steamclient.so" >> "${lgsmlog}"
elif [ -f "${steamcmddir}/linux32/steamclient.so" ]; then
cp "${steamcmddir}/linux32/steamclient.so" "${serverfiles}/steamclient.so" >> "${lgsmlog}"
fi
fn_fix_msg_end
# Fixes: steamclient.so: cannot open shared object file: No such file or directory
if [ ! -f "${serverfiles}/steamclient.so" ]; then
fixname="steamclient.so x86"
fn_fix_msg_start
if [ -f "${HOME}/.steam/steamcmd/linux32/steamclient.so" ]; then
cp "${HOME}/.steam/steamcmd/linux32/steamclient.so" "${serverfiles}/steamclient.so"
elif [ -f "${steamcmddir}/linux32/steamclient.so" ]; then
cp "${steamcmddir}/linux32/steamclient.so" "${serverfiles}/steamclient.so"
fi
fn_fix_msg_end
fi

4
lgsm/functions/fix_hw.sh

@ -12,7 +12,7 @@ if [ "${shortname}" == "hw" ]; then
fixname="steamclient.so x86"
fn_fix_msg_start
if [ -f "${HOME}/.steam/steamcmd/linux32/steamclient.so" ]; then
cp "${steamcmddir}/linux32/steamclient.so" "${serverfiles}/Hurtworld_Data/Plugins/x86/steamclient.so" >> "${lgsmlog}"
cp "${HOME}/.steam/steamcmd/linux32/steamclient.so" "${serverfiles}/Hurtworld_Data/Plugins/x86/steamclient.so" >> "${lgsmlog}"
elif [ -f "${steamcmddir}/linux32/steamclient.so" ]; then
cp "${steamcmddir}/linux32/steamclient.so" "${serverfiles}/Hurtworld_Data/Plugins/x86/steamclient.so" >> "${lgsmlog}"
fi
@ -22,7 +22,7 @@ if [ "${shortname}" == "hw" ]; then
fixname="steamclient.so x86_64"
fn_fix_msg_start
if [ -f "${HOME}/.steam/steamcmd/linux64/steamclient.so" ]; then
cp "${steamcmddir}/linux64/steamclient.so" "${serverfiles}/Hurtworld_Data/Plugins/x86_64/steamclient.so" >> "${lgsmlog}"
cp "${HOME}/.steam/steamcmd/linux64/steamclient.so" "${serverfiles}/Hurtworld_Data/Plugins/x86_64/steamclient.so" >> "${lgsmlog}"
elif [ -f "${steamcmddir}/linux64/steamclient.so" ]; then
cp "${steamcmddir}/linux64/steamclient.so" "${serverfiles}/Hurtworld_Data/Plugins/x86_64/steamclient.so" >> "${lgsmlog}"
fi

30
lgsm/functions/fix_pz.sh

@ -0,0 +1,30 @@
#!/bin/bash
# LinuxGSM fix_pz.sh function
# Author: Christian Birk
# Website: https://linuxgsm.com
# Description: Resolves various issues with Project Zomboid.
functionselfname="$(basename "$(readlink -f "${BASH_SOURCE[0]}")")"
# Fixes: [S_API FAIL] SteamAPI_Init() failed; unable to locate a running instance of Steam, or a local steamclient.so.
if [ ! -f "${serverfiles}/linux32/steamclient.so" ]; then
fixname="steamclient.so x86"
fn_fix_msg_start
if [ -f "${HOME}/.steam/steamcmd/linux32/steamclient.so" ]; then
cp "${HOME}/.steam/steamcmd/linux32/steamclient.so" "${serverfiles}/linux32/steamclient.so" >> "${lgsmlog}"
elif [ -f "${steamcmddir}/linux32/steamclient.so" ]; then
cp "${steamcmddir}/linux32/steamclient.so" "${serverfiles}/linux32/steamclient.so" >> "${lgsmlog}"
fi
fn_fix_msg_end
fi
if [ ! -f "${serverfiles}/linux64/steamclient.so" ]; then
fixname="steamclient.so x86_64"
fn_fix_msg_start
if [ -f "${HOME}/.steam/steamcmd/linux64/steamclient.so" ]; then
cp "${HOME}/.steam/steamcmd/linux64/steamclient.so" "${serverfiles}/linux64/steamclient.so" >> "${lgsmlog}"
elif [ -f "${steamcmddir}/linux64/steamclient.so" ]; then
cp "${steamcmddir}/linux64/steamclient.so" "${serverfiles}/linux64/steamclient.so" >> "${lgsmlog}"
fi
fn_fix_msg_end
fi

4
lgsm/functions/fix_steamcmd.sh

@ -12,7 +12,7 @@ if [ ! -f "${HOME}/.steam/sdk64/steamclient.so" ]; then
fn_fix_msg_start
mkdir -pv "${HOME}/.steam/sdk64" >> "${lgsmlog}"
if [ -f "${HOME}/.steam/steamcmd/linux64/steamclient.so" ]; then
cp "${steamcmddir}/linux64/steamclient.so" "${HOME}/.steam/sdk64/steamclient.so" >> "${lgsmlog}"
cp "${HOME}/.steam/steamcmd/linux64/steamclient.so" "${HOME}/.steam/sdk64/steamclient.so" >> "${lgsmlog}"
elif [ -f "${steamcmddir}/linux64/steamclient.so" ]; then
cp "${steamcmddir}/linux64/steamclient.so" "${HOME}/.steam/sdk64/steamclient.so" >> "${lgsmlog}"
fi
@ -25,7 +25,7 @@ if [ ! -f "${HOME}/.steam/sdk32/steamclient.so" ]; then
fn_fix_msg_start
mkdir -pv "${HOME}/.steam/sdk32" >> "${lgsmlog}"
if [ -f "${HOME}/.steam/steamcmd/linux32/steamclient.so" ]; then
cp "${steamcmddir}/linux32/steamclient.so" "${HOME}/.steam/sdk32/steamclient.so" >> "${lgsmlog}"
cp "${HOME}/.steam/steamcmd/linux32/steamclient.so" "${HOME}/.steam/sdk32/steamclient.so" >> "${lgsmlog}"
elif [ -f "${steamcmddir}/linux32/steamclient.so" ]; then
cp "${steamcmddir}/linux32/steamclient.so" "${HOME}/.steam/sdk32/steamclient.so" >> "${lgsmlog}"
fi

16
lgsm/functions/fix_tu.sh

@ -6,12 +6,14 @@
functionselfname="$(basename "$(readlink -f "${BASH_SOURCE[0]}")")"
if [ "${shortname}" == "tu" ]; then
# Fixes: [S_API FAIL] SteamAPI_Init() failed; unable to locate a running instance of Steam, or a local steamclient.so.
if [ ! -f "${executabledir}/steamclient.so" ]; then
fixname="steamclient.so"
fn_fix_msg_start
cp -v "${serverfiles}/linux64/steamclient.so" "${executabledir}/steamclient.so" >> "${lgsmlog}"
fn_fix_msg_end
# Fixes: [S_API FAIL] SteamAPI_Init() failed; unable to locate a running instance of Steam, or a local steamclient.so.
if [ ! -f "${executabledir}/steamclient.so" ]; then
fixname="steamclient.so x86_64"
fn_fix_msg_start
if [ -f "${HOME}/.steam/steamcmd/linux64/steamclient.so" ]; then
cp "${HOME}/.steam/steamcmd/linux64/steamclient.so" "${executabledir}/steamclient.so" >> "${lgsmlog}"
elif [ -f "${steamcmddir}/linux64/steamclient.so" ]; then
cp "${steamcmddir}/linux64/steamclient.so" "${executabledir}/steamclient.so" >> "${lgsmlog}"
fi
fn_fix_msg_end
fi

10
lgsm/functions/fix_wurm.sh

@ -6,9 +6,15 @@
functionselfname="$(basename "$(readlink -f "${BASH_SOURCE[0]}")")"
# Copies steamclient.so to correct location.
if [ ! -f "${serverfiles}/nativelibs" ]; then
cp -f "${serverfiles}/linux64/steamclient.so" "${serverfiles}/nativelibs"
fixname="steamclient.so x86"
fn_fix_msg_start
if [ -f "${HOME}/.steam/steamcmd/linux32/steamclient.so" ]; then
cp "${HOME}/.steam/steamcmd/linux32/steamclient.so" "${serverfiles}/nativelibs" >> "${lgsmlog}"
elif [ -f "${steamcmddir}/linux32/steamclient.so" ]; then
cp "${steamcmddir}/linux32/steamclient.so" "${serverfiles}/nativelibs" >> "${lgsmlog}"
fi
fn_fix_msg_end
fi
# First run requires start with no parms.

Loading…
Cancel
Save