blob: 65a1dc645cae567bb1d896a7b8b46b49946b8ba2 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
|
# Maintainer: tocic <tocic at protonmail dot ch>
pkgname=duma-git
pkgver=2.5.24b1.r80.g0b9f76a
pkgrel=1
pkgdesc="Detect Unintended Memory Access (D.U.M.A.) -
A Red-Zone memory allocator"
arch=("x86_64")
url="https://github.com/johnsonjh/duma"
license=("GPL-2.0-only AND LGPL-2.1-only")
depends=("bash")
makedepends=("cmake" "git")
provides=("${pkgname%-git}")
conflicts=("${pkgname%-git}")
source=("${pkgname}::git+https://github.com/johnsonjh/duma#branch=master")
b2sums=("SKIP")
pkgver() {
printf "%s" \
$(git -C "${pkgname}" describe --long --tags \
| sed "s/^VERSION_//;s/_BETA_/b/;s/\([^-]*-g\)/r\1/;s/-/./g;s/_/./g")
}
build() {
# Intentionally disable the makepkg.conf options
# since the library requires a debug build
cmake -B "build/" -S "${pkgname}" \
-D BUILD_TESTS:BOOL="OFF" \
-D BUILD_EXAMPLES:BOOL="OFF" \
-D CMAKE_C_FLAGS:STRING="-fmacro-prefix-map=${srcdir}/=" \
-D CMAKE_CXX_FLAGS:STRING="-fmacro-prefix-map=${srcdir}/=" \
-D CMAKE_INSTALL_PREFIX:PATH="/usr/" \
-Wno-dev
cmake --build "build/"
}
package() {
DESTDIR="${pkgdir}" cmake --install "build/"
}
|