diff --git a/.gitignore b/.gitignore index c0f64a83..42f166ee 100644 --- a/.gitignore +++ b/.gitignore @@ -1,2 +1,3 @@ dist/ build/ +contrib/ diff --git a/build_proton.sh b/build_proton.sh index 9c054b21..f8eb6216 100755 --- a/build_proton.sh +++ b/build_proton.sh @@ -596,8 +596,23 @@ case "$BUILD_COMPONENTS" in *) echo "Invalid build components: $BUILD_COMPONENTS" ;; esac +function setup_wine_gecko +{ + mkdir -p "$DST_DIR"/share/wine/gecko/ + if [ -e "$TOP/../gecko/wine_gecko-$1-$2.msi" ]; then + cp "$TOP/../gecko/wine_gecko-$1-$2.msi" "$DST_DIR"/share/wine/gecko/ + else + mkdir -p contrib/ + if [ ! -e "contrib/wine_gecko-$1-$2.msi" ]; then + echo ">>>> Downloading wine-gecko. To avoid this in future, put it here: $TOP/../gecko/wine_gecko-$1-$2.msi" + wget -O "contrib/wine_gecko-$1-$2.msi" "https://dl.winehq.org/wine/wine-gecko/$1/wine_gecko-$1-$2.msi" + fi + cp "contrib/wine_gecko-$1-$2.msi" "$DST_DIR"/share/wine/gecko/ + fi +} + if [ "$PACKAGE" = true ]; then - echo "Packaging..." + echo ">>>> Packaging..." cd "$TOP" #create default prefix @@ -613,6 +628,9 @@ if [ "$PACKAGE" = true ]; then cp -a openvr/bin/win32/openvr_api.dll "$TOP"/build/dist/lib/wine/dxvk/openvr_api_dxvk.dll cp -a openvr/bin/win64/openvr_api.dll "$TOP"/build/dist/lib64/wine/dxvk/openvr_api_dxvk.dll + setup_wine_gecko "2.47" "x86" + setup_wine_gecko "2.47" "x86_64" + #the difference between -1 and -9 is about 20 MB, so prioritize quick startup over file size tar -C build/dist -c . | gzip -c -1 > dist/proton_dist.tar.gz