-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy path02_get_wine
executable file
·69 lines (58 loc) · 2.39 KB
/
02_get_wine
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
#!/bin/bash
cd "$(dirname "`readlink -f "$0"`")"
export SCRIPTS_PATH="$(pwd)"
fatal () {
echo "Fatal error!"
exit 1
}
if [[ $1 == tkg ]] ; then
version="$2"
if [[ -z $version ]] ; then
echo "Use: 02_get_wine tkg VESRION"
exit 0
fi
# git clone https://github.com/Kron4ek/wine-tkg "${SCRIPTS_PATH}/wine-tkg/"
wget https://github.com/Kron4ek/wine-tkg/archive/refs/tags/$version.tar.gz || fatal
tar -xf $version.tar.gz || fatal
rm -f $version.tar.gz || fatal
mv wine-tkg-$version wine-tkg || fatal
pushd "${SCRIPTS_PATH}/wine-tkg/" || fatal
echo -e "-----------------------------------------\nAdding 001-wine-tkg-to-lg patches:"
patch -Np1 < ../patches/001-wine-tkg-to-lg.patch || fatal
popd || fatal
elif [[ $1 == tkg-ntsync ]] ; then
git clone https://github.com/Kron4ek/wine-tkg wine -b ntsync
mv -f "${SCRIPTS_PATH}/wine" "${SCRIPTS_PATH}/wine-tkg-ntsync"
cp -fr "${SCRIPTS_PATH}/wine-tkg-ntsync" "${SCRIPTS_PATH}/wine-tkg-ntsync-bak"
pushd "${SCRIPTS_PATH}/wine-tkg-ntsync/" || fatal
echo -e "-----------------------------------------\nAdding 001-wine-tkg-to-lg patches:"
patch -Np1 < ../patches/001-wine-tkg-to-lg.patch || fatal
popd || fatal
elif [[ $1 == ge ]] ; then
if [[ ! -d "${SCRIPTS_PATH}/proton-ge" ]] ; then
version="$2"
if [[ -z $version ]] ; then
echo "Use: 02_get_wine ge VESRION (X-X)"
exit 0
fi
git clone --branch "GE-Proton$version" --recurse-submodules http://github.com/gloriouseggroll/proton-ge-custom || fatal
mv "${SCRIPTS_PATH}/proton-ge-custom/wine" "${SCRIPTS_PATH}/proton-ge" || fatal
pushd "${SCRIPTS_PATH}/proton-ge-custom" || fatal
git log -1 | grep GE-Proton | awk -F'GE-Proton' '{print $2}' > ${SCRIPTS_PATH}/proton-ge/GE_VER || fatal
popd || fatal
rm -fr "${SCRIPTS_PATH}/proton-ge-custom" || fatal
cd "${SCRIPTS_PATH}/proton-ge" || fatal
rm -f .git
git init
git add .
git commit -m "Commit before patches."
fi
cd "${SCRIPTS_PATH}/proton-ge" || fatal
echo -e "-----------------------------------------\nAdding De-steamify-proton-s-WINE_for_PortProton patches:\n"
patch -Np1 < ../patches/proton-ge-to-lg.patch
else
echo "Use: 02_get_wine < tkg | tkg-ntsync | ge >"
exit 0
fi
echo -e "\nDone\n"
# ${SCRIPTS_PATH}/03_build_wine_debian_multi.sh