blob: 074e81b1ecefc78b5faff1f1c0efe68a668cd713 (
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
|
# Maintainer: fkzys <fkzys at proton dot me>
pkgname=subs2srs-mono-git
pkgver=29.7.r34.924196e
pkgrel=1
pkgdesc="Create Anki import files from movies and TV shows for language learning"
arch=('any')
url="https://github.com/fkzys/subs2srs-mono"
license=('GPL-3.0-or-later')
depends=('mono' 'ffmpeg' 'mp3gain' 'mkvtoolnix-cli')
optdepends=(
'anki: flashcard application'
'noto-fonts-cjk: display japanese characters'
)
makedepends=('git' 'p7zip' 'icoutils')
provides=('subs2srs-mono' 'subs2srs')
conflicts=('subs2srs-mono' 'subs2srs')
source=("${pkgname}::git+${url}.git")
sha256sums=('SKIP')
pkgver() {
cd "$pkgname"
printf '29.7.r%s.%s' "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"
}
build() {
cd "$pkgname"
make build
}
package() {
cd "$pkgname"
make DESTDIR="$pkgdir" install
# Icons from exe
cd subs2srs
7z -y e subs2srs.exe '3.ico' '4.ico' -r 1>/dev/null
icotool -x 3.ico 4.ico
install -Dm644 4_1_32x32x24.png \
"$pkgdir/usr/share/icons/hicolor/32x32/apps/subs2srs.png"
7z -y e 'Utils/SubsReTimer/SubsReTimer.exe' '*.ico' -r 1>/dev/null
icotool -x ./*.ico
install -Dm644 1_1_16x16x32.png \
"$pkgdir/usr/share/icons/hicolor/16x16/apps/subsretimer.png"
install -Dm644 2_1_32x32x32.png \
"$pkgdir/usr/share/icons/hicolor/32x32/apps/subsretimer.png"
install -Dm644 3_1_48x48x32.png \
"$pkgdir/usr/share/icons/hicolor/48x48/apps/subsretimer.png"
rm -f ./*.ico ./*.png
}
|