void-packages/srcpkgs/csound/template
Đoàn Trần Công Danh c987560802 srcpkgs/c*: convert patches to -Np1
```sh
git grep -l '^patch_args=-Np0' "srcpkgs/$1*/template" |
while read template; do
	for p in ${template%/template}/patches/*; do
		sed -i '
			\,^[+-][+-][+-] /dev/null,b
			/^[*-]\+ [0-9]\+\(,[0-9]\+\)\? [*-]\+$/b
			s,^[*][*][*] ,&a/,
			/^--- /{
				s,\(^--- \)\(./\)*,\1a/,
				s,[.][Oo][Rr][Ii][Gg]\([	/]\),\1,
				s/[.][Oo][Rr][Ii][Gg]$//
				s/[.]patched[.]\([^.]\)/.\1/
				h
			}
			/^+++ -/{
				g
				s/^--- a/+++ b/
				b
			}
			s,\(^+++ \)\(./\)*,\1b/,
		' "$p"
	done
	sed -i '/^patch_args=/d' $template
done
```
2021-06-20 13:17:29 +07:00

34 lines
1.1 KiB
Bash

# Template file for 'csound'
pkgname=csound
version=6.15.0
revision=2
build_style=cmake
configure_args="
-DLUA_MODULE_INSTALL_DIR=${XBPS_CROSS_BASE}/usr/lib/lua/5.1
-DDPD_MODULE_INSTALL_DIR=${XBPS_CROSS_BASE}/usr/lib/pd/extra
-DPORTAUDIO_V19=yes"
hostmakedepends="flex python"
makedepends="LuaJIT-devel boost-devel fltk-devel fluidsynth-devel libcurl-devel
libgomp-devel liblo-devel libsndfile-devel libstk-devel pd-devel portaudio-devel
portmidi-devel tk-devel"
depends="pd stk-data"
short_desc="Programming language for sound rendering and signal processing"
maintainer="Andrea Brancaleoni <abc@pompel.me>"
license="LGPL-2.1-or-later"
homepage="https://csound.com/"
distfiles="https://github.com/${pkgname}/${pkgname}/archive/${version}.tar.gz"
checksum=d47ed0fb70c752cb06ee2655ee9f010d8d1e369fc73d09d2ac2bc1b3060bf724
CFLAGS="-fcommon"
CXXFLAGS="-Wno-error -fcommon"
case $XBPS_TARGET_MACHINE in
*-musl) makedepends+=" libexecinfo-devel";;
esac
post_install() {
vinstall ${FILESDIR}/csound.sh 755 etc/profile.d
# Avoid conflict with libextractor
mv ${DESTDIR}/usr/bin/extract ${DESTDIR}/usr/bin/csextract
}