upgpkg: aquamarine-git 0.8.0.r3.gc8282f4-1

upgpkg: hyprcursor-git 0.1.12.r1.g2fd3642-1

upgpkg: hyprgraphics-git 0.1.3.r0.g9d7f268-1

upstream release

upgpkg: hypridle-git 0.1.6.r1.g66d1815-1

upgpkg: hyprland-git 0.48.0.r62.gd775686-1

upgpkg: hyprland-meta-git 0.0.1-5

upgpkg: hyprland-protocols-git 0.6.4.r0.g3a5c2bd-1

upstream release

upgpkg: hyprland-qt-support-git 0.1.0.r8.g073c52b-1

upgpkg: hyprland-qtutils-git 0.1.3.r6.g3504a29-1

upgpkg: hyprland-welcome-git r19.51561c0-1

upgpkg: hyprlang-git 0.6.0.r10.g72df386-1

upgpkg: hyprlock-git 0.8.0.r1.g71d35aa-1

upgpkg: hyprpolkitagent-git 0.1.2.r3.g352638e-1

upgpkg: hyprsunset-git 0.2.0.r0.g7b7339f-1

upstream release

upgpkg: hyprsysteminfo-git 0.1.3.r2.g6769e50-1

upgpkg: hyprutils-git 0.6.0.r0.gf2dc70e-1

upstream release

upgpkg: hyprwayland-scanner-git 0.4.4.r2.g206367a-1

upgpkg: xdg-desktop-portal-hyprland-git 1.3.9.r4.g150b0b6-1

all PKGBUILDS now follow the same template
This commit is contained in:
alba4k 2025-04-10 21:45:54 +02:00
parent 2109a7abe4
commit b84d54a8d9
2 changed files with 53 additions and 26 deletions

View file

@ -1,23 +1,23 @@
pkgbase = hyprgraphics-git
pkgdesc = Hyprland graphics / resource utilities
pkgver = 0.1.0.r0.g4d927a52
pkgver = 0.1.3.r0.g9d7f268
pkgrel = 1
url = https://github.com/hyprwm/hyprgraphics
arch = x86_64
arch = aarch64
license = BSD-3-Clause
makedepends = git
makedepends = cmake
makedepends = gcc
depends = pixman
makedepends = git
makedepends = ninja
depends = cairo
depends = file
depends = hyprutils-git
depends = libjpeg
depends = libjxl
depends = libspng
depends = libwebp
depends = libjxl
depends = file
provides = hyprgraphics=0.1.0
depends = pixman
provides = hyprgraphics=0.1.3
provides = libhyprgraphics.so
conflicts = hyprgraphics
source = hyprgraphics::git+https://github.com/hyprwm/hyprgraphics.git

View file

@ -1,35 +1,62 @@
# Maintainer: alba4k <blaskoazzolaaaron@gmail.com>
_pkgname="hyprgraphics"
pkgname="${_pkgname}-git"
pkgver=0.1.0.r0.g4d927a52
_pkgsrc=$_pkgname
pkgname="$_pkgname-git"
pkgver=0.1.3.r0.g9d7f268
pkgrel=1
pkgdesc="Hyprland graphics / resource utilities"
arch=(x86_64 aarch64)
url="https://github.com/hyprwm/hyprgraphics"
arch=('x86_64' 'aarch64')
url="https://github.com/hyprwm/$_pkgname"
license=('BSD-3-Clause')
depends=('pixman' 'cairo' 'hyprutils-git' 'libjpeg' 'libspng' 'libwebp' 'libjxl' 'file')
makedepends=('git' 'cmake' 'gcc')
source=("${_pkgname}::git+https://github.com/hyprwm/hyprgraphics.git")
provides=("${_pkgname}=${pkgver%%.r*}" "lib$_pkgname.so")
conflicts=("hyprgraphics")
depends=(
cairo
file
hyprutils-git
libjpeg
libjxl
libspng
libwebp
pixman
)
makedepends=(
cmake
git
ninja
)
source=("$_pkgsrc::git+$url.git")
conflicts=("$_pkgname")
provides=("$_pkgname=${pkgver%%.r*}" "lib$_pkgname.so")
sha256sums=('SKIP')
: '
prepare() {
# Pick pull request form GitHub replacing NUM with the pr number
# e.g. git pull origin pull/111/head --no-edit --rebase
git pull origin pull/NUM/head --no-edit --rebase
}
'
pkgver() {
cd ${_pkgname}
git describe --long --tags --abbrev=8 --exclude='*[a-zA-Z][a-zA-Z]*' \
| sed -E 's/^[^0-9]*//;s/([^-]*-g)/r\1/;s/-/./g'
cd "$_pkgsrc"
git describe --long --tags --abbrev=7 | sed 's/^v//;s/\([^-]*-g\)/r\1/;s/-/./g'
}
build() {
cd "${srcdir}/${_pkgname}"
cmake --no-warn-unused-cli -DCMAKE_INSTALL_PREFIX=/usr -S . -B ./build
cmake --build ./build --config Release --target hyprgraphics
local cmake_options=(
-B build
-S "$_pkgsrc"
-G Ninja
-W no-dev
-D CMAKE_BUILD_TYPE=None
-D CMAKE_INSTALL_PREFIX=/usr
)
cmake "${cmake_options[@]}"
cmake --build build
}
package() {
cd "${srcdir}/${_pkgname}"
DESTDIR="${pkgdir}" cmake --install build
install -Dm644 LICENSE -t "${pkgdir}/usr/share/licenses/${pkgname}"
DESTDIR="$pkgdir" cmake --install build
install -Dm644 "$_pkgsrc/LICENSE" -t "$pkgdir/usr/share/licenses/$pkgname/"
}