From 83afe068247e5d2ac559c9fa1b58ee5ce56cf4f3 Mon Sep 17 00:00:00 2001 From: tocic Date: Sat, 4 Feb 2023 11:01:01 +0300 Subject: [PATCH] Add build files The warning "Package contains reference to $srcdir" is expected. See https://github.com/cschreib/snitch/issues/62. --- .SRCINFO | 14 ++++++++++++++ .gitignore | 6 ++++++ PKGBUILD | 26 ++++++++++++++++++++++++++ 3 files changed, 46 insertions(+) create mode 100644 .SRCINFO create mode 100644 .gitignore create mode 100644 PKGBUILD diff --git a/.SRCINFO b/.SRCINFO new file mode 100644 index 000000000000..76c64ddef43a --- /dev/null +++ b/.SRCINFO @@ -0,0 +1,14 @@ +pkgbase = snitch + pkgdesc = Lightweight C++20 testing framework + pkgver = 1.0.0 + pkgrel = 1 + url = https://github.com/cschreib/snitch + arch = x86_64 + license = Boost + makedepends = cmake + makedepends = python + depends = gcc-libs + source = snitch-1.0.0.tar.gz::https://github.com/cschreib/snitch/archive/v1.0.0.tar.gz + b2sums = 388dc536c87ed664c885b69290bc5e3d1cb18df2f9fccc8d7ea973f41cfd362d2a6a66685a907f67a5f7a039e50158e008d6bda0383894efe6eaa5a45a645aed + +pkgname = snitch diff --git a/.gitignore b/.gitignore new file mode 100644 index 000000000000..2f5661e0609c --- /dev/null +++ b/.gitignore @@ -0,0 +1,6 @@ +/** +!/**/ + +!/.gitignore +!/.SRCINFO +!/PKGBUILD diff --git a/PKGBUILD b/PKGBUILD new file mode 100644 index 000000000000..db34df376dbb --- /dev/null +++ b/PKGBUILD @@ -0,0 +1,26 @@ +# Maintainer: tocic + +pkgname=snitch +pkgver=1.0.0 +pkgrel=1 +pkgdesc="Lightweight C++20 testing framework" +arch=("x86_64") +url="https://github.com/cschreib/snitch" +license=("Boost") +depends=("gcc-libs") +makedepends=("cmake" "python") +source=("${pkgname}-${pkgver}.tar.gz::https://github.com/cschreib/snitch/archive/v${pkgver}.tar.gz") +b2sums=("388dc536c87ed664c885b69290bc5e3d1cb18df2f9fccc8d7ea973f41cfd362d2a6a66685a907f67a5f7a039e50158e008d6bda0383894efe6eaa5a45a645aed") + +build() { + cmake -B "build/" -S "${pkgname}-${pkgver}" \ + -D BUILD_SHARED_LIBS:BOOL="ON" \ + -D CMAKE_INSTALL_PREFIX:PATH="/usr/" \ + -Wno-dev + + cmake --build "build/" +} + +package() { + DESTDIR="${pkgdir}" cmake --install "build/" +}