void-packages/srcpkgs/synergy/template
Đoàn Trần Công Danh 4b97cd2fb4 srcpkgs/s*: 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

35 lines
1.1 KiB
Bash

# Template file for 'synergy'
pkgname=synergy
version=1.13.0
revision=2
wrksrc="${pkgname}-core-${version}-stable"
build_style=cmake
configure_args="-DBUILD_TESTS=OFF -DSYNERGY_BUILD_LEGACY_GUI=ON"
hostmakedepends="unzip pkg-config qt5-qmake qt5-host-tools"
makedepends="avahi-compat-libs-devel libcurl-devel avahi-compat-libs-devel
libSM-devel libXext-devel libXrandr-devel libXtst-devel libXinerama-devel
qt5-devel qt5-tools-devel"
short_desc="Share a single mouse and keyboard between multiple computers"
maintainer="Orphaned <orphan@voidlinux.org>"
license="GPL-2.0-only"
homepage="http://synergy-foss.org/"
distfiles="https://github.com/symless/synergy-core/archive/v${version}-stable.tar.gz"
checksum=a57989dd2d3ae30657f2b95cba3cae112c189f9bbbc3d1b25b3874859afeb94d
post_install() {
vmkdir usr/share/examples/${pkgname}
install -m644 doc/synergy.conf.example* \
${DESTDIR}/usr/share/examples/${pkgname}
vsv synergys
vsv synergyc
}
synergy-gui_package() {
depends="desktop-file-utils ${sourcepkg}>=${version}_${revision}"
pkg_install() {
vmove usr/bin/synergy
vmove usr/share/icons
vmove usr/share/applications
}
}