summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKuklin István Alexander2020-12-30 15:56:31 +0100
committerKuklin István Alexander2020-12-30 15:56:31 +0100
commitb6104299c7d3b9bbf5f03cb53dfcb1bead1b1df3 (patch)
tree0ed59871358bd9515347f78c87698d24a612bc56
parent00ed03223ce0b0079612ab04115815c535a9c487 (diff)
downloadpackages-b6104299c7d3b9bbf5f03cb53dfcb1bead1b1df3.tar.gz
packages-b6104299c7d3b9bbf5f03cb53dfcb1bead1b1df3.tar.bz2
packages-b6104299c7d3b9bbf5f03cb53dfcb1bead1b1df3.zip
2.1.38
-rw-r--r--.SRCINFO14
-rw-r--r--Dockerfile4
-rw-r--r--PKGBUILD26
-rw-r--r--docker.sudoers1
-rw-r--r--install_sh.patch21
-rw-r--r--prefix-fix.patch11
-rw-r--r--remove_xdg_cmds_from_makefile.patch20
7 files changed, 44 insertions, 53 deletions
diff --git a/.SRCINFO b/.SRCINFO
index 95034d6..8251d21 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,19 +1,19 @@
1pkgbase = anki-official-binary-bundle 1pkgbase = anki-official-binary-bundle
2 pkgdesc = The official binary shipped with the tested versions of the dependent libraries. 2 pkgdesc = The official binary shipped with the tested versions of the dependent libraries.
3 pkgver = 2.1.35 3 pkgver = 2.1.38
4 pkgrel = 1 4 pkgrel = 1
5 url = https://apps.ankiweb.net 5 url = https://apps.ankiweb.net
6 arch = x86_64 6 arch = x86_64
7 license = GNU AGPL 7 license = GNU AGPL
8 depends = libxkbcommon-x11
9 optdepends = mpv
8 provides = anki 10 provides = anki
9 conflicts = anki 11 conflicts = anki
10 conflicts = anki-git 12 conflicts = anki-git
11 source = https://apps.ankiweb.net/downloads/current/anki-2.1.35-linux-amd64.tar.bz2 13 source = https://github.com/ankitects/anki/releases/download/2.1.38/anki-2.1.38-linux.tar.bz2
12 source = remove_xdg_cmds_from_makefile.patch 14 source = install_sh.patch
13 source = prefix-fix.patch 15 md5sums = ab70980ca8b87a6f0fd67d05fc7a37d4
14 md5sums = d7ad8af7c1d9ddd92bb14d9d4a10ea7c 16 md5sums = 0ffca54471c2b5b2a300a68a93e135db
15 md5sums = 0eb542757f6b15d9904a53496627c76b
16 md5sums = 82a5d4f63bbc29e6a80043dd95973b4f
17 17
18pkgname = anki-official-binary-bundle 18pkgname = anki-official-binary-bundle
19 19
diff --git a/Dockerfile b/Dockerfile
index cd7479f..f2ac91e 100644
--- a/Dockerfile
+++ b/Dockerfile
@@ -1,4 +1,8 @@
1FROM archlinux 1FROM archlinux
2RUN pacman -Sy --noconfirm sudo fakeroot base-devel 2RUN pacman -Sy --noconfirm sudo fakeroot base-devel
3RUN pacman -S --noconfirm git 3RUN pacman -S --noconfirm git
4RUN pacman -S --noconfirm vim
5COPY docker.sudoers /etc/sudoers.d/wheel
4RUN useradd user 6RUN useradd user
7RUN usermod -a user -G wheel
8
diff --git a/PKGBUILD b/PKGBUILD
index ca6d7d1..1ed0341 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -5,7 +5,7 @@
5 5
6# Maintainer: Kuklin István <kuklinistvan@zoho.com> 6# Maintainer: Kuklin István <kuklinistvan@zoho.com>
7pkgname=anki-official-binary-bundle 7pkgname=anki-official-binary-bundle
8pkgver=2.1.35 8pkgver=2.1.38
9pkgrel=1 9pkgrel=1
10epoch= 10epoch=
11pkgdesc="The official binary shipped with the tested versions of the dependent libraries." 11pkgdesc="The official binary shipped with the tested versions of the dependent libraries."
@@ -13,10 +13,10 @@ arch=('x86_64')
13url="https://apps.ankiweb.net" 13url="https://apps.ankiweb.net"
14license=('GNU AGPL') 14license=('GNU AGPL')
15groups=() 15groups=()
16depends=() 16depends=('libxkbcommon-x11')
17makedepends=() 17makedepends=()
18checkdepends=() 18checkdepends=()
19optdepends=() 19optdepends=('mpv')
20provides=('anki') 20provides=('anki')
21conflicts=('anki' 'anki-git') 21conflicts=('anki' 'anki-git')
22replaces=() 22replaces=()
@@ -24,33 +24,29 @@ backup=()
24options=() 24options=()
25install= 25install=
26changelog= 26changelog=
27topdirname="anki-$pkgver-linux-amd64" 27topdirname="anki-$pkgver-linux"
28source=( 28source=(
29 "https://apps.ankiweb.net/downloads/current/${topdirname}.tar.bz2" 29 "https://github.com/ankitects/anki/releases/download/${pkgver}/${topdirname}.tar.bz2"
30 "remove_xdg_cmds_from_makefile.patch" 30 "install_sh.patch"
31 "prefix-fix.patch"
32) 31)
33noextract=() 32noextract=()
34md5sums=('d7ad8af7c1d9ddd92bb14d9d4a10ea7c' 33md5sums=('ab70980ca8b87a6f0fd67d05fc7a37d4'
35 '0eb542757f6b15d9904a53496627c76b' 34 '0ffca54471c2b5b2a300a68a93e135db')
36 '82a5d4f63bbc29e6a80043dd95973b4f')
37 35
38validpgpkeys=() 36validpgpkeys=()
39 37
40prepare() { 38prepare() {
41 cd "$srcdir" 39 cd "$srcdir"
42 ln -s "$topdirname" anki 40 ln -s "$topdirname" anki
43 patch -p1 -i remove_xdg_cmds_from_makefile.patch 41 patch -p0 -i install_sh.patch anki/install.sh
44 patch -p0 -i prefix-fix.patch
45 rm anki 42 rm anki
46} 43}
47 44
48build() { 45build() {
49 cd "$topdirname" 46 cd "$topdirname"
50 make
51} 47}
52 48
53package() { 49package() {
54 cd "$topdirname" 50 cd "$topdirname"
55 make PREFIX="$pkgdir"/usr/ install 51 PREFIX="$pkgdir"/usr/ ./install.sh
56} 52}
diff --git a/docker.sudoers b/docker.sudoers
new file mode 100644
index 0000000..7c499c2
--- /dev/null
+++ b/docker.sudoers
@@ -0,0 +1 @@
%wheel ALL=(ALL) NOPASSWD: ALL
diff --git a/install_sh.patch b/install_sh.patch
new file mode 100644
index 0000000..e436b84
--- /dev/null
+++ b/install_sh.patch
@@ -0,0 +1,21 @@
1--- install.sh.orig 2020-12-10 06:36:44.000000000 +0100
2+++ install.sh 2020-12-30 14:54:50.834734784 +0100
3@@ -10,7 +10,7 @@
4 mkdir -p ${PREFIX}/share/anki
5 cp -av * ${PREFIX}/share/anki/
6 mkdir -p ${PREFIX}/bin
7-ln -sf ${PREFIX}/share/anki/bin/Anki ${PREFIX}/bin/anki
8+ln -sf /usr/share/anki/bin/Anki ${PREFIX}/bin/anki
9 # fix a previous packaging issue where we created this as a file
10 (test -f ${PREFIX}/share/applications && rm ${PREFIX}/share/applications)||true
11 mkdir -p ${PREFIX}/share/pixmaps
12@@ -21,9 +21,4 @@
13 mv anki.desktop ${PREFIX}/share/applications/;\
14 mv anki.1 ${PREFIX}/share/man/man1/)
15
16-xdg-mime install anki.xml --novendor
17-xdg-mime default anki.desktop application/x-colpkg
18-xdg-mime default anki.desktop application/x-apkg
19-xdg-mime default anki.desktop application/x-ankiaddon
20-
21 echo "Install complete. Type 'anki' to run."
diff --git a/prefix-fix.patch b/prefix-fix.patch
deleted file mode 100644
index af7e059..0000000
--- a/prefix-fix.patch
+++ /dev/null
@@ -1,11 +0,0 @@
1--- anki/Makefile.orig
2+++ anki/Makefile
3@@ -10,7 +10,7 @@
4 mkdir -p ${PREFIX}/share/anki
5 cp -av * ${PREFIX}/share/anki/
6 mkdir -p ${PREFIX}/bin
7- ln -sf ${PREFIX}/share/anki/bin/anki ${PREFIX}/bin/
8+ ln -sf /usr/share/anki/bin/anki ${PREFIX}/bin/
9 # fix a previous packaging issue where we created this as a file
10 (test -f ${PREFIX}/share/applications && rm ${PREFIX}/share/applications)||true
11 mkdir -p ${PREFIX}/share/pixmaps
diff --git a/remove_xdg_cmds_from_makefile.patch b/remove_xdg_cmds_from_makefile.patch
deleted file mode 100644
index 8785e8b..0000000
--- a/remove_xdg_cmds_from_makefile.patch
+++ /dev/null
@@ -1,20 +0,0 @@
1diff --git a/anki/Makefile b/anki/Makefile
2index 9f10a3a..6a3539b 100644
3--- a/anki/Makefile
4+++ b/anki/Makefile
5@@ -20,15 +20,10 @@ install:
6 mv anki.xpm anki.png ${PREFIX}/share/pixmaps/;\
7 mv anki.desktop ${PREFIX}/share/applications/;\
8 mv anki.1 ${PREFIX}/share/man/man1/)
9- xdg-mime install anki.xml --novendor
10- xdg-mime default anki.desktop application/x-colpkg
11- xdg-mime default anki.desktop application/x-apkg
12- xdg-mime default anki.desktop application/x-ankiaddon
13 @echo
14 @echo "Install complete. Type 'anki' to run."
15
16 uninstall:
17- -xdg-mime uninstall ${PREFIX}/share/anki/anki.xml
18 rm -rf ${PREFIX}/share/anki
19 rm -rf ${PREFIX}/bin/anki
20 rm -rf ${PREFIX}/share/pixmaps/anki.xpm