diff options
Diffstat (limited to 'pcr')
-rw-r--r-- | pcr/textext/0001-Fix-Issue-111-Write-log-file-to-user-writable-dir.patch | 27 | ||||
-rw-r--r-- | pcr/textext/PKGBUILD | 51 |
2 files changed, 60 insertions, 18 deletions
diff --git a/pcr/textext/0001-Fix-Issue-111-Write-log-file-to-user-writable-dir.patch b/pcr/textext/0001-Fix-Issue-111-Write-log-file-to-user-writable-dir.patch new file mode 100644 index 000000000..42c56369a --- /dev/null +++ b/pcr/textext/0001-Fix-Issue-111-Write-log-file-to-user-writable-dir.patch @@ -0,0 +1,27 @@ +From 55c6847481487e0f2e7a44706b873608705d47bf Mon Sep 17 00:00:00 2001 +From: Alexander Blinne <alexander.blinne@uni-jena.de> +Date: Mon, 4 Feb 2019 15:04:56 +0100 +Subject: [PATCH] Fix Issue 111: Write log file to user-writable dir + +--- + extension/textext/__init__.py | 4 +++- + 1 file changed, 3 insertions(+), 1 deletion(-) + +diff --git a/extension/textext/__init__.py b/extension/textext/__init__.py +index 5c26968..65739ae 100644 +--- a/extension/textext/__init__.py ++++ b/extension/textext/__init__.py +@@ -62,7 +62,9 @@ EXIT_CODE_OK = 0 + EXIT_CODE_EXPECTED_ERROR = 1 + EXIT_CODE_UNEXPECTED_ERROR = 60 + +-LOG_LOCATION = os.path.dirname(__file__) # todo: check destination is writeable ++LOG_LOCATION = os.path.join(defaults.inkscape_extensions_path, "textext") ++if not os.path.isdir(LOG_LOCATION): ++ os.makedirs(LOG_LOCATION) + LOG_FILENAME = os.path.join(LOG_LOCATION, "textext.log") # todo: check destination is writeable + + +-- +2.20.1 + diff --git a/pcr/textext/PKGBUILD b/pcr/textext/PKGBUILD index 92dbc487d..924ae1db3 100644 --- a/pcr/textext/PKGBUILD +++ b/pcr/textext/PKGBUILD @@ -1,23 +1,38 @@ -# Contributor (Arch): Joel Schaerer <joel.schaerer@laposte.net> -# Maintainer (Arch): Stefan Husmann <stefan-husmann@t-online.de> +# Contributor (AUR): Joel Schaerer <joel.schaerer@laposte.net> +# Maintainer (AUR): Stefan Husmann <stefan-husmann@t-online.de> pkgname=textext -pkgver=0.4.4 -pkgrel=3.1 +_pkgname=TexText +pkgver=0.9.1 +pkgrel=4 pkgdesc="An inkscape extension which lets you add LaTeX equations to your drawings" -arch=('i686' 'x86_64') +arch=('any') license=('BSD3') -url="http://pav.iki.fi/software/textext/" -depends=('inkscape' 'texlive-core' 'python2-lxml' 'pdf2svg') -source=(http://pav.iki.fi/software/textext/$pkgname-$pkgver.tar.gz LICENSE.txt) -md5sums=('5dbb18bf762565196f8ac1f68f8607e3' - '91da7de463147c1c78b1c2e6f24da380') +url="https://github.com/textext/textext" +makedepends=('dos2unix') +depends=('inkscape' 'texlive-core' 'python2') +optdepends=('pdf2svg' 'pygtk' 'imagemagick6') +source=("$pkgname-$pkgver.tar.gz::https://github.com/textext/textext/releases/download/$pkgver/${_pkgname}-Linux-$pkgver.tar.gz" + "0001-Fix-Issue-111-Write-log-file-to-user-writable-dir.patch") + +sha256sums=('5c48544b4c51547792909ba89fd27432b58bfb26d9d9c3131ab65ec809d8198b' + '3fc97197fc55a7de3df3ec35955802156a9c9ead07f48fe821792c11f4dcfeab') + +prepare() { + cd "$pkgname-$pkgver" + dos2unix "$srcdir/$pkgname-$pkgver/extension/textext/__init__.py" + patch -l -p1 < "$srcdir/0001-Fix-Issue-111-Write-log-file-to-user-writable-dir.patch" +} + package() { - cd "$srcdir" - install -Dm 644 LICENSE.txt \ - "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE.txt" - install -Dm 755 textext.py \ - "${pkgdir}/usr/share/inkscape/extensions/textext.py" - install -Dm 644 textext.inx \ - "${pkgdir}/usr/share/inkscape/extensions/textext.inx" -}
\ No newline at end of file + install -d "$pkgdir"/usr/share/inkscape/extensions + cd $pkgname-$pkgver/extension + cp -r $pkgname "$pkgdir"/usr/share/inkscape/extensions + install -m644 $pkgname.inx "$pkgdir"/usr/share/inkscape/extensions/ + cd .. + install -d "$pkgdir"/usr/share/licenses/$pkgname + install LICENSE.txt "$pkgdir"/usr/share/licenses/$pkgname/LICENSE.txt + cd "$pkgdir"/usr/share/inkscape/extensions/$pkgname + sed -i '1s+\#!/usr/bin/env python+\#!/usr/bin/env python2+' __init__.py typesetter.py +} + |