summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorxiota2023-11-14 20:03:51 -0800
committerxiota2023-11-14 20:04:22 -0800
commitf10f8411928b3ee0dbb91f42f7fe6191e3b7ecb5 (patch)
tree73a5b97016ab5e82caed95de72170e35518e3904
parentd9ecd4f1edb1389d1d329c3d1c61419f92e8797c (diff)
downloadaur-f10f8411928b3ee0dbb91f42f7fe6191e3b7ecb5.tar.gz
r25806.24548b1f5
reorganize
-rwxr-xr-x.SRCINFO124
-rwxr-xr-xPKGBUILD404
2 files changed, 339 insertions, 189 deletions
diff --git a/.SRCINFO b/.SRCINFO
index 89c825d8f621..2ec58de14b1d 100755
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,80 +1,90 @@
pkgbase = yuzu-git
pkgdesc = An experimental open-source emulator for the Nintendo Switch
- pkgver = r24275.238e46ec9
+ pkgver = r25806.24548b1f5
pkgrel = 1
url = https://github.com/yuzu-emu/yuzu
arch = i686
arch = x86_64
license = GPL2
makedepends = boost
- makedepends = clang
+ makedepends = catch2
makedepends = cmake
makedepends = ffmpeg
+ makedepends = gcc
makedepends = git
+ makedepends = glslang
+ makedepends = llvm
+ makedepends = mold
makedepends = ninja
makedepends = nlohmann-json
+ makedepends = qt5-tools
+ makedepends = rapidjson
makedepends = robin-map
- makedepends = yasm
- depends = desktop-file-utils
+ makedepends = spirv-headers
+ makedepends = vulkan-headers
+ depends = boost-libs
+ depends = cubeb
+ depends = enet
depends = fmt
- depends = glslang
- depends = libfdk-aac
- depends = libusb
- depends = libxkbcommon-x11
- depends = lz4
+ depends = libinih
depends = mbedtls
- depends = openssl
- depends = opus
- depends = qt5-base
depends = qt5-multimedia
- depends = qt5-tools
- depends = qt5-wayland
depends = qt5-webengine
depends = sdl2
- depends = shared-mime-info
- depends = zlib
- depends = zstd
+ optdepends = qt5-wayland: Wayland support
provides = yuzu
conflicts = yuzu
- source = yuzu::git+https://github.com/yuzu-emu/yuzu
- source = git+https://github.com/lsalzman/enet.git
- source = git+https://github.com/benhoyt/inih.git
- source = git+https://github.com/mozilla/cubeb.git
- source = git+https://github.com/MerryMage/dynarmic.git
- source = git+https://github.com/libusb/libusb.git
- source = git+https://github.com/yuzu-emu/discord-rpc.git
- source = git+https://github.com/KhronosGroup/Vulkan-Headers.git
- source = git+https://github.com/yuzu-emu/sirit
- source = git+https://github.com/yuzu-emu/mbedtls
- source = git+https://github.com/herumi/xbyak.git
- source = git+https://github.com/xiph/opus.git
- source = git+https://git.ffmpeg.org/ffmpeg.git
- source = git+https://github.com/libsdl-org/SDL.git
- source = git+https://github.com/yhirose/cpp-httplib.git
- source = git+https://github.com/Microsoft/vcpkg.git
- source = git+https://github.com/arun11299/cpp-jwt.git
- source = git+https://github.com/arsenm/sanitizers-cmake.git
- source = git+https://github.com/google/googletest
- source = git+https://github.com/KhronosGroup/SPIRV-Headers.git
- md5sums = SKIP
- md5sums = SKIP
- md5sums = SKIP
- md5sums = SKIP
- md5sums = SKIP
- md5sums = SKIP
- md5sums = SKIP
- md5sums = SKIP
- md5sums = SKIP
- md5sums = SKIP
- md5sums = SKIP
- md5sums = SKIP
- md5sums = SKIP
- md5sums = SKIP
- md5sums = SKIP
- md5sums = SKIP
- md5sums = SKIP
- md5sums = SKIP
- md5sums = SKIP
- md5sums = SKIP
+ source = yuzu::git+https://github.com/yuzu-emu/yuzu.git
+ source = arun11299.cpp-jwt::git+https://github.com/arun11299/cpp-jwt.git
+ source = benhoyt.inih::git+https://github.com/benhoyt/inih.git
+ source = bylaws.libadrenotools::git+https://github.com/bylaws/libadrenotools.git
+ source = ffmpeg::git+https://github.com/FFmpeg/FFmpeg.git
+ source = gpuopen-librariesandsdks.vulkanmemoryallocator::git+https://github.com/GPUOpen-LibrariesAndSDKs/VulkanMemoryAllocator.git
+ source = herumi.xbyak::git+https://github.com/herumi/xbyak.git
+ source = khronosgroup.vulkan-headers::git+https://github.com/KhronosGroup/Vulkan-Headers.git
+ source = lat9nq.tzdb_to_nx::git+https://github.com/lat9nq/tzdb_to_nx.git
+ source = libsdl-org.sdl::git+https://github.com/libsdl-org/SDL.git
+ source = libusb::git+https://github.com/libusb/libusb.git
+ source = lsalzman.enet::git+https://github.com/lsalzman/enet.git
+ source = merryhime.dynarmic::git+https://github.com/merryhime/dynarmic.git
+ source = microsoft.vcpkg::git+https://github.com/microsoft/vcpkg.git
+ source = mozilla.cubeb::git+https://github.com/mozilla/cubeb.git
+ source = xiph.opus::git+https://github.com/xiph/opus.git
+ source = yhirose.cpp-httplib::git+https://github.com/yhirose/cpp-httplib.git
+ source = yuzu-emu.breakpad::git+https://github.com/yuzu-emu/breakpad.git
+ source = yuzu-emu.discord-rpc::git+https://github.com/yuzu-emu/discord-rpc.git
+ source = yuzu-emu.mbedtls::git+https://github.com/yuzu-emu/mbedtls.git
+ source = yuzu-emu.sirit::git+https://github.com/yuzu-emu/sirit.git
+ source = bylaws.liblinkernsbypass::git+https://github.com/bylaws/liblinkernsbypass.git
+ source = eggert.tz::git+https://github.com/eggert/tz.git
+ source = arsenm.sanitizers-cmake::git+https://github.com/arsenm/sanitizers-cmake.git
+ source = google.googletest::git+https://github.com/google/googletest.git
+ source = khronosgroup.spirv-headers::git+https://github.com/KhronosGroup/SPIRV-Headers.git
+ sha256sums = SKIP
+ sha256sums = SKIP
+ sha256sums = SKIP
+ sha256sums = SKIP
+ sha256sums = SKIP
+ sha256sums = SKIP
+ sha256sums = SKIP
+ sha256sums = SKIP
+ sha256sums = SKIP
+ sha256sums = SKIP
+ sha256sums = SKIP
+ sha256sums = SKIP
+ sha256sums = SKIP
+ sha256sums = SKIP
+ sha256sums = SKIP
+ sha256sums = SKIP
+ sha256sums = SKIP
+ sha256sums = SKIP
+ sha256sums = SKIP
+ sha256sums = SKIP
+ sha256sums = SKIP
+ sha256sums = SKIP
+ sha256sums = SKIP
+ sha256sums = SKIP
+ sha256sums = SKIP
+ sha256sums = SKIP
pkgname = yuzu-git
diff --git a/PKGBUILD b/PKGBUILD
index 6b32971c1b09..ca9a75214ae9 100755
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -1,151 +1,291 @@
-# Maintainer: Zion Nimchuk <zionnimchuk@gmail.com>
-# Co-maintainer: Brendan Szymanski <hello@bscubed.dev>
+# Maintainer:
+# Contributor: Zion Nimchuk <zionnimchuk@gmail.com>
+# Contributor: Brendan Szymanski <hello@bscubed.dev>
-_pkgname=yuzu
-pkgname=$_pkgname-git
-pkgver=r24275.238e46ec9
+# options
+: ${_pkgtype:=git}
+
+# basic info
+_pkgname="yuzu"
+pkgname="$_pkgname${_pkgtype:+-$_pkgtype}"
+pkgver=r25806.24548b1f5
pkgrel=1
pkgdesc='An experimental open-source emulator for the Nintendo Switch'
-arch=('i686' 'x86_64')
-url='https://github.com/yuzu-emu/yuzu'
+url="https://github.com/yuzu-emu/yuzu"
license=('GPL2')
-provides=('yuzu')
-conflicts=('yuzu')
-depends=('desktop-file-utils'
- 'fmt'
- 'glslang'
- 'libfdk-aac'
- 'libusb'
- 'libxkbcommon-x11'
- 'lz4'
- 'mbedtls'
- 'openssl'
- 'opus'
- 'qt5-base'
- 'qt5-multimedia'
- 'qt5-tools'
- 'qt5-wayland'
- 'qt5-webengine'
- 'sdl2'
- 'shared-mime-info'
- 'zlib'
- 'zstd')
-makedepends=('boost'
- 'clang'
- 'cmake'
- 'ffmpeg'
- 'git'
- 'ninja'
- 'nlohmann-json'
- 'robin-map'
- 'yasm')
-source=("$_pkgname::git+https://github.com/yuzu-emu/yuzu"
- 'git+https://github.com/lsalzman/enet.git'
- 'git+https://github.com/benhoyt/inih.git'
- 'git+https://github.com/mozilla/cubeb.git'
- 'git+https://github.com/MerryMage/dynarmic.git'
- 'git+https://github.com/libusb/libusb.git'
- 'git+https://github.com/yuzu-emu/discord-rpc.git'
- 'git+https://github.com/KhronosGroup/Vulkan-Headers.git'
- 'git+https://github.com/yuzu-emu/sirit'
- 'git+https://github.com/yuzu-emu/mbedtls'
- 'git+https://github.com/herumi/xbyak.git'
- 'git+https://github.com/xiph/opus.git'
- 'git+https://git.ffmpeg.org/ffmpeg.git'
- 'git+https://github.com/libsdl-org/SDL.git'
- 'git+https://github.com/yhirose/cpp-httplib.git'
- 'git+https://github.com/Microsoft/vcpkg.git'
- 'git+https://github.com/arun11299/cpp-jwt.git'
- # cubeb dependencies
- 'git+https://github.com/arsenm/sanitizers-cmake.git'
- 'git+https://github.com/google/googletest'
- # sirit dependencies
- 'git+https://github.com/KhronosGroup/SPIRV-Headers.git')
-md5sums=('SKIP'
- 'SKIP'
- 'SKIP'
- 'SKIP'
- 'SKIP'
- 'SKIP'
- 'SKIP'
- 'SKIP'
- 'SKIP'
- 'SKIP'
- 'SKIP'
- 'SKIP'
- 'SKIP'
- 'SKIP'
- 'SKIP'
- 'SKIP'
- 'SKIP'
- 'SKIP'
- 'SKIP'
- 'SKIP')
+arch=('i686' 'x86_64')
+
+# main package
+_main_package() {
+ depends=(
+ 'boost-libs'
+ 'cubeb'
+ 'enet'
+ 'fmt'
+ 'libinih'
+ 'mbedtls'
+ 'qt5-multimedia'
+ 'qt5-webengine'
+ 'sdl2'
+ )
+ makedepends=(
+ 'boost'
+ 'catch2'
+ 'cmake'
+ 'ffmpeg'
+ 'gcc'
+ 'git'
+ 'glslang'
+ 'llvm'
+ 'mold'
+ 'ninja'
+ 'nlohmann-json'
+ 'qt5-tools'
+ 'rapidjson'
+ 'robin-map'
+ 'spirv-headers'
+ 'vulkan-headers'
+ )
+ optdepends=(
+ "qt5-wayland: Wayland support"
+ )
+
+ provides=("$_pkgname")
+ conflicts=("$_pkgname")
+
+ _pkgsrc="$_pkgname"
+ source=("$_pkgsrc"::"git+$url.git")
+ sha256sums=('SKIP')
+
+ _source_yuzu
+ _source_bylaws_libadrenotools
+ _source_lat9nq_tzdb_to_nx
+ _source_mozilla_cubeb
+ _source_yuzu_emu_sirit
+}
+# submodules
+_source_yuzu() {
+ source+=(
+ 'arun11299.cpp-jwt'::'git+https://github.com/arun11299/cpp-jwt.git'
+ 'benhoyt.inih'::'git+https://github.com/benhoyt/inih.git'
+ 'bylaws.libadrenotools'::'git+https://github.com/bylaws/libadrenotools.git'
+ 'ffmpeg'::'git+https://github.com/FFmpeg/FFmpeg.git'
+ 'gpuopen-librariesandsdks.vulkanmemoryallocator'::'git+https://github.com/GPUOpen-LibrariesAndSDKs/VulkanMemoryAllocator.git'
+ 'herumi.xbyak'::'git+https://github.com/herumi/xbyak.git'
+ 'khronosgroup.vulkan-headers'::'git+https://github.com/KhronosGroup/Vulkan-Headers.git'
+ 'lat9nq.tzdb_to_nx'::'git+https://github.com/lat9nq/tzdb_to_nx.git'
+ 'libsdl-org.sdl'::'git+https://github.com/libsdl-org/SDL.git'
+ 'libusb'::'git+https://github.com/libusb/libusb.git'
+ 'lsalzman.enet'::'git+https://github.com/lsalzman/enet.git'
+ 'merryhime.dynarmic'::'git+https://github.com/merryhime/dynarmic.git'
+ 'microsoft.vcpkg'::'git+https://github.com/microsoft/vcpkg.git'
+ 'mozilla.cubeb'::'git+https://github.com/mozilla/cubeb.git'
+ 'xiph.opus'::'git+https://github.com/xiph/opus.git'
+ 'yhirose.cpp-httplib'::'git+https://github.com/yhirose/cpp-httplib.git'
+ 'yuzu-emu.breakpad'::'git+https://github.com/yuzu-emu/breakpad.git'
+ 'yuzu-emu.discord-rpc'::'git+https://github.com/yuzu-emu/discord-rpc.git'
+ 'yuzu-emu.mbedtls'::'git+https://github.com/yuzu-emu/mbedtls.git'
+ 'yuzu-emu.sirit'::'git+https://github.com/yuzu-emu/sirit.git'
+ )
+ sha256sums+=(
+ 'SKIP'
+ 'SKIP'
+ 'SKIP'
+ 'SKIP'
+ 'SKIP'
+ 'SKIP'
+ 'SKIP'
+ 'SKIP'
+ 'SKIP'
+ 'SKIP'
+ 'SKIP'
+ 'SKIP'
+ 'SKIP'
+ 'SKIP'
+ 'SKIP'
+ 'SKIP'
+ 'SKIP'
+ 'SKIP'
+ 'SKIP'
+ 'SKIP'
+ )
+
+ _prepare_yuzu() (
+ cd "${srcdir:?}/$_pkgsrc"
+ local -A _submodules=(
+ ['arun11299.cpp-jwt']='externals/cpp-jwt'
+ ['benhoyt.inih']='externals/inih/inih'
+ ['bylaws.libadrenotools']='externals/libadrenotools'
+ ['ffmpeg']='externals/ffmpeg/ffmpeg'
+ ['gpuopen-librariesandsdks.vulkanmemoryallocator']='externals/VulkanMemoryAllocator'
+ ['herumi.xbyak']='externals/xbyak'
+ ['khronosgroup.vulkan-headers']='externals/Vulkan-Headers'
+ ['lat9nq.tzdb_to_nx']='externals/nx_tzdb/tzdb_to_nx'
+ ['libsdl-org.sdl']='externals/SDL'
+ ['libusb']='externals/libusb/libusb'
+ ['lsalzman.enet']='externals/enet'
+ ['merryhime.dynarmic']='externals/dynarmic'
+ ['microsoft.vcpkg']='externals/vcpkg'
+ ['mozilla.cubeb']='externals/cubeb'
+ ['xiph.opus']='externals/opus'
+ ['yhirose.cpp-httplib']='externals/cpp-httplib'
+ ['yuzu-emu.breakpad']='externals/breakpad'
+ ['yuzu-emu.discord-rpc']='externals/discord-rpc'
+ ['yuzu-emu.mbedtls']='externals/mbedtls'
+ ['yuzu-emu.sirit']='externals/sirit'
+ )
+ _submodule_update
+ )
+}
+
+_source_bylaws_libadrenotools() {
+ source+=(
+ 'bylaws.liblinkernsbypass'::'git+https://github.com/bylaws/liblinkernsbypass.git'
+ )
+ sha256sums+=(
+ 'SKIP'
+ )
+
+ _prepare_bylaws_libadrenotools() (
+ cd "${srcdir:?}/$_pkgsrc"
+ cd "externals/libadrenotools"
+ local -A _submodules=(
+ ['bylaws.liblinkernsbypass']='lib/linkernsbypass'
+ )
+ _submodule_update
+ )
+}
+
+_source_lat9nq_tzdb_to_nx() {
+ source+=(
+ 'eggert.tz'::'git+https://github.com/eggert/tz.git'
+ )
+ sha256sums+=(
+ 'SKIP'
+ )
+
+ _prepare_lat9nq_tzdb_to_nx() (
+ cd "${srcdir:?}/$_pkgsrc"
+ cd "externals/nx_tzdb/tzdb_to_nx"
+ local -A _submodules=(
+ ['eggert.tz']='externals/tz/tz'
+ )
+ _submodule_update
+ )
+}
+
+_source_mozilla_cubeb() {
+ source+=(
+ 'arsenm.sanitizers-cmake'::'git+https://github.com/arsenm/sanitizers-cmake.git'
+ 'google.googletest'::'git+https://github.com/google/googletest.git'
+ )
+ sha256sums+=(
+ 'SKIP'
+ 'SKIP'
+ )
+
+ _prepare_mozilla_cubeb() (
+ cd "${srcdir:?}/$_pkgsrc"
+ cd "externals/cubeb"
+ local -A _submodules=(
+ ['arsenm.sanitizers-cmake']='cmake/sanitizers-cmake'
+ ['google.googletest']='googletest'
+ )
+ _submodule_update
+ )
+}
+
+_source_yuzu_emu_sirit() {
+ source+=(
+ 'khronosgroup.spirv-headers'::'git+https://github.com/KhronosGroup/SPIRV-Headers.git'
+ )
+ sha256sums+=(
+ 'SKIP'
+ )
+
+ _prepare_yuzu_emu_sirit() (
+ cd "${srcdir:?}/$_pkgsrc"
+ cd "externals/sirit"
+ local -A _submodules=(
+ ['khronosgroup.spirv-headers']='externals/SPIRV-Headers'
+ )
+ _submodule_update
+ )
+}
+
+# common functions
pkgver() {
- cd "$srcdir/$_pkgname"
- echo "r$(git rev-list --count HEAD).$(git rev-parse --short HEAD)"
+ cd "$_pkgsrc"
+ printf 'r%s.%s' \
+ "$(git rev-list --count HEAD)" \
+ "$(git rev-parse --short HEAD)"
}
prepare() {
- cd "$srcdir/$_pkgname"
-
- for submodule in {inih,cubeb,dynarmic,libusb,discord-rpc,Vulkan-Headers,sirit,mbedtls,xbyak,opus,ffmpeg,SDL,cpp-httplib,vcpkg,cpp-jwt,enet};
- do
- git config --file=.gitmodules submodule.$submodule.url "$srcdir/${submodule}"
+ _submodule_update() {
+ local key
+ for key in ${!_submodules[@]} ; do
+ git submodule init "${_submodules[${key}]}"
+ git submodule set-url "${_submodules[${key}]}" "${srcdir}/${key}"
+ git -c protocol.file.allow=always submodule update "${_submodules[${key}]}"
done
+ }
- git -c protocol.file.allow=always submodule update --init
+ _prepare_yuzu
- cd "$srcdir/$_pkgname"/externals/cubeb
-
- git config --file=.gitmodules submodule.cmake/sanitizers-cmake.url "$srcdir/sanitizers-cmake"
- git config --file=.gitmodules submodule.googletest.url "$srcdir/googletest"
- git -c protocol.file.allow=always submodule update --init
-
- cd "$srcdir/$_pkgname"/externals/sirit
-
- git config --file=.gitmodules submodule.externals/SPIRV-Headers.url "$srcdir/SPIRV-Headers"
- git -c protocol.file.allow=always submodule update --init
+ _prepare_bylaws_libadrenotools
+ _prepare_lat9nq_tzdb_to_nx
+ _prepare_mozilla_cubeb
+ _prepare_yuzu_emu_sirit
}
build() {
- cd "$srcdir/$_pkgname"
-
- if [[ -d build ]]; then
- rm -rf build
- fi
- mkdir -p build && cd build
- cmake .. -GNinja \
- -DCMAKE_INSTALL_PREFIX=/usr \
- -DCMAKE_C_COMPILER=clang \
- -DCMAKE_CXX_COMPILER=clang++ \
- -DCMAKE_BUILD_TYPE=Release \
- -DYUZU_USE_QT_WEB_ENGINE=ON \
- -DYUZU_USE_QT_MULTIMEDIA=ON \
- -DYUZU_USE_EXTERNAL_SDL2=OFF \
- -DUSE_DISCORD_PRESENCE=ON \
- -DENABLE_QT_TRANSLATION=ON \
- -DENABLE_COMPATIBILITY_LIST_DOWNLOAD=ON \
- -DBUILD_REPOSITORY=yuzu-emu/yuzu-mainline \
- -DBUILD_TAG=${pkgver} \
- -DTITLE_BAR_FORMAT_IDLE="yuzu | ${pkgver} {}" \
- -DTITLE_BAR_FORMAT_RUNNING="yuzu | ${pkgver} | {}" \
- -DDYNARMIC_NO_BUNDLED_ROBIN_MAP=ON \
- -DYUZU_USE_BUNDLED_OPUS=OFF \
- -DYUZU_USE_BUNDLED_FFMPEG=OFF \
- -DYUZU_USE_BUNDLED_LIBUSB=OFF \
- -DYUZU_USE_BUNDLED_QT=OFF \
- -DYUZU_TESTS=OFF
- ninja
-}
+ local _cmake_options=(
+ -S "$_pkgsrc"
+ -B build
+ -GNinja
+ -DCMAKE_INSTALL_PREFIX="/usr"
+ -DCMAKE_C_COMPILER="gcc"
+ -DCMAKE_CXX_COMPILER="g++"
+ -DCMAKE_C_FLAGS="$CFLAGS"
+ -DCMAKE_CXX_FLAGS="$CXXFLAGS"
+ -DCMAKE_BUILD_TYPE="Release"
+
+ -DYUZU_DOWNLOAD_TIME_ZONE_DATA=ON
+ -DYUZU_ENABLE_LTO=ON
+ -DYUZU_TESTS=OFF
+ -DYUZU_USE_BUNDLED_FFMPEG=OFF
+ -DYUZU_USE_BUNDLED_QT=OFF
+ -DYUZU_USE_FASTER_LD=OFF
+ -DYUZU_USE_EXTERNAL_SDL2=OFF
+ -DYUZU_USE_EXTERNAL_VULKAN_HEADERS=OFF
+ -DYUZU_USE_QT_MULTIMEDIA=ON
+ -DYUZU_USE_QT_WEB_ENGINE=ON
+ -DENABLE_QT6=OFF
+ -DENABLE_QT_TRANSLATION=ON
+ -DUSE_DISCORD_PRESENCE=ON
+ -DSIRIT_USE_SYSTEM_SPIRV_HEADERS=ON
+
+ -DBUILD_REPOSITORY=yuzu-emu/yuzu
+ -DBUILD_TAG="${pkgver}"
+ -DTITLE_BAR_FORMAT_IDLE="yuzu | ${pkgver} {}"
+ -DTITLE_BAR_FORMAT_RUNNING="yuzu | ${pkgver} | {}"
+ -Wno-dev
-#check() {
-# cd "$srcdir/$_pkgname/build"
-# ninja test
-#}
+ -DDYNARMIC_NO_BUNDLED_ROBIN_MAP=ON
+ -DENABLE_COMPATIBILITY_LIST_DOWNLOAD=ON
+ -DYUZU_USE_BUNDLED_LIBUSB=OFF
+ -DYUZU_USE_BUNDLED_OPUS=OFF
+ )
+
+ cmake "${_cmake_options[@]}"
+ cmake --build build
+}
package() {
- cd "$srcdir/$_pkgname/build"
- DESTDIR="$pkgdir" ninja install
+ DESTDIR="${pkgdir:?}" cmake --install build
}
+
+# execut
+_main_package