summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorEmilio Reggi2020-11-27 13:59:23 +0100
committerEmilio Reggi2020-11-27 13:59:23 +0100
commitc05f38c4c1378f02974e9628942a015a74ea2a9e (patch)
tree516f44263995eb254c579a83b11eb4618d37bb46
downloadaur-c05f38c4c1378f02974e9628942a015a74ea2a9e.tar.gz
Create PKGBUILD
-rw-r--r--.SRCINFO17
-rw-r--r--PKGBUILD31
2 files changed, 48 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO
new file mode 100644
index 000000000000..023c3f0ef89c
--- /dev/null
+++ b/.SRCINFO
@@ -0,0 +1,17 @@
+pkgbase = mastodonpp-git
+ pkgdesc = mastodonpp is a C++ wrapper for the Mastodon and Pleroma APIs. It replaces mastodon-cpp.
+ pkgver = r335.cf43022
+ pkgrel = 1
+ url = https://schlomp.space/tastytea/mastodonpp.git
+ arch = x86_64
+ license = GPL
+ makedepends = git
+ makedepends = cmake
+ depends = libcurl.so
+ optdepends = doxygen: documentation
+ optdepends = catch2: tests
+ source = mastodonpp::git+https://schlomp.space/tastytea/mastodonpp.git
+ md5sums = SKIP
+
+pkgname = mastodonpp-git
+
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 000000000000..727a4d5cfcdb
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,31 @@
+# Maintainer: Emilio Reggi <nag@mailbox.org>
+pkgname=mastodonpp-git
+_pkgname=mastodonpp
+pkgver=r335.cf43022
+pkgrel=1
+pkgdesc="mastodonpp is a C++ wrapper for the Mastodon and Pleroma APIs. It replaces mastodon-cpp."
+arch=('x86_64')
+url="https://schlomp.space/tastytea/mastodonpp.git"
+license=('GPL')
+groups=()
+depends=('libcurl.so')
+makedepends=('git' 'cmake')
+optdepends=('doxygen: documentation' 'catch2: tests')
+source=("${_pkgname}"::"git+https://schlomp.space/tastytea/mastodonpp.git")
+md5sums=('SKIP')
+
+pkgver() {
+ cd "$_pkgname"
+ printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"
+}
+
+build() {
+ # mkdir "${_pkgname}/build"
+ cmake -B "${_pkgname}/build" -S "${_pkgname}" -DCMAKE_INSTALL_PREFIX=/usr -Wno-dev
+ make -C "${_pkgname}/build"
+}
+
+package() {
+ make -C "${_pkgname}/build" DESTDIR="$pkgdir" install
+ install -D -m644 "${_pkgname}/LICENSE" -t "${pkgdir}/usr/share/licenses/${_pkgname}"
+}