diff --git a/bin/force-run-elf b/bin/force-run-elf index 8a4ce5d..19c613f 100755 --- a/bin/force-run-elf +++ b/bin/force-run-elf @@ -1,3 +1,6 @@ #!/bin/sh -/lib/ld-linux-x86-64.so.2 "$1" +# XXX: only works if .interp is numbered < 10 (readelf output is retarded to parse because of the [] with space padding) +INTERP=`readelf -SW "$1" | grep .interp | awk '{print "dd if='$1' of=/proc/self/fd/1 bs=1 count=$[0x" $7 "] skip=$[0x" $6 "]"}' | sh 2>/dev/null` + +exec "$INTERP" "$@" diff --git a/bin/prepare_steam b/bin/prepare_steam index c0da4ec..2c11e80 100755 --- a/bin/prepare_steam +++ b/bin/prepare_steam @@ -46,6 +46,10 @@ def main(argv): profile = config[args.platform] steamroot = os.path.expanduser(profile["steamroot"]) + + if profile.get("Enabled", "1") != "1": + print("Profile disabled in config") + return 0 # Read steam libraryfolders.vdf libsvdf = os.path.join(steamroot, "steamapps", "libraryfolders.vdf") @@ -109,10 +113,11 @@ def main(argv): with open(libsvdf, "w") as f: vdf.write(f, libs_config) - os.rename(steamvdf, steamvdf + ".bak") - with open(steamvdf, "w") as f: - vdf.write(f, steam_config) - + if profile.get("DontTouchConfigVdf", "0") != "1": + os.rename(steamvdf, steamvdf + ".bak") + with open(steamvdf, "w") as f: + vdf.write(f, steam_config) + return 0 diff --git a/bin/pulse-g930 b/bin/pulse-g930 deleted file mode 100755 index 58d39c8..0000000 --- a/bin/pulse-g930 +++ /dev/null @@ -1,6 +0,0 @@ -#!/bin/sh -echo "Setting up pulseaudio tunnels for the G930 Headset" -echo -n "G930 Sink Tunnel: " -pactl load-module module-tunnel-sink-new server=10.66.64.4 sink=alsa_output.usb-Logitech_Logitech_G930_Headset-00-Headset.analog-stereo sink_name=tunnel.arch.g930 sink_properties=\"device.description=\'G930 Headset\'\" -echo -n "G930 Source Tunnel: " -pactl load-module module-tunnel-source-new server=10.66.64.4 source=alsa_input.usb-Logitech_Logitech_G930_Headset-00-Headset.analog-mono source_name=tunnel.arch.g930 source_properties=\"device.description=\'G930 Headset\'\" diff --git a/etc/prepare_steam.vdf b/etc/prepare_steam.vdf index 6a6e166..627fa6e 100644 --- a/etc/prepare_steam.vdf +++ b/etc/prepare_steam.vdf @@ -26,6 +26,7 @@ "wine32" { "steamroot" "~/.local/share/wineprefixes/Steam32/drive_c/Program Files/Steam/" + "Enabled" "0" "Libraries" { "/media/Data/SteamLibrary" "E:\\SteamLibrary" @@ -35,4 +36,4 @@ { "0" "F:\\Steam\\Library" } -} \ No newline at end of file +}