summarylogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--.SRCINFO21
-rw-r--r--PKGBUILD56
-rw-r--r--codwaw.desktop8
-rw-r--r--codwaw.sh21
4 files changed, 106 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO
new file mode 100644
index 000000000000..a32bd3b041f1
--- /dev/null
+++ b/.SRCINFO
@@ -0,0 +1,21 @@
+pkgbase = codwaw-wine-steam
+ pkgdesc = Call of Duty: World at War using WINE with data via Steam
+ pkgver = 1.7
+ pkgrel = 1
+ url = https://store.steampowered.com/app/10090/Call_of_Duty_World_at_War/
+ arch = i686
+ arch = x86_64
+ license = custom
+ makedepends = steamcmd
+ makedepends = icoutils
+ depends = wine
+ source = codwaw.sh
+ source = codwaw.desktop
+ source = https://github.com/jm2/archlinux-package-codwaw-wine-steam/raw/master/CoDWaW.exe
+ source = https://github.com/jm2/archlinux-package-codwaw-wine-steam/raw/master/CoDWaWmp.exe
+ sha256sums = 84437aa7bf7baf82596c636d0a026933ee9197e67efd2887de59fb03c5aa8715
+ sha256sums = d3f8517b127a1cb03e991d963c40df17bbe6de57f5e8a662fbc6598e43e797db
+ sha256sums = f751d06799ed27f30c61d157ed292aa3adce73fbf9c30b92a5657b29624e8b31
+ sha256sums = b0e265592901cd248b7358e8b37c8c1b5c85c6b24fb3cb378f62d601378e4fae
+
+pkgname = codwaw-wine-steam
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 000000000000..900b6143f515
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,56 @@
+# Maintainer: John-Michael Mulesa <jmulesa [at] gmail.com>
+
+pkgname=codwaw-wine-steam
+_pkgname=codwaw
+pkgver=1.7
+pkgrel=1
+_steamid=10090
+arch=('i686' 'x86_64')
+makedepends=('steamcmd' 'icoutils')
+depends=('wine')
+source=("${_pkgname}.sh" "${_pkgname}.desktop"
+ "https://github.com/jm2/archlinux-package-codwaw-wine-steam/raw/master/CoDWaW.exe"
+ "https://github.com/jm2/archlinux-package-codwaw-wine-steam/raw/master/CoDWaWmp.exe")
+pkgdesc="Call of Duty: World at War using WINE with data via Steam"
+license=('custom')
+url='https://store.steampowered.com/app/10090/Call_of_Duty_World_at_War/'
+sha256sums=('84437aa7bf7baf82596c636d0a026933ee9197e67efd2887de59fb03c5aa8715'
+ 'd3f8517b127a1cb03e991d963c40df17bbe6de57f5e8a662fbc6598e43e797db'
+ 'f751d06799ed27f30c61d157ed292aa3adce73fbf9c30b92a5657b29624e8b31'
+ 'b0e265592901cd248b7358e8b37c8c1b5c85c6b24fb3cb378f62d601378e4fae')
+
+prepare() {
+ mkdir -p $srcdir/${_pkgname}
+
+ # Use steamcmd to get data.
+ printf "Enter your Steam username:"
+ read steam_username
+ steamcmd +@sSteamCmdForcePlatformType windows +@ShutdownOnFailedCommand 1 +force_install_dir $srcdir/${_pkgname} +login $steam_username "+app_update ${_steamid} validate" +quit
+ wrestool -x -t -14 -o . ${_pkgname}/CoDWaW.exe
+ icotool -x -o . *.ico
+}
+
+package() {
+ mkdir -p $pkgdir/opt/${_pkgname}
+
+ # Move required files to pkgdir
+ cp -r $srcdir/${_pkgname}/* $pkgdir/opt/${_pkgname}/
+ cp $srcdir/CoDWaW{,mp}.exe $pkgdir/opt/${_pkgname}/
+ rm -rf $pkgdir/opt/${_pkgname}/steamapps
+ rm $pkgdir/opt/${_pkgname}/*.vdf
+
+ # Required for player profiles.
+ chmod o+w $pkgdir/opt/${_pkgname}
+
+ # Install desktop file.
+ install -D -m 644 $srcdir/${_pkgname}.desktop \
+ $pkgdir/usr/share/applications/${_pkgname}.desktop
+
+ # Install icon file.
+ install -D -m 644 $srcdir/CoDWaW.exe_14_ID_ICON1_1024_5_256x256x24.png \
+ $pkgdir/usr/share/pixmaps/${_pkgname}.png
+
+ # Install bash startup script.
+ install -D -m 755 $srcdir/${_pkgname}.sh \
+ $pkgdir/usr/bin/${_pkgname}
+}
diff --git a/codwaw.desktop b/codwaw.desktop
new file mode 100644
index 000000000000..6171e3e1dc65
--- /dev/null
+++ b/codwaw.desktop
@@ -0,0 +1,8 @@
+[Desktop Entry]
+Name=Call of Duty: World at War
+Comment=Call of Duty: World at War WINE
+Exec=/usr/bin/codwaw
+Icon=codwaw
+Terminal=false
+Type=Application
+Categories=Application;Game;
diff --git a/codwaw.sh b/codwaw.sh
new file mode 100644
index 000000000000..5c89272cd7d5
--- /dev/null
+++ b/codwaw.sh
@@ -0,0 +1,21 @@
+#!/bin/bash
+export WINEPREFIX="$HOME"/.codwaw/wine
+if [ ! -d "$HOME"/.codwaw ] ; then
+ mkdir -p "$HOME"/.codwaw/wine
+ wineboot -u
+fi
+cd /opt/codwaw
+while getopts ":szmh" opt; do
+ case ${opt} in
+ s ) /usr/bin/wine CoDWaW.exe
+ ;;
+ z ) /usr/bin/wine CoDWaW.exe
+ ;;
+ m ) /usr/bin/wine CoDWaWmp.exe
+ ;;
+ h ) echo "Usage: codwaw [-z: zombies/singleplayer CoDWaW.exe (default)|-m: multiplayer CoDWaWmp.exe]"
+ ;;
+ esac
+ exit
+done
+/usr/bin/wine CoDWaW.exe