ppsspp-git/PKGBUILD

153 lines
4.8 KiB
Bash
Raw Normal View History

2015-06-08 02:11:15 -07:00
# Maintainer: Maxime Gauduin <alucryd@archlinux.org>
# Contributor: Bartłomiej Piotrowski <bpiotrowski@archlinux.org>
# Contributor: Ben Reedy <thebenj88@gmail.com>
# Contributor: Clement Guerin <geecko.dev@free.fr>
# Contributor: Thiago Kenji Okada <thiago.mast3r@gmail.com>
# Contributor: uberushaximus <uberushaximus@gmail.com>
pkgbase=ppsspp-git
2017-04-05 14:34:33 -07:00
pkgname=('ppsspp-git' 'ppsspp-headless-git' 'ppsspp-qt-git')
2018-08-28 05:42:12 -07:00
pkgver=1.6.3.r383.22a536fb0
2015-06-08 02:11:15 -07:00
pkgrel=1
pkgdesc='A PSP emulator written in C++'
2017-04-05 14:34:33 -07:00
arch=('x86_64')
2015-06-08 02:11:15 -07:00
url='http://www.ppsspp.org/'
license=('GPL2')
2017-04-05 14:34:33 -07:00
depends=('gcc-libs' 'glew' 'glibc' 'libgl' 'sdl2' 'zlib')
2018-06-18 06:03:18 -07:00
makedepends=('cmake' 'git' 'glu' 'libglvnd' 'libzip' 'qt5-tools')
2015-06-08 02:11:15 -07:00
source=('git+https://github.com/hrydgard/ppsspp.git'
2018-08-28 05:42:12 -07:00
'git+https://github.com/Kingcom/armips.git'
'git+https://github.com/discordapp/discord-rpc.git'
'ppsspp-ffmpeg::git+https://github.com/hrydgard/ppsspp-ffmpeg.git'
2017-04-04 11:57:43 -07:00
'ppsspp-glslang::git+https://github.com/hrydgard/glslang.git'
'git+https://github.com/hrydgard/ppsspp-lang.git'
2018-08-28 05:42:12 -07:00
'git+https://github.com/Tencent/rapidjson.git'
2017-04-04 11:57:43 -07:00
'git+https://github.com/KhronosGroup/SPIRV-Cross.git'
2018-08-28 05:42:12 -07:00
'armips-tinyformat::git+https://github.com/Kingcom/tinyformat.git'
2017-04-05 14:34:33 -07:00
'ppsspp.sh'
'ppsspp-headless.sh'
'ppsspp-qt.sh'
'ppsspp.desktop'
'ppsspp-qt.desktop'
'ppsspp-flags.patch')
2015-06-08 02:11:15 -07:00
sha256sums=('SKIP'
2016-12-11 13:42:14 -08:00
'SKIP'
2015-06-08 02:11:15 -07:00
'SKIP'
'SKIP'
'SKIP'
'SKIP'
2017-04-04 11:57:43 -07:00
'SKIP'
2018-08-28 05:42:12 -07:00
'SKIP'
'SKIP'
2017-05-19 16:31:05 -07:00
'2c2d1ee6d1ce5c2acec372d58b8079885f6d5d674633cfea489cd550252a5426'
'1236ce000bb670ee2c0e0645c3d55f4d8c8e74dbc35a1af0962a3bdd7608f1c5'
'828b06aacc56672a4d953d77342717c5be414a68261025f74e466abd084b8e6b'
2017-04-05 14:34:33 -07:00
'1c332702d0aeced07df7e12ba8530bc3f19a52bc76c355f6c84c141becfd46d8'
'b3b1fb9e0ecd3c4472b51f27d028a69514b1a3823c26e33da6ffaebfb1522b7f'
'6694643d96dae673f01555637139468eb277f3379afbcceccad3f7e0ae670278')
2015-06-08 02:11:15 -07:00
pkgver() {
cd ppsspp
echo "$(git describe --tags | sed 's/^v//; s/-/.r/; s/-g/./')"
}
prepare() {
cd ppsspp
2017-04-05 14:34:33 -07:00
patch -Np1 -i ../ppsspp-flags.patch
2017-04-04 11:57:43 -07:00
for submodule in ffmpeg assets/lang ext/glslang; do
2015-06-08 02:11:15 -07:00
git submodule init ${submodule}
git config submodule.${submodule}.url ../ppsspp-${submodule#*/}
git submodule update ${submodule}
done
2018-08-28 05:42:12 -07:00
for submodule in ext/{SPIRV-Cross,armips,discord-rpc,rapidjson}; do
2017-04-04 11:57:43 -07:00
git submodule init ${submodule}
git config submodule.${submodule}.url ../${submodule#*/}
git submodule update ${submodule}
done
2015-06-08 02:11:15 -07:00
pushd ext/armips
2017-04-04 11:57:43 -07:00
for submodule in ext/tinyformat; do
git submodule init ${submodule}
git config submodule.${submodule}.url ../../../armips-${submodule#*/}
git submodule update ${submodule}
done
popd
2015-09-07 00:26:32 -07:00
for ui in sdl qt; do
if [[ -d build-$ui ]]; then
rm -rf build-$ui
fi
mkdir build-$ui
done
2015-06-08 02:11:15 -07:00
}
build() {
2015-09-07 00:26:32 -07:00
cd ppsspp/build-sdl
2015-06-08 02:11:15 -07:00
cmake .. \
-DCMAKE_BUILD_TYPE='Release' \
2017-04-05 14:34:33 -07:00
-DCMAKE_SKIP_RPATH='ON' \
2018-02-11 13:34:44 -08:00
-DHEADLESS='ON' \
-DUSE_SYSTEM_LIBZIP='ON'
2015-06-08 02:11:15 -07:00
make
2015-09-07 00:26:32 -07:00
cd ../build-qt
2015-06-08 02:11:15 -07:00
2016-11-08 01:54:43 -08:00
cmake .. \
-DCMAKE_BUILD_TYPE='Release' \
-DCMAKE_SKIP_RPATH='ON' \
2018-02-11 13:34:44 -08:00
-DUSE_SYSTEM_LIBZIP='ON' \
2016-11-08 01:54:43 -08:00
-DUSING_QT_UI='ON'
2015-06-08 02:11:15 -07:00
make
}
package_ppsspp-git() {
2017-04-05 14:34:33 -07:00
depends+=('hicolor-icon-theme' 'libzip')
2015-06-08 02:11:15 -07:00
provides=('ppsspp')
conflicts=('ppsspp' 'ppsspp-qt' 'ppsspp-qt-git')
2015-09-07 00:26:32 -07:00
cd ppsspp/build-sdl
2015-06-08 02:11:15 -07:00
2017-04-05 14:34:33 -07:00
install -dm 755 "${pkgdir}"/{opt/ppsspp,usr/{bin,share/{applications,icons,pixmaps}}}
install -m 755 PPSSPPSDL "${pkgdir}"/opt/ppsspp/
cp -dr --no-preserve='ownership' assets "${pkgdir}"/opt/ppsspp/
2016-11-08 01:54:43 -08:00
cp -dr --no-preserve='ownership' ../icons/hicolor "${pkgdir}"/usr/share/icons/
install -m 644 ../icons/icon-512.svg "${pkgdir}"/usr/share/pixmaps/ppsspp.svg
2017-04-05 14:34:33 -07:00
install -m 755 ../../ppsspp.sh "${pkgdir}"/usr/bin/ppsspp
2015-09-26 02:35:47 -07:00
install -m 644 ../../ppsspp.desktop "${pkgdir}"/usr/share/applications/
2015-06-08 02:11:15 -07:00
}
2017-04-05 14:34:33 -07:00
package_ppsspp-headless-git() {
provides=('ppsspp-headless')
conflicts=('ppsspp-headless')
cd ppsspp/build-sdl
install -dm 755 "${pkgdir}"/{opt/ppsspp,usr/bin}
install -m 755 PPSSPPHeadless "${pkgdir}"/opt/ppsspp/
install -m 755 ../../ppsspp-headless.sh "${pkgdir}"/usr/bin/ppsspp-headless
}
2015-06-08 02:11:15 -07:00
package_ppsspp-qt-git() {
2017-04-05 14:34:33 -07:00
depends+=('hicolor-icon-theme' 'libzip' 'qt5-base')
provides=('ppsspp-qt')
2015-06-08 02:11:15 -07:00
conflicts=('ppsspp' 'ppsspp-git' 'ppsspp-qt')
cd ppsspp/build-qt
2017-04-05 14:34:33 -07:00
install -dm 755 "${pkgdir}"/{opt/ppsspp,usr/{bin,share/{applications,icons,pixmaps}}}
install -m 755 PPSSPPQt "${pkgdir}"/opt/ppsspp/
cp -dr --no-preserve='ownership' assets "${pkgdir}"/opt/ppsspp/
2016-11-08 01:54:43 -08:00
cp -dr --no-preserve='ownership' ../icons/hicolor "${pkgdir}"/usr/share/icons/
install -m 644 ../icons/icon-512.svg "${pkgdir}"/usr/share/pixmaps/ppsspp.svg
2017-04-05 14:34:33 -07:00
install -m 755 ../../ppsspp-qt.sh "${pkgdir}"/usr/bin/ppsspp-qt
install -m 644 ../../ppsspp-qt.desktop "${pkgdir}"/usr/share/applications/
2015-06-08 02:11:15 -07:00
}
# vim ts=2 sw=2 et: