From 160abc3c4638296ae624932de67ea5f050e4406a Mon Sep 17 00:00:00 2001 From: Puqns67 Date: Sun, 16 Jun 2024 18:18:37 +0800 Subject: [PATCH] prismlauncher-git: new package --- packages/prismlauncher-git/.SRCINFO | 47 +++++++++++++++++++++++ packages/prismlauncher-git/PKGBUILD | 59 +++++++++++++++++++++++++++++ 2 files changed, 106 insertions(+) create mode 100644 packages/prismlauncher-git/.SRCINFO create mode 100644 packages/prismlauncher-git/PKGBUILD diff --git a/packages/prismlauncher-git/.SRCINFO b/packages/prismlauncher-git/.SRCINFO new file mode 100644 index 0000000..f19a41a --- /dev/null +++ b/packages/prismlauncher-git/.SRCINFO @@ -0,0 +1,47 @@ +pkgbase = prismlauncher-git + pkgdesc = Minecraft launcher with ability to manage multiple instances. + pkgver = 8.0.r728.g978e96916 + pkgrel = 1 + url = https://prismlauncher.org/ + arch = x86_64 + arch = aarch64 + license = GPL-3.0-only + makedepends = cmake + makedepends = extra-cmake-modules + makedepends = gamemode + makedepends = ghc-filesystem + makedepends = git + makedepends = java-environment=17 + makedepends = ninja + makedepends = scdoc + depends = bzip2 + depends = cmark + depends = gcc-libs + depends = glibc + depends = hicolor-icon-theme + depends = libglvnd + depends = qt6-5compat + depends = qt6-base + depends = qt6-networkauth + depends = quazip-qt6 + depends = tomlplusplus + depends = zlib + optdepends = flite: for Minecraft text2speech support + optdepends = glfw: to use system GLFW libraries + optdepends = openal: to use system OpenAL libraries + optdepends = visualvm: Profiling support + optdepends = mangohud: run Minecraft with mangohud + optdepends = gamemode: run Minecraft with gamemode + optdepends = xorg-xrandr: for older Minecraft (<=1.12.2) + optdepends = java-runtime=8: for older Minecraft (<1.18 Pre-release 2) + optdepends = java-runtime=17: for Minecraft 1.18.0+ (>=1.18 Pre-release 2) + optdepends = java-runtime=21: for Minecraft 1.20.5+ (>=24w14a) + optdepends = qt6-wayland: for Wayland support + provides = prismlauncher + conflicts = prismlauncher + source = prismlauncher::git+https://github.com/PrismLauncher/PrismLauncher.git + source = libnbtplusplus::git+https://github.com/PrismLauncher/libnbtplusplus.git + b2sums = SKIP + b2sums = SKIP + +pkgname = prismlauncher-git diff --git a/packages/prismlauncher-git/PKGBUILD b/packages/prismlauncher-git/PKGBUILD new file mode 100644 index 0000000..cb45ae5 --- /dev/null +++ b/packages/prismlauncher-git/PKGBUILD @@ -0,0 +1,59 @@ +# Maintainer: Puqns67 + +_pkgname='prismlauncher' + +pkgname="${_pkgname}-git" +pkgver=8.0.r728.g978e96916 +pkgrel=1 +pkgdesc='Minecraft launcher with ability to manage multiple instances.' +arch=('x86_64' 'aarch64') +url='https://prismlauncher.org/' +license=('GPL-3.0-only') +depends=('bzip2' 'cmark' 'gcc-libs' 'glibc' 'hicolor-icon-theme' 'libglvnd' 'qt6-5compat' 'qt6-base' 'qt6-networkauth' 'quazip-qt6' 'tomlplusplus' 'zlib') +makedepends=('cmake' 'extra-cmake-modules' 'gamemode' 'ghc-filesystem' 'git' 'java-environment=17' 'ninja' 'scdoc') +optdepends=('flite: for Minecraft text2speech support' + 'glfw: to use system GLFW libraries' + 'openal: to use system OpenAL libraries' + 'visualvm: Profiling support' + 'mangohud: run Minecraft with mangohud' + 'gamemode: run Minecraft with gamemode' + 'xorg-xrandr: for older Minecraft (<=1.12.2)' + 'java-runtime=8: for older Minecraft (<1.18 Pre-release 2)' + 'java-runtime=17: for Minecraft 1.18.0+ (>=1.18 Pre-release 2)' + 'java-runtime=21: for Minecraft 1.20.5+ (>=24w14a)' + 'qt6-wayland: for Wayland support') +provides=("${_pkgname}") +conflicts=("${_pkgname}") + +source=("${_pkgname}"::"git+https://github.com/PrismLauncher/PrismLauncher.git" + "libnbtplusplus"::"git+https://github.com/PrismLauncher/libnbtplusplus.git") + +b2sums=('SKIP' + 'SKIP') + +pkgver() { + git -C "${srcdir}/${_pkgname}" describe --long --tags | sed 's/\([^-]*-g\)/r\1/;s/-/./g' +} + +prepare() { + rmdir -v "${srcdir}/${_pkgname}/libraries/libnbtplusplus" + ln -s "${srcdir}/libnbtplusplus" "${srcdir}/${_pkgname}/libraries/libnbtplusplus" + + cmake \ + -B "${srcdir}/build" \ + -D CMAKE_BUILD_TYPE=RelWithDebInfo \ + -D CMAKE_INSTALL_PREFIX='/usr' \ + -D BUILD_TESTING=OFF \ + -D ENABLE_LTO=ON \ + -D Launcher_BUILD_PLATFORM=archlinux \ + -G Ninja \ + -S "${srcdir}/${_pkgname}" +} + +build() { + cmake --build "${srcdir}/build" +} + +package() { + DESTDIR="${pkgdir}" cmake --install "${srcdir}/build" +}