summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorMark Wagie2024-02-20 18:20:21 -0700
committerMark Wagie2024-02-20 18:20:21 -0700
commit47c5fb282fb5c03622b484cf85b258dc27646bd1 (patch)
tree7cba2f690edb97d752bc05a3368bd23734826c54
downloadaur-47c5fb282fb5c03622b484cf85b258dc27646bd1.tar.gz
initial commit
-rw-r--r--.SRCINFO23
-rw-r--r--.gitignore7
-rw-r--r--PKGBUILD60
3 files changed, 90 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO
new file mode 100644
index 000000000000..121470521027
--- /dev/null
+++ b/.SRCINFO
@@ -0,0 +1,23 @@
+pkgbase = cosmic-notifications-git
+ pkgdesc = WIP Layer Shell notifications daemon which integrates with COSMIC.
+ pkgver = r61.19f147f
+ pkgrel = 1
+ url = https://github.com/pop-os/cosmic-notifications
+ arch = x86_64
+ arch = aarch64
+ groups = cosmic
+ license = GPL-3.0-or-later
+ makedepends = cargo
+ makedepends = git
+ makedepends = intltool
+ makedepends = just
+ makedepends = mold
+ depends = hicolor-icon-theme
+ depends = libxkbcommon
+ depends = wayland
+ provides = cosmic-notifications
+ conflicts = cosmic-notifications
+ source = git+https://github.com/pop-os/cosmic-notifications.git
+ sha256sums = SKIP
+
+pkgname = cosmic-notifications-git
diff --git a/.gitignore b/.gitignore
new file mode 100644
index 000000000000..4dab8d6386e3
--- /dev/null
+++ b/.gitignore
@@ -0,0 +1,7 @@
+# Ignore everything
+*
+
+# But not these files...
+!.gitignore
+!PKGBUILD
+!.SRCINFO
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 000000000000..f2b9f89958f6
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,60 @@
+# Maintainer: Mark Wagie <mark dot wagie at proton dot me>
+# Contributor: soloturn <soloturn@gmail.com>
+pkgname=cosmic-notifications-git
+pkgver=r61.19f147f
+pkgrel=1
+pkgdesc="WIP Layer Shell notifications daemon which integrates with COSMIC."
+arch=('x86_64' 'aarch64')
+url="https://github.com/pop-os/cosmic-notifications"
+license=('GPL-3.0-or-later')
+groups=('cosmic')
+depends=(
+ 'hicolor-icon-theme'
+ 'libxkbcommon'
+ 'wayland'
+)
+makedepends=(
+ 'cargo'
+ 'git'
+ 'intltool'
+ 'just'
+ 'mold'
+)
+checkdepends=()
+optdepends=()
+provides=("${pkgname%-git}")
+conflicts=("${pkgname%-git}")
+source=('git+https://github.com/pop-os/cosmic-notifications.git')
+sha256sums=('SKIP')
+
+pkgver() {
+ cd "${pkgname%-git}"
+ printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"
+}
+
+prepare() {
+ cd "${pkgname%-git}"
+
+ # Use mold linker instead of lld
+ sed -i 's/lld/mold/g' justfile
+
+ export CARGO_HOME="$srcdir/cargo-home"
+ export RUSTUP_TOOLCHAIN=stable
+ just vendor
+}
+
+build() {
+ cd "${pkgname%-git}"
+ # note, consider rust build time optimisations:
+ # https://matklad.github.io/2021/09/04/fast-rust-builds.html,
+ # later. for now, ignore warnings, and build with lower priority
+ # to not block user installing this pkg. to speed up build, use "mold" linker, see
+ # https://stackoverflow.com/questions/67511990/how-to-use-the-mold-linker-with-cargo
+ RUSTFLAGS="-A warnings -C link-arg=-fuse-ld=mold"
+ nice just build-vendored
+}
+
+package() {
+ cd "${pkgname%-git}"
+ just rootdir="$pkgdir" install
+}