blob: a94820cba8b495b8cf57b1c934788861fb511a89 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
|
# Maintainer: HurricanePootis <hurricanepootis@protonmail.com>
pkgname=imgbrd-grabber
pkgver=7.13.0
pkgrel=1
pkgdesc="Very customizable imageboard/booru downloader with powerful filenaming features."
arch=('x86_64')
url="https://github.com/Bionus/imgbrd-grabber"
license=('Apache-2.0')
depends=('qt6-multimedia' 'qt6-declarative' 'nodejs' 'qt6-networkauth' 'hicolor-icon-theme' 'gcc-libs' 'glibc' 'qt6-base'
'qt6-webengine')
makedepends=('git' 'cmake' 'qt6-tools' 'npm' 'qt6-shadertools' 'jq' 'ninja')
optdepends=('openssl: Access HTTPS sources')
conflicts=("imgbrd-grabber-git" 'imgbrd-grabber-bin' 'imgbrd-grabber-appimage')
source=('git+https://github.com/Bionus/imgbrd-grabber.git#tag=v'${pkgver}''
'git+https://github.com/LaurentGomila/qt-android-cmake.git'
'git+https://github.com/sakra/cotire.git'
'git+https://github.com/lexbor/lexbor.git'
'git+https://github.com/catchorg/Catch2.git')
sha256sums=('175f41d63ec78f8d13c9584853ec511030a30ca41b25b9aefd000bf1cc937cf0'
'SKIP'
'SKIP'
'SKIP'
'SKIP')
prepare() {
cd "$srcdir/${pkgname}"
git submodule init
git config submodule.cmake/qt-android-cmake.url "$srcdir/qt-android-cmake"
git config submodule.cmake/cotire.url "$srcdir/cotire"
git config submodule.tests/src/vendor/catch.url "$srcdir/Catch2"
git config submodule.lib/vendor/lexbor.url "$srcdir/lexbor"
git -c protocol.file.allow=always submodule update
}
build() {
cd "$srcdir/${pkgname}/src/sites"
npm install --no-optional
cd "$srcdir"
cmake -S $pkgname/src -B build \
-G Ninja \
-DCMAKE_BUILD_TYPE=None \
-DCMAKE_INSTALL_PREFIX=/usr \
-DLEXBOR_BUILD_TESTS_CPP=0 \
-Wno-dev
cmake --build build
}
package() {
cd "$srcdir"
DESTDIR="$pkgdir/" cmake --install build && rm -rf "$pkgdir/usr/include" "$pkgdir/usr/lib"
cat >> "$pkgdir/usr/share/applications/org.bionus.Grabber.desktop" <<-EOF
StartupWMClass=cr.fr.bionus.Grabber
EOF
sed -i 's/Icon=grabber/Icon=org.bionus.Grabber.png/g' "$pkgdir/usr/share/applications/org.bionus.Grabber.desktop"
for size in {128,96,48};
do
cd "$pkgdir/usr/share/icons/hicolor/${size}x${size}/apps"
mv grabber.png org.bionus.Grabber.png
ln -s org.bionus.Grabber.png cr.fr.bionus.Grabber.png
done
touch "$pkgdir/usr/share/Grabber/settings.ini"
}
|