[arch-commits] Commit in mcomix/repos (3 files)

Jakob Gruber schuay at nymeria.archlinux.org
Sun Sep 15 08:42:44 UTC 2013


    Date: Sunday, September 15, 2013 @ 10:42:44
  Author: schuay
Revision: 97190

archrelease: copy trunk to community-staging-x86_64

Added:
  mcomix/repos/community-staging-x86_64/
  mcomix/repos/community-staging-x86_64/PKGBUILD
    (from rev 97189, mcomix/trunk/PKGBUILD)
  mcomix/repos/community-staging-x86_64/mcomix.install
    (from rev 97189, mcomix/trunk/mcomix.install)

----------------+
 PKGBUILD       |   48 ++++++++++++++++++++++++++++++++++++++++++++++++
 mcomix.install |   30 ++++++++++++++++++++++++++++++
 2 files changed, 78 insertions(+)

Copied: mcomix/repos/community-staging-x86_64/PKGBUILD (from rev 97189, mcomix/trunk/PKGBUILD)
===================================================================
--- community-staging-x86_64/PKGBUILD	                        (rev 0)
+++ community-staging-x86_64/PKGBUILD	2013-09-15 08:42:44 UTC (rev 97190)
@@ -0,0 +1,48 @@
+# $Id$
+# Maintainer: schuay <jakob.gruber at gmail.com>
+# Contributor: Ray Powell <ray_al at xphoniexx.net>
+
+pkgname=mcomix
+pkgver=1.00
+pkgrel=5
+pkgdesc="A user-friendly, customizable image viewer specifically designed to handle comic books"
+arch=('any')
+url="http://sourceforge.net/projects/mcomix/"
+license=('GPL')
+depends=('pygtk' 'python2-pillow' 'xdg-utils' 'python2' \
+         'desktop-file-utils' 'hicolor-icon-theme' 'python2-setuptools')
+makedepends=('gettext' 'intltool')
+optdepends=('unrar: for rar compressed comics')
+conflicts=('comix')
+replaces=('comix')
+install='mcomix.install'
+source=("http://downloads.sourceforge.net/project/mcomix/MComix-${pkgver}/mcomix-${pkgver}.tar.bz2")
+
+build() {
+  cd ${srcdir}/${pkgname}-${pkgver}
+
+  # https://www.archlinux.org/todo/replace-pil-with-pillow/
+  sed -i 's/import Image/from PIL import Image/' mime/comicthumb
+
+  # python2 fix
+  for file in $(grep -Rl "/usr/bin/env python" .);
+  do
+    sed -i 's_#!/usr/bin/env python_#!/usr/bin/env python2_' $file
+  done
+}
+
+package() {
+  cd ${srcdir}/${pkgname}-${pkgver}
+
+  export PYTHONPATH=${pkgdir}/usr/lib/python2.7/site-packages/
+  mkdir -p $PYTHONPATH
+
+  python2 setup.py install --prefix=/usr --optimize=1 \
+    --single-version-externally-managed --root=${pkgdir}
+
+  install -Dm755 mime/comicthumb ${pkgdir}/usr/bin/comicthumb
+  install -Dm644 mime/comicthumb.1.gz ${pkgdir}/usr/share/man/man1/comicthumb.1.gz
+  install -Dm644 mime/comicbook.schemas ${pkgdir}/usr/share/gconf/schemas/mcomix.schemas
+}
+
+md5sums=('3a916dd9da17043ab59ccd17e26eb932')

Copied: mcomix/repos/community-staging-x86_64/mcomix.install (from rev 97189, mcomix/trunk/mcomix.install)
===================================================================
--- community-staging-x86_64/mcomix.install	                        (rev 0)
+++ community-staging-x86_64/mcomix.install	2013-09-15 08:42:44 UTC (rev 97190)
@@ -0,0 +1,30 @@
+pkgname=mcomix
+
+post_install() {
+  if [ -f usr/sbin/gconfpkg ]; then
+      usr/sbin/gconfpkg --install ${pkgname} &> /dev/null
+  fi
+  xdg-icon-resource forceupdate --theme hicolor &> /dev/null
+  update-desktop-database -q
+  update-mime-database usr/share/mime &> /dev/null
+}
+
+pre_upgrade() {
+  pre_remove $1
+}
+
+post_upgrade() {
+  post_install $1
+}
+
+pre_remove() {
+  if [ -f usr/sbin/gconfpkg ]; then
+      usr/sbin/gconfpkg --uninstall ${pkgname} &> /dev/null
+  fi
+}
+
+post_remove() {
+  xdg-icon-resource forceupdate --theme hicolor &> /dev/null
+  update-desktop-database -q
+  update-mime-database usr/share/mime &> /dev/null
+}




More information about the arch-commits mailing list