void-packages/srcpkgs/imgbrd-grabber/template
Đoàn Trần Công Danh 986c0a7d5e srcpkgs/i*: 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 KiB
Bash

# Template file for 'imgbrd-grabber'
pkgname=imgbrd-grabber
version=7.1.1
revision=1
build_style=cmake
hostmakedepends="nodejs"
makedepends="qt5-declarative-devel qt5-multimedia-devel qt5-plugin-mysql
qt5-plugin-odbc qt5-plugin-pgsql qt5-plugin-sqlite qt5-plugin-tds
qt5-script-devel qt5-tools-devel"
short_desc="Powerful imageboard/booru downloader"
maintainer="SolitudeSF <solitudesf@protonmail.com>"
license="Apache-2.0"
homepage="https://bionus.github.io/imgbrd-grabber"
changelog="https://github.com/Bionus/imgbrd-grabber/releases"
distfiles="https://github.com/Bionus/imgbrd-grabber/archive/v${version}.tar.gz"
checksum=4ecb247f92fb4ba7c3245439bcd221e8c64dd037c1761065a663adb6b4571740
if [ "$CROSS_BUILD" ]; then
hostmakedepends+=" qt5-host-tools qt5-qmake"
fi
case "$XBPS_TARGET_MACHINE" in
i686*) broken="segfaults with node" ;;
esac
pre_configure() {
vsed -i 's|USE_QSCINTILLA 1|USE_QSCINTILLA 0|' gui/CMakeLists.txt
vsed -i 's|USE_BREAKPAD 1|USE_BREAKPAD 0|' gui/CMakeLists.txt
}
post_install() {
touch ${DESTDIR}/usr/share/Grabber/settings.ini
}