2023-01-15 18:43:53 +01:00
|
|
|
# Maintainer: 0xDEADCADE <$(base64 -d<<<MHhkZWFkY2FkZUBwcm90b25tYWlsLmNvbQ==)>
|
2023-01-16 19:34:11 +01:00
|
|
|
# shellcheck disable=SC2148,SC2034,SC2154
|
2020-12-09 05:09:45 +01:00
|
|
|
|
|
|
|
_pkgname=yuzu
|
|
|
|
pkgname=$_pkgname-early-access
|
2023-01-16 19:34:11 +01:00
|
|
|
_repo="pineappleEA/pineapple-src"
|
|
|
|
_releases_gh=$(curl https://api.github.com/repos/${_repo}/releases)
|
|
|
|
pkgver=$(echo "$_releases_gh" | jq -r .[0].tag_name | cut -d "-" -f 2)
|
2022-11-11 05:29:31 +01:00
|
|
|
pkgrel=1
|
2021-11-01 14:34:25 +01:00
|
|
|
pkgdesc="An experimental open-source Nintendo Switch emulator/debugger (early access version)"
|
2020-12-09 05:09:45 +01:00
|
|
|
arch=('i686' 'x86_64')
|
2021-01-01 05:37:03 +01:00
|
|
|
url="https://yuzu-emu.org/"
|
2020-12-09 05:09:45 +01:00
|
|
|
license=('GPL2')
|
2023-05-24 16:05:14 +02:00
|
|
|
depends=('boost-libs' 'shared-mime-info' 'hicolor-icon-theme' 'sdl2' 'qt5-base' 'qt5-multimedia' 'qt5-webengine' 'libxkbcommon-x11' 'ffmpeg' 'fmt' 'libzip' 'opus' 'libfdk-aac' 'lz4' 'mbedtls' 'openssl' 'zstd' 'enet' 'cubeb')
|
2023-01-16 19:34:11 +01:00
|
|
|
makedepends=('llvm' 'git' 'glslang' 'cmake' 'ninja' 'graphviz' 'doxygen' 'clang' 'boost' 'catch2' 'nlohmann-json' 'rapidjson' 'qt5-tools' 'desktop-file-utils' 'robin-map' 'jq')
|
2020-12-09 05:09:45 +01:00
|
|
|
optdepends=('qt5-wayland: for Wayland support')
|
2021-05-19 22:32:48 +02:00
|
|
|
provides=('yuzu')
|
|
|
|
conflicts=('yuzu')
|
2021-07-09 01:14:17 +02:00
|
|
|
source=("https://github.com/pineappleEA/pineapple-src/archive/EA-${pkgver}.tar.gz"
|
2023-01-16 19:34:11 +01:00
|
|
|
"https://github.com/pineappleEA/pineapple-src/releases/download/EA-${pkgver}/Windows-Yuzu-EA-${pkgver}.zip"
|
|
|
|
"https://raw.githubusercontent.com/pineappleEA/Pineapple-Linux/master/yuzu.xml")
|
|
|
|
sha256sums=('SKIP'
|
|
|
|
'SKIP'
|
2023-01-16 19:52:12 +01:00
|
|
|
'SKIP')
|
2020-12-09 05:09:45 +01:00
|
|
|
|
|
|
|
prepare() {
|
2023-01-16 19:34:11 +01:00
|
|
|
cd "$srcdir/yuzu-windows-msvc-early-access" || exit
|
2023-01-16 19:55:38 +01:00
|
|
|
tar -xvf ./*.tar.xz
|
2023-01-16 19:34:11 +01:00
|
|
|
cd "$(find ./ -name "*.tar.xz" | sed -e 's/.tar.xz//')" || exit
|
|
|
|
cp -R .git* "$srcdir/pineapple-src-EA-${pkgver}/"
|
2023-01-15 18:43:53 +01:00
|
|
|
|
2023-01-16 19:34:11 +01:00
|
|
|
cd "$srcdir/pineapple-src-EA-${pkgver}" || exit
|
2022-11-10 21:36:15 +01:00
|
|
|
for i in $(git config --file .gitmodules --get-regexp path | awk '{ print $2 }') ; do
|
|
|
|
rm -rf "$i"
|
|
|
|
done
|
2023-01-15 18:43:53 +01:00
|
|
|
git submodule update --init --recursive
|
2022-11-10 21:36:15 +01:00
|
|
|
|
2021-01-01 05:37:03 +01:00
|
|
|
find . -name "CMakeLists.txt" -exec sed -i 's/^.*-Werror$/-W/g' {} +
|
2021-05-19 22:32:48 +02:00
|
|
|
#find . -name "CMakeLists.txt" -exec sed -i 's/^.*-Werror=.*)$/ )/g' {} +
|
2021-01-01 05:37:03 +01:00
|
|
|
find . -name "CMakeLists.txt" -exec sed -i 's/^.*-Werror=.*$/ /g' {} +
|
|
|
|
find . -name "CMakeLists.txt" -exec sed -i 's/-Werror/-W/g' {} +
|
2022-08-04 06:29:12 +02:00
|
|
|
sed -i -e 's/--quiet //g' src/video_core/host_shaders/CMakeLists.txt
|
2023-01-16 19:34:11 +01:00
|
|
|
# shellcheck disable=SC2016
|
2022-08-04 06:29:12 +02:00
|
|
|
sed -i -e 's#${SPIRV_HEADER_FILE} ${SOURCE_FILE}#${SPIRV_HEADER_FILE} ${SOURCE_FILE} 2>/dev/null#g' src/video_core/host_shaders/CMakeLists.txt
|
2021-07-09 01:14:17 +02:00
|
|
|
sed -i -e '/Name=yuzu/ s/$/ Early Access/' dist/yuzu.desktop
|
|
|
|
sed -i -e '/yuzu %f/a StartupWMClass=yuzu' dist/yuzu.desktop
|
|
|
|
sed -i -e 's_^MimeType=.*_&application/x-nx-nsp;application/x-nx-xci;_' dist/yuzu.desktop
|
2022-09-28 14:39:53 +02:00
|
|
|
sed -i -e 's| (%2)||' src/yuzu/aboutdialog.ui
|
|
|
|
|
2023-01-16 19:34:11 +01:00
|
|
|
cp -f "$srcdir/yuzu.xml" "dist/yuzu.xml"
|
2020-12-09 05:09:45 +01:00
|
|
|
}
|
|
|
|
build() {
|
2023-01-16 19:34:11 +01:00
|
|
|
cd "$srcdir/pineapple-src-EA-${pkgver}" || exit
|
|
|
|
mkdir -p build && cd build || exit
|
2020-12-09 05:09:45 +01:00
|
|
|
cmake .. -GNinja \
|
2022-08-04 06:29:12 +02:00
|
|
|
-DCMAKE_CXX_COMPILER=clang++ \
|
|
|
|
-DCMAKE_C_COMPILER=clang \
|
2022-11-04 05:29:50 +01:00
|
|
|
-DCMAKE_C_FLAGS="$CFLAGS -flto=thin" \
|
|
|
|
-DCMAKE_CXX_FLAGS="$CXXFLAGS -flto=thin" \
|
|
|
|
-DCMAKE_INTERPROCEDURAL_OPTIMIZATION=ON \
|
2020-12-09 05:09:45 +01:00
|
|
|
-DTITLE_BAR_FORMAT_IDLE="yuzu Early Access $pkgver" \
|
|
|
|
-DTITLE_BAR_FORMAT_RUNNING="yuzu Early Access $pkgver | {3}" \
|
|
|
|
-DCMAKE_INSTALL_PREFIX=/usr \
|
|
|
|
-DCMAKE_BUILD_TYPE=Release \
|
|
|
|
-DYUZU_ENABLE_COMPATIBILITY_REPORTING=ON \
|
|
|
|
-DENABLE_COMPATIBILITY_LIST_DOWNLOAD=ON \
|
|
|
|
-DYUZU_USE_QT_WEB_ENGINE=ON \
|
2021-07-09 01:14:17 +02:00
|
|
|
-DUSE_DISCORD_PRESENCE=ON \
|
2021-12-10 21:28:08 +01:00
|
|
|
-DENABLE_QT_TRANSLATION=ON \
|
2022-05-19 06:32:03 +02:00
|
|
|
-DYUZU_USE_BUNDLED_OPUS=OFF \
|
2023-01-15 18:43:53 +01:00
|
|
|
-DDYNARMIC_NO_BUNDLED_FMT=ON \
|
|
|
|
-DDYNARMIC_NO_BUNDLED_ROBIN_MAP=ON \
|
2022-07-12 22:24:39 +02:00
|
|
|
-DYUZU_USE_BUNDLED_FFMPEG=OFF \
|
|
|
|
-DYUZU_USE_BUNDLED_LIBUSB=OFF \
|
|
|
|
-DYUZU_USE_BUNDLED_QT=OFF \
|
2023-01-15 18:43:53 +01:00
|
|
|
-DYUZU_USE_EXTERNAL_SDL2=OFF
|
|
|
|
|
2020-12-09 05:09:45 +01:00
|
|
|
ninja
|
|
|
|
}
|
|
|
|
|
|
|
|
package() {
|
2023-01-16 19:34:11 +01:00
|
|
|
cd "$srcdir/pineapple-src-EA-${pkgver}/build" || exit
|
2021-01-01 05:37:03 +01:00
|
|
|
DESTDIR="$pkgdir" ninja install
|
2022-11-10 21:36:15 +01:00
|
|
|
|
2023-01-16 19:34:11 +01:00
|
|
|
rm -rf "$pkgdir/usr/lib" "$pkgdir/usr/include"
|
2020-12-09 05:09:45 +01:00
|
|
|
}
|