sourcemod-smjansson

LOW
maintainer ChrisTX 0 votes scanned 2026-11-03 12:04:35.126831
View on AUR
Why flagged

The package builds a SourceMod extension from source hosted on GitHub, which is the project's legitimate repository; the only concern is low due to few votes and recent upload, but the build process is transparent and uses verifiable source code with proper checksums.

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.

Low AI review llm_review

An AI model (qwen/qwen3-235b-a22b-2507) reviewed this and agrees it is LOW (confidence 90%): The package builds a SourceMod extension from source hosted on GitHub, which is the project's legitimate repository; the only concern is low due to few votes and recent upload, but the build process is transparent and uses verifiable source code with proper checksums.

PKGBUILD

1# Maintainer: Christian Pfeiffer <cpfeiffer at rev-crew dot info>
2# shellcheck disable=SC2034,SC2154
3# shellcheck shell=bash
4
5pkgname=sourcemod-smjansson
6_name=SMJansson
7# SMJansson has no releases: its version (smsdk_config.h), the number of commits and the latest
8# commit, which fixes the build with current SourceMod
9_commit=b811b3341254fff6756d66fbc6c928ee6e701a32
10pkgver=2.6.0.1.r36.gb811b33
11pkgrel=1
12pkgdesc="SMJansson, a JSON extension of SourceMod (in the addons folder of sourcemod)"
13arch=(x86_64)
14url="https://github.com/davenonymous/SMJansson"
15# The extension's code says GPL 3.0 with SourceMod's exceptions; the repository has no licence file
16license=(GPL-3.0-only LicenseRef-SourceMod-exception)
17depends=(lib32-gcc-libs lib32-glibc lib32-jansson sourcemod)
18# The sources of the installed SourceMod, which it's built against
19makedepends=(ambuild clang python sourcemod-src)
20checkdepends=(sourcemod-scripting)
21# Where ./aur-packages commits reads the pins from: the commit pkgver names
22_pins_lookup() {
23 echo "_commit $(curl -fsSL "https://api.github.com/repos/davenonymous/SMJansson/commits/${pkgver##*.g}" | jq -r .sha)"
24}
25source=("$_name-$_commit.tar.gz::https://github.com/davenonymous/SMJansson/archive/$_commit.tar.gz"
26 smjansson-system-jansson.patch)
27sha512sums=('36e8b5db06dea90a205c3ad3266dd9d41ba19f5dba86be1e79506829432153245e3499bff7e97c74e6103a32bde949bf976059528f35e40b01f7ea8a082d1028'
28 '197ac4ed92556f931cca36fad74b005b2b1f5a8a06a7b414224352965ae91b7864f57beab9981e087597bda15ce51ddbaac63657755dc18cdb78583e7d4885fe')
29b2sums=('a5a6f5a53710c299caf381684d07a4f7a8eb6f92c8eaffcfd3d9dc84a76f87898b207abfd94586b61049a7d3b34c18bb93e7b28e684d5487641309584498bca4'
30 'a1c6dc75875581de11a91e2a9f1005f923af556b89fb622882e9e663e61d0a7ae1fe019cc4a86b9aeb491bfdebaaba259e972f22d120caadccb0431bef3fde36')
31
32prepare() {
33 cd "$srcdir/$_name-$_commit" || exit
34 # SourceMod's SDK manifests where the build script looks for them
35 ln -s /usr/src/sourcemod/hl2sdk-manifests hl2sdk-manifests
36
37 # The extension with the system's jansson and without SDKs (--sdks=), SourceMod's asm and
38 # libudis86 (not used); configure.py with Python 3.14's argparse, which checks the help texts;
39 # test.inc with the regex.inc it uses
40 patch -Np1 -i "$srcdir/smjansson-system-jansson.patch"
41 # Nothing prebuilt or bundled: the extension, the test plugin and jansson 2.6
42 rm -r bin pawn/plugins jansson
43}
44
45build() {
46 # Clang, like SourceMod's builds; position-independent code, which upstream only builds for
47 # x86_64, so the library has no text relocations
48 export CC=clang CXX=clang++
49 CFLAGS+=" -fPIC"
50
51 mkdir -p "$_name-$_commit/build"
52 cd "$_name-$_commit/build" || exit
53 # No SDK, as it's a plain extension. The build script requires the paths of Metamod:Source and a
54 # jansson source to be folders, but uses neither: jansson's headers are in /usr/include.
55 python ../configure.py --enable-optimize --targets=x86 --sdks= \
56 --sm-path=/usr/src/sourcemod --mms-path="$srcdir" --jansson-path=/usr/include
57 ambuild
58}
59
60check() {
61 # The test plugin compiles against the include file and SourceMod's
62 cd "$_name-$_commit/build/package/addons/sourcemod/scripting" || exit
63 spcomp64 -iinclude -o"$srcdir/smjansson.test.smx" smjansson.test.sp
64}
65
66package() {
67 # In the addons folder of sourcemod, as it uses no SDK: the extension, its include file and test
68 # plugin, as in upstream's package
69 install -d "$pkgdir/usr/lib/sourcemod"
70 cp -r --no-preserve=ownership "$srcdir/$_name-$_commit/build/package/addons" "$pkgdir/usr/lib/sourcemod/"
71
72 # SourceMod's licence and exceptions, which the extension's code refers to
73 install -Dm644 /usr/src/sourcemod/licenses/LICENSE.txt -t "$pkgdir/usr/share/licenses/$pkgname"
74}
75

Scan history

Scanned at (UTC)SeverityRules
2026-11-03 12:04:35 Low 2

Report a package

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

0 / 4000
Your suggestion