summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCarl Hetherington <cth@carlh.net>2025-11-06 22:24:12 +0100
committerCarl Hetherington <cth@carlh.net>2025-11-07 00:13:39 +0100
commitd75d0af984d9c14bfefca8f1bdbc215c3bf3a388 (patch)
tree7bef4fd52a421203453afdbd41e1f9840d2edd2b
parent30dcaea1373ac62fba050e02ce5b0c1085797a23 (diff)
Allow building of arch package.carl
-rw-r--r--cscript21
1 files changed, 15 insertions, 6 deletions
diff --git a/cscript b/cscript
index c3bbc08..fed7574 100644
--- a/cscript
+++ b/cscript
@@ -1,7 +1,16 @@
-def build(target, options):
- cmd = './waf configure --without-libsndfile --prefix=%s' % target.directory
- if target.platform == 'linux':
- cmd += ' --static'
- target.command(cmd)
- target.command('./waf build install')
+import os
+
+def build(target, options, for_package, version):
+ if for_package and target.platform == 'linux' and target.distro == 'arch':
+ target.command('git clone https://aur.archlinux.org/leqm-nrt.git')
+ os.chdir('leqm-nrt')
+ target.command('sed -i "s/commit=\${_commit}/branch=carl/" PKGBUILD')
+ target.command('makepkg --skipinteg')
+ target.command('sudo pacman --noconfirm -U leqm-nrt*.zst')
+ else:
+ cmd = './waf configure --without-libsndfile --prefix=%s' % target.directory
+ if target.platform == 'linux':
+ cmd += ' --static'
+ target.command(cmd)
+ target.command('./waf build install')