diff options
author | Michał Masłowski <mtjm@mtjm.eu> | 2012-10-21 10:47:37 +0200 |
---|---|---|
committer | Michał Masłowski <mtjm@mtjm.eu> | 2012-10-21 10:47:37 +0200 |
commit | aec9ffe68488d34c02bceb4942b87779f5c460d5 (patch) | |
tree | 5aaa0d61510bf94c4dd5bd751b53f61d39817e96 /libre | |
parent | 59d570b2f4d752b3cd4dfcdf2ce8c75993d9c2eb (diff) | |
parent | 9598f5141ea75ffa72a3c7c85639c6f296020ef1 (diff) |
Merge branch 'master' of ssh://parabolagnulinux.org:1863/home/parabola/abslibre-pre-mips64el
Conflicts:
community-staging/projectm/PKGBUILD
community-testing/evas_generic_loaders-svn/PKGBUILD
community-testing/gambas2/PKGBUILD
community-testing/gambas3/PKGBUILD
community-testing/libextractor/PKGBUILD
community-testing/pdf2djvu/PKGBUILD
community-testing/qtcreator/PKGBUILD
community-testing/qtcreator/qtcreator.desktop
community/galculator/PKGBUILD
community/ristretto/PKGBUILD
core/systemd/PKGBUILD
extra/llvm/PKGBUILD
extra/pyqt/PKGBUILD
extra/python-lxml/PKGBUILD
multilib/lib32-util-linux/PKGBUILD
staging/glew/PKGBUILD
staging/xine-lib/PKGBUILD
testing/calligra/PKGBUILD
testing/gdk-pixbuf2/PKGBUILD
testing/gdm/PKGBUILD
testing/gdm/fix_external_program_directories.patch
testing/glib2/PKGBUILD
testing/gnome-color-manager/PKGBUILD
testing/gthumb/PKGBUILD
testing/gtk3/PKGBUILD
testing/gvfs/PKGBUILD
testing/inkscape/PKGBUILD
testing/kdebase-workspace/PKGBUILD
testing/libreoffice/PKGBUILD
testing/networkmanager/PKGBUILD
testing/polkit/PKGBUILD
testing/poppler/PKGBUILD
testing/rhythmbox/PKGBUILD
testing/xorg-server/PKGBUILD
testing/xorg-xdm/PKGBUILD
Diffstat (limited to 'libre')
-rwxr-xr-x | libre/python2-reportlab-libre/PKGBUILD | 49 | ||||
-rw-r--r-- | libre/python2-reportlab-libre/free-fonts.patch | 144 |
2 files changed, 193 insertions, 0 deletions
diff --git a/libre/python2-reportlab-libre/PKGBUILD b/libre/python2-reportlab-libre/PKGBUILD new file mode 100755 index 000000000..27014d100 --- /dev/null +++ b/libre/python2-reportlab-libre/PKGBUILD @@ -0,0 +1,49 @@ +# $Id: PKGBUILD 67753 2012-03-14 10:35:58Z giovanni $ +# Maintainer: +# Contributor: Angel 'angvp' Velasquez <angvp[at]archlinux.com.ve> +# Contributor: William Rea <sillywilly@gmail.com> +# Maintainer (Parabola): fauno <fauno@kiwwwi.com.ar> +# Contributor: borgo <nomail> +# Contributor (Parabola): André Silva <emulatorman@lavabit.com> + +pkgbase=python-reportlab-libre +pkgname=python2-reportlab-libre +_origname=reportlab +pkgver=2.6 +pkgrel=1 +pkgdesc="A proven industry-strength PDF generating solution (without non-free Adobe T1 fonts)" +arch=('i686' 'x86_64') +url="http://www.reportlab.org/rl_toolkit.html" +depends=('python2' 'freetype2' 'ttf-bitstream-vera' 'gsfonts' 'python-imaging') +conflicts=('python2-reportlab' 'python-reportlab<=2.5-2') +replaces=('python2-reportlab' 'python-reportlab<=2.5-2') +provides=("python2-reportlab=$pkgver") +license=('custom') +source=(http://www.reportlab.com/ftp/${_origname}-$pkgver.tar.gz + free-fonts.patch) +md5sums=('e5d27a24a2c8456b168913242aa1940f' + '1588b88851711cc6c868db4c7d4f4dea') +optdepends=('ghostscript') + +build() { + cd $srcdir/${_origname}-$pkgver + + # remove non-free Adobe T1 fonts + patch -p1 -i $srcdir/free-fonts.patch + + # Parabola contains those fonts from the ttf-bitstream-vera package + rm -f src/reportlab/fonts/{bitstream-vera-license.txt,Vera*} + + # python2 fix + for file in src/reportlab/graphics/widgets/table.py src/reportlab/lib/normalDate.py \ + src/reportlab/pdfgen/pycanvas.py; do + sed -i 's_#!.*/usr/bin/env python_#!/usr/bin/env python2_' $file + done +} + +package_python2-reportlab-libre() { + cd $srcdir/${_origname}-$pkgver + + python2 setup.py install --root=$pkgdir --optimize=1 + install -D -m644 LICENSE.txt $pkgdir/usr/share/licenses/$pkgname/license.txt +} diff --git a/libre/python2-reportlab-libre/free-fonts.patch b/libre/python2-reportlab-libre/free-fonts.patch new file mode 100644 index 000000000..b2683931b --- /dev/null +++ b/libre/python2-reportlab-libre/free-fonts.patch @@ -0,0 +1,144 @@ +diff -rupN reportlab-2.6.orig/setup.py reportlab-2.6/setup.py +--- reportlab-2.6.orig/setup.py 2012-09-27 13:14:06.000000000 -0300 ++++ reportlab-2.6/setup.py 2012-10-18 14:34:16.750336101 -0200 +@@ -222,11 +222,11 @@ def get_fonts(PACKAGE_DIR, reportlab_fil + infoline("Standard T1 font curves already downloaded") + return + try: +- infoline("Downloading standard T1 font curves") ++ #infoline("Downloading standard T1 font curves") + +- remotehandle = urllib2.urlopen("http://www.reportlab.com/ftp/pfbfer-20070710.zip") +- zipdata = StringIO.StringIO(remotehandle.read()) +- remotehandle.close() ++ #remotehandle = urllib2.urlopen("http://www.reportlab.com/ftp/pfbfer-20070710.zip") ++ #zipdata = StringIO.StringIO(remotehandle.read()) ++ #remotehandle.close() + archive = zipfile.ZipFile(zipdata) + dst = pjoin(rl_dir, 'fonts') + +@@ -239,7 +239,7 @@ def get_fonts(PACKAGE_DIR, reportlab_fil + except: + xitmsg = "Failed to download standard T1 font curves" + reportlab_files = [x for x in reportlab_files if os.path.isfile(pjoin(rl_dir,x))] +- infoline(xitmsg) ++ #infoline(xitmsg) + + def main(): + #test to see if we've a special command +diff -rupN reportlab-2.6.orig/src/reportlab/pdfbase/_fontdata.py reportlab-2.6/src/reportlab/pdfbase/_fontdata.py +--- reportlab-2.6.orig/src/reportlab/pdfbase/_fontdata.py 2012-09-27 11:39:39.000000000 -0300 ++++ reportlab-2.6/src/reportlab/pdfbase/_fontdata.py 2012-10-18 14:36:08.018365073 -0200 +@@ -72,20 +72,20 @@ _font2fnrMapWin32 = { + } + if sys.platform in ('linux2',): + _font2fnrMapLinux2 ={ +- 'symbol': 'Symbol', +- 'zapfdingbats': 'ZapfDingbats', +- 'helvetica': 'Arial', +- 'helvetica-bold': 'Arial-Bold', +- 'helvetica-boldoblique': 'Arial-BoldItalic', +- 'helvetica-oblique': 'Arial-Italic', +- 'times-bold': 'TimesNewRoman-Bold', +- 'times-bolditalic':'TimesNewRoman-BoldItalic', +- 'times-italic': 'TimesNewRoman-Italic', +- 'times-roman': 'TimesNewRoman', +- 'courier-bold': 'Courier-Bold', +- 'courier-boldoblique': 'Courier-BoldOblique', +- 'courier': 'Courier', +- 'courier-oblique': 'Courier-Oblique', ++ 'symbol': 's050000l.pfb', ++ 'zapfdingbats': 'd050000l.pfb', ++ 'helvetica': 'n019003l.pfb', ++ 'helvetica-bold': 'n019004l.pfb', ++ 'helvetica-boldoblique': 'n019024l.pfb', ++ 'helvetica-oblique': 'n019023l.pfb', ++ 'times-bold': 'n021004l.pfb', ++ 'times-bolditalic':'n021024l.pfb', ++ 'times-italic': 'n021023l.pfb', ++ 'times-roman': 'n021003l.pfb', ++ 'courier-bold': 'n022004l.pfb', ++ 'courier-boldoblique': 'n022024l.pfb', ++ 'courier': 'n022003l.pfb', ++ 'courier-oblique': 'n022023l.pfb', + } + _font2fnrMap = _font2fnrMapLinux2 + for k, v in _font2fnrMap.items(): +diff -rupN reportlab-2.6.orig/src/reportlab/rl_config.py reportlab-2.6/src/reportlab/rl_config.py +--- reportlab-2.6.orig/src/reportlab/rl_config.py 2012-09-27 11:39:39.000000000 -0300 ++++ reportlab-2.6/src/reportlab/rl_config.py 2012-10-18 16:05:12.683766581 -0200 +@@ -49,25 +49,7 @@ ttfAsciiReadable= 1 + + # places to look for T1Font information + T1SearchPath = ( +- 'c:/Program Files/Adobe/Acrobat 9.0/Resource/Font', +- 'c:/Program Files/Adobe/Acrobat 8.0/Resource/Font', +- 'c:/Program Files/Adobe/Acrobat 7.0/Resource/Font', +- 'c:/Program Files/Adobe/Acrobat 6.0/Resource/Font', #Win32, Acrobat 6 +- 'c:/Program Files/Adobe/Acrobat 5.0/Resource/Font', #Win32, Acrobat 5 +- 'c:/Program Files/Adobe/Acrobat 4.0/Resource/Font', #Win32, Acrobat 4 +- '%(disk)s/Applications/Python %(sys_version)s/reportlab/fonts', #Mac? +- '/usr/lib/Acrobat9/Resource/Font', #Linux, Acrobat 5? +- '/usr/lib/Acrobat8/Resource/Font', #Linux, Acrobat 5? +- '/usr/lib/Acrobat7/Resource/Font', #Linux, Acrobat 5? +- '/usr/lib/Acrobat6/Resource/Font', #Linux, Acrobat 5? +- '/usr/lib/Acrobat5/Resource/Font', #Linux, Acrobat 5? +- '/usr/lib/Acrobat4/Resource/Font', #Linux, Acrobat 4 +- '/usr/local/Acrobat9/Resource/Font', #Linux, Acrobat 5? +- '/usr/local/Acrobat8/Resource/Font', #Linux, Acrobat 5? +- '/usr/local/Acrobat7/Resource/Font', #Linux, Acrobat 5? +- '/usr/local/Acrobat6/Resource/Font', #Linux, Acrobat 5? +- '/usr/local/Acrobat5/Resource/Font', #Linux, Acrobat 5? +- '/usr/local/Acrobat4/Resource/Font', #Linux, Acrobat 4 ++ '/usr/share/fonts/Type1', + '%(REPORTLAB_DIR)s/fonts', #special + '%(REPORTLAB_DIR)s/../fonts', #special + '%(REPORTLAB_DIR)s/../../fonts', #special +@@ -76,44 +58,17 @@ T1SearchPath = ( + + # places to look for TT Font information + TTFSearchPath = ( +- 'c:/winnt/fonts', +- 'c:/windows/fonts', +- '/usr/lib/X11/fonts/TrueType/', +- '/usr/share/fonts/truetype', ++ '/usr/share/fonts/TTF', + '%(REPORTLAB_DIR)s/fonts', #special + '%(REPORTLAB_DIR)s/../fonts', #special + '%(REPORTLAB_DIR)s/../../fonts',#special + '%(HOME)s/fonts', #special +- #mac os X - from +- #http://developer.apple.com/technotes/tn/tn2024.html +- '~/Library/Fonts', +- '/Library/Fonts', +- '/Network/Library/Fonts', +- '/System/Library/Fonts', +- + ) + + # places to look for CMap files - should ideally merge with above + CMapSearchPath = ( +- '/usr/lib/Acrobat9/Resource/CMap', +- '/usr/lib/Acrobat8/Resource/CMap', +- '/usr/lib/Acrobat7/Resource/CMap', +- '/usr/lib/Acrobat6/Resource/CMap', +- '/usr/lib/Acrobat5/Resource/CMap', +- '/usr/lib/Acrobat4/Resource/CMap', +- '/usr/local/Acrobat9/Resource/CMap', +- '/usr/local/Acrobat8/Resource/CMap', +- '/usr/local/Acrobat7/Resource/CMap', +- '/usr/local/Acrobat6/Resource/CMap', +- '/usr/local/Acrobat5/Resource/CMap', +- '/usr/local/Acrobat4/Resource/CMap', +- 'C:\\Program Files\\Adobe\\Acrobat\\Resource\\CMap', +- 'C:\\Program Files\\Adobe\\Acrobat 9.0\\Resource\\CMap', +- 'C:\\Program Files\\Adobe\\Acrobat 8.0\\Resource\\CMap', +- 'C:\\Program Files\\Adobe\\Acrobat 7.0\\Resource\\CMap', +- 'C:\\Program Files\\Adobe\\Acrobat 6.0\\Resource\\CMap', +- 'C:\\Program Files\\Adobe\\Acrobat 5.0\\Resource\\CMap', +- 'C:\\Program Files\\Adobe\\Acrobat 4.0\\Resource\\CMap', ++ '/usr/share/ghostscript/9.04/Resource/CMap', ++ '/usr/share/ghostscript/9.06/Resource/CMap', + '%(REPORTLAB_DIR)s/fonts/CMap', #special + '%(REPORTLAB_DIR)s/../fonts/CMap', #special + '%(REPORTLAB_DIR)s/../../fonts/CMap', #special |