summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorArkadiy Illarionov2022-04-02 17:27:23 +0300
committerArkadiy Illarionov2022-04-02 17:27:23 +0300
commit270bb8d2b6a6e58a138d720080071ef63d0d134c (patch)
tree96caa4c66b7c2cf6403ae7d187fb474e54e7edd1
parent504f67868c5e626ca8624d843d76f36c2484dd78 (diff)
downloadaur-270bb8d2b6a6e58a138d720080071ef63d0d134c.tar.gz
Release 2.0.1
Switch back to SourceForge releases. Use PEP-517 build and install.
-rw-r--r--.SRCINFO15
-rw-r--r--PKGBUILD48
-rw-r--r--b6fe038db.patch67
3 files changed, 97 insertions, 33 deletions
diff --git a/.SRCINFO b/.SRCINFO
index e77e611ac04c..a9bd93c83858 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,11 +1,12 @@
pkgbase = mcomix
pkgdesc = A user-friendly, customizable image viewer specifically designed to handle comic books
- pkgver = 1.3.0.dev0
- pkgrel = 6
- url = https://github.com/multiSnow/mcomix3
+ pkgver = 2.0.1
+ pkgrel = 1
+ url = https://sourceforge.net/p/mcomix/wiki/Home/
arch = any
license = GPL
- makedepends = git
+ makedepends = python-build
+ makedepends = python-installer
depends = gtk3
depends = python-cairo
depends = python-gobject
@@ -16,7 +17,9 @@ pkgbase = mcomix
optdepends = unzip: for zip compressed comics
optdepends = lhasa: for lha compressed comics
optdepends = mupdf-tools: for PDF comics
- source = git+https://github.com/multiSnow/mcomix3.git#commit=483f4b3f2d9a125606d47597ae7eff3b38e5bf9d
- md5sums = SKIP
+ source = https://downloads.sourceforge.net/project/mcomix/MComix-2.0.1/mcomix-2.0.1.tar.gz
+ source = b6fe038db.patch
+ md5sums = afa6e2ba9c843e82b346b21d316dbc15
+ md5sums = 6dab75dc1be41f522ce9271e1c3d62a2
pkgname = mcomix
diff --git a/PKGBUILD b/PKGBUILD
index a386c749e418..5087fecfe0e0 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -3,45 +3,39 @@
pkgname=mcomix
# Might want to move to date-based versions.
-pkgver=1.3.0.dev0
-pkgrel=6
+pkgver=2.0.1
+pkgrel=1
pkgdesc="A user-friendly, customizable image viewer specifically designed to handle comic books"
arch=('any')
-url="https://github.com/multiSnow/mcomix3"
+url="https://sourceforge.net/p/mcomix/wiki/Home/"
license=('GPL')
depends=('gtk3' 'python-cairo' 'python-gobject' 'python-pillow')
-makedepends=('git')
+makedepends=('python-build' 'python-installer')
optdepends=('libunrar: for rar compressed comics'
'p7zip: for 7z compressed comics'
'unrar: for rar compressed comics'
'unzip: for zip compressed comics'
'lhasa: for lha compressed comics'
'mupdf-tools: for PDF comics')
-_commit=483f4b3f2d9a125606d47597ae7eff3b38e5bf9d # HEAD as of 20220123.
-source=("git+https://github.com/multiSnow/mcomix3.git#commit=$_commit")
-md5sums=('SKIP')
+source=("https://downloads.sourceforge.net/project/${pkgname}/MComix-${pkgver}/${pkgname}-${pkgver}.tar.gz"
+ "b6fe038db.patch"
+)
+md5sums=('afa6e2ba9c843e82b346b21d316dbc15'
+ '6dab75dc1be41f522ce9271e1c3d62a2'
+)
-package() {
- cd mcomix3
-
- python installer.py --srcdir=mcomix --target="${pkgdir}"/usr/share
-
- install -dm755 "$pkgdir"/usr/bin
- ln -s /usr/share/mcomix/mcomixstarter.py "$pkgdir"/usr/bin/mcomix
- ln -s /usr/share/mcomix/comicthumb.py "$pkgdir"/usr/bin/comicthumb
+prepare() {
+ cd "${pkgname}-${pkgver}"
+ patch -p1 < ../b6fe038db.patch
+}
- install -Dm644 mime/mcomix.desktop "$pkgdir"/usr/share/applications/mcomix.desktop
- install -Dm644 mime/mcomix.appdata.xml "$pkgdir"/usr/share/metainfo/mcomix.appdata.xml
- install -Dm644 mime/comicthumb.thumbnailer "$pkgdir"/usr/share/thumbnailers/comicthumb.thumbnailer
+build(){
+ cd "${pkgname}-${pkgver}"
+ python -m build --wheel --no-isolation
+}
- for size in 16x16 22x22 24x24 32x32 48x48
- do
- install -dm755 "$pkgdir"/usr/share/icons/hicolor/$size/apps/
- install -Dm644 mcomix/mcomix/images/$size/mcomix.png "$pkgdir"/usr/share/icons/hicolor/$size/apps/mcomix.png
- install -Dm644 mime/icons/$size/application-x-cb7.png "$pkgdir"/usr/share/icons/hicolor/$size/mimetypes/application-x-cb7.png
- install -Dm644 mime/icons/$size/application-x-cbt.png "$pkgdir"/usr/share/icons/hicolor/$size/mimetypes/application-x-cbt.png
- done
+package() {
+ cd "${pkgname}-${pkgver}"
- install -Dm644 man/mcomix.1 "$pkgdir"/usr/share/man/man1/mcomix.1
- install -Dm644 man/comicthumb.1 "$pkgdir"/usr/share/man/man1/comicthumb.1
+ python -m installer --destdir="$pkgdir" dist/*.whl
}
diff --git a/b6fe038db.patch b/b6fe038db.patch
new file mode 100644
index 000000000000..736e2af124d7
--- /dev/null
+++ b/b6fe038db.patch
@@ -0,0 +1,67 @@
+commit b6fe038db5e9ee10b22b08f7c3203f66f378ce96
+Author: Oddegamra <oddegamra@users.sourceforge.net>
+Date: Sat Apr 2 15:17:28 2022 +0200
+
+ fix: Missing resource files after "setup.py install"
+
+diff --git a/MANIFEST.in b/MANIFEST.in
+index 90d97d2..935a30d 100644
+--- a/MANIFEST.in
++++ b/MANIFEST.in
+@@ -1,5 +1,5 @@
+ recursive-include mcomix/images *.png
+-recursive-include mcomix/messages *.po *.mo *.pot
++recursive-include mcomix/messages *.mo
+ recursive-include mime *.*
+ include mime/comicthumb mime/comicthumb.thumbnailer
+ include mcomix.1.gz ChangeLog COPYING mcomixstarter.py
+diff --git a/setup.py b/setup.py
+index 2967ef7..4144ce5 100755
+--- a/setup.py
++++ b/setup.py
+@@ -11,44 +11,16 @@ Example usage:
+ $ ./setup.py install --single-version-externally-managed --root /tmp/mcomix --prefix /usr
+ """
+
+-import os
+-import glob
+ import setuptools
+
+ from mcomix import constants
+
+
+-def get_data_patterns(directory, *patterns):
+- """ Build a list of patterns for all subdirectories of <directory>
+- to be passed into package_data. """
+-
+- olddir = os.getcwd()
+- os.chdir(os.path.join(constants.BASE_PATH, directory))
+- allfiles = []
+- for dirpath, _, _ in os.walk("."):
+- for pattern in patterns:
+- current_pattern = os.path.normpath(os.path.join(dirpath, pattern))
+- if glob.glob(current_pattern):
+- # Forward slashes only for distutils.
+- allfiles.append(current_pattern.replace('\\', '/'))
+- os.chdir(olddir)
+- return allfiles
+-
+-# Filter unnecessary image files. Replace wildcard pattern with actual files.
+-images = get_data_patterns('mcomix/images', '*.png')
+-images.remove('*.png')
+-images.extend([ os.path.basename(img)
+- for img in glob.glob(os.path.join(constants.BASE_PATH, 'mcomix/images', '*.png'))
+- if os.path.basename(img) not in
+- ('mcomix-large.png', )])
+-
+ setuptools.setup(
+ name = constants.APPNAME.lower(),
+ version = constants.VERSION,
+ packages = ['mcomix', 'mcomix.archive', 'mcomix.library'],
+- package_data = {
+- 'mcomix' : get_data_patterns('mcomix/messages', '*.mo') + images,
+- },
++ include_package_data=True,
+ entry_points = {
+ 'console_scripts' : [ 'mcomix = mcomix.run:run' ],
+ 'setuptools.installation': [ 'eggsecutable=mcomix.run:run' ],