bde-verify-git

LOW
maintainer damian101 0 votes scanned 2026-10-27 15:48:05.092314
View on AUR
Why flagged

Uploaded within the last 14 days with 2 or fewer community votes — little peer review so far.

Triggered rules

Low Few votes, recently uploaded zero_votes_recent

Uploaded within the last 14 days with 2 or fewer community votes — little peer review so far.

PKGBUILD

1# Maintainer: Damian Höster <damian.hoester@posteo.de>
2
3_pkgname=bde-verify
4pkgname=$_pkgname-git
5pkgver=1.5.1.r1208.a03bd7b
6pkgrel=1
7pkgdesc='Static analysis tool verifying adherence to BDE C++ coding standards'
8arch=(x86_64)
9url=https://bloomberg.github.io/bde_verify/
10license=(Apache-2.0)
11
12depends=(
13 aspell
14 clang21
15 gcc-libs
16 glibc
17 llvm21-libs
18 perl
19 which
20)
21
22makedepends=(
23 cmake
24 git
25 llvm21
26 ninja
27)
28
29optdepends=(
30 'aspell-en: English dictionary for spell checking'
31)
32
33provides=(
34 $_pkgname
35 bde_verify
36)
37conflicts=(
38 $_pkgname
39 bde_verify
40)
41
42source=($_pkgname::git+https://github.com/bloomberg/bde_verify.git)
43sha256sums=(SKIP)
44
45pkgver() {
46 local _ver _rev _hash
47 _ver=$(sed -n 's/^bde-verify (\([^)]*\)).*/\1/p' $_pkgname/debian/changelog 2>/dev/null | head -n1)
48 [[ -z $_ver ]] && _ver=1.5.1
49 _rev=$(git -C $_pkgname rev-list --count HEAD)
50 _hash=$(git -C $_pkgname rev-parse --short HEAD)
51 printf '%s.r%s.%s' "$_ver" "$_rev" "$_hash"
52}
53
54prepare() {
55 # On Arch Linux, Clang component libraries are packaged into the unified clang-cpp and LLVM shared libraries
56 sed -i \
57 -e /clangTooling/d \
58 -e /clangFrontendTool/d \
59 -e 's/clangFrontend/clang-cpp LLVM/' \
60 $_pkgname/CMakeLists.txt
61
62 # Ensure bde_verify_bin can locate LLVM 21 shared libraries at runtime
63 sed -i 's|\${CMAKE_INSTALL_PREFIX}/lib64|/usr/lib/llvm21/lib|' \
64 $_pkgname/CMakeLists.txt
65}
66
67build() {
68 export CFLAGS+=" -ffile-prefix-map=$srcdir=."
69 export CXXFLAGS+=" -ffile-prefix-map=$srcdir=."
70
71 if [[ -x /usr/lib/llvm21/bin/clang++ ]]; then
72 export CC=/usr/lib/llvm21/bin/clang
73 export CXX=/usr/lib/llvm21/bin/clang++
74 fi
75
76 local cmake_args=(
77 -S $_pkgname
78 -B build
79 -G Ninja
80 -D CMAKE_BUILD_TYPE=Release
81 -D CMAKE_INSTALL_PREFIX=/usr
82 -D Clang_DIR=/usr/lib/llvm21/lib/cmake/clang
83 -D LLVM_DIR=/usr/lib/llvm21/lib/cmake/llvm
84 -D CLANG_RESOURCE_DIR=/usr/lib/llvm21/lib/clang/21
85 )
86
87 cmake "${cmake_args[@]}"
88 cmake --build build
89}
90
91package() {
92 DESTDIR="$pkgdir" cmake --install build
93
94 # Provide configuration in standard /etc hierarchy while keeping compatibility symlink
95 if [[ -d "$pkgdir"/usr/etc/bde-verify ]]; then
96 install -dm755 "$pkgdir"/etc
97 mv "$pkgdir"/usr/etc/bde-verify "$pkgdir"/etc/
98 ln -s /etc/bde-verify "$pkgdir"/usr/etc/bde-verify
99 fi
100
101 # Relocate library files to /usr/lib if installed under /usr/lib64
102 if [[ -d "$pkgdir"/usr/lib64 ]]; then
103 install -dm755 "$pkgdir/usr/lib"
104 mv "$pkgdir"/usr/lib64/* "$pkgdir"/usr/lib/ 2>/dev/null || true
105 rmdir "$pkgdir"/usr/lib64 2>/dev/null || true
106 fi
107
108 install -Dm644 $_pkgname/LICENSE -t "$pkgdir"/usr/share/licenses/$pkgname
109 install -Dm644 $_pkgname/README.md -t "$pkgdir"/usr/share/doc/$pkgname
110}
111

Scan history

Scanned at (UTC)SeverityRules
2026-10-27 15:48:05 Low 1

Report a package

Reports go to the AURWatch maintainer (one person) and are read by hand. No login required.

0 / 4000
Your suggestion