aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLeo <thinkabit.ukim@gmail.com>2019-06-08 04:42:33 -0300
committerKevin Daudt <kdaudt@alpinelinux.org>2019-06-08 16:11:51 +0000
commit8d3718890e2c104b6c2ea42f1c52e10773b2d17a (patch)
treeb428a5a457c6b4123e1ca96ea1881060d43aaca9
parent8969bc28c0e2c56c30bf5d5f47f9d31d7e6c8689 (diff)
downloadaports-8d3718890e2c104b6c2ea42f1c52e10773b2d17a.tar.bz2
aports-8d3718890e2c104b6c2ea42f1c52e10773b2d17a.tar.xz
community/libwmf: upgrade to 0.2.12
Closes GH-8633
-rw-r--r--community/libwmf/APKBUILD30
-rw-r--r--community/libwmf/freetype.patch66
-rw-r--r--community/libwmf/libpng14.patch12
3 files changed, 78 insertions, 30 deletions
diff --git a/community/libwmf/APKBUILD b/community/libwmf/APKBUILD
index c557abc05d..d088390110 100644
--- a/community/libwmf/APKBUILD
+++ b/community/libwmf/APKBUILD
@@ -1,43 +1,37 @@
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=libwmf
-pkgver=0.2.8.4
-pkgrel=4
+pkgver=0.2.12
+pkgrel=0
pkgdesc="A library for reading vector images in Microsoft's native Windows Metafile Format (WMF)."
url="http://wvware.sourceforge.net/libwmf.html"
arch="all"
-license="LGPL"
+license="LGPL-2.0-or-later"
depends="ghostscript-fonts"
-makedepends="libpng-dev>=1.4.0 freetype-dev jpeg-dev>=8 expat-dev"
-install=
+makedepends="libpng-dev>=1.4.0 freetype-dev jpeg-dev>=8 expat-dev
+ automake autoconf libtool"
subpackages="$pkgname-dev"
-source="https://downloads.sourceforge.net/sourceforge/wvware/$pkgname-$pkgver.tar.gz
- libpng14.patch"
-
-builddir="$srcdir"/$pkgname-$pkgver
+source="$pkgname-$pkgver.tar.gz::https://github.com/caolanm/libwmf/archive/v$pkgver.tar.gz
+ freetype.patch
+ "
prepare() {
default_prepare
- update_config_guess
-
- cd "$builddir"
- sed -i -e 's/src include fonts doc/src include fonts/g' Makefile.in
+ autoreconf -fi -Ipatches
}
build() {
- cd "$builddir"
./configure --prefix=/usr \
--with-gsfontdir=/usr/share/fonts/Type1 \
--with-fontdir=/usr/share/fonts/Type1 \
- --with-gsfontmap=/usr/share/ghostscript/8.15/lib/Fontmap.GS
+ --with-gsfontmap=/usr/share/ghostscript/9.10/lib/Fontmap.GS
make
}
package() {
- cd "$builddir"
make -j1 DESTDIR="$pkgdir" install
# Remove fonts, these are in ghostscript-fonts
rm -rf "$pkgdir/usr/share/fonts"
}
-sha512sums="d98df8e76a52245487b13e5ab3d2fbba9d246f97ee04a7344c0e5861bb2d0f990fc6d662dbd849ce621768b06eaebd4270fb34bec4ee004334a98b14ba6044a5 libwmf-0.2.8.4.tar.gz
-804a43fa37928a91a477cfc875e80b55ebfcb6682cc12e661ca70006df8c4326e2ecf8ce3ffefbee465597bf47abbbfe7762981205a366aac32a43e1e9e1da7b libpng14.patch"
+sha512sums="9280851e560becc91546906b911e0c59a1abd690e10680f6d94a335d66aeaec5eb12ccf2214ee7af2a15729a7b5f8b906022822399b4e2bc12c75a2d75748cab libwmf-0.2.12.tar.gz
+d60ec85731f4d797c7188883302dc816c77b7ad7d87fe5187e2237e84e0ccfb5b017a3398bb20f0fc14bad53270c8940360858063bb0ae063437d2a255e3874d freetype.patch"
diff --git a/community/libwmf/freetype.patch b/community/libwmf/freetype.patch
new file mode 100644
index 0000000000..44cab47cfa
--- /dev/null
+++ b/community/libwmf/freetype.patch
@@ -0,0 +1,66 @@
+From 61655f82224cadb261e81f8bae111eaaa7bdf531 Mon Sep 17 00:00:00 2001
+From: Koen Kooi <koen@dominion.thruhere.net>
+Date: Wed, 6 Aug 2014 14:53:03 +0200
+Subject: [PATCH] configure: use pkg-config for freetype
+
+Upstream-status: Pending
+Signed-off-by: Koen Kooi <koen@dominion.thruhere.net>
+---
+ configure.ac | 37 ++++++++-----------------------------
+ 1 file changed, 8 insertions(+), 29 deletions(-)
+
+diff --git a/configure.ac b/configure.ac
+index 3cfe974..0055a8c 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -399,40 +399,19 @@ AC_ARG_WITH(freetype,[ --with-freetype=DIR use freetype2 in DIR],[
+ fi
+ ])
+
+-if [ test -n "$FREETYPE_DIR" ]; then
+- AC_PATH_PROG(FREETYPE_CONFIG,freetype-config, ,[$FREETYPE_DIR/bin:$PATH])
+-else
+- AC_PATH_PROG(FREETYPE_CONFIG,freetype-config)
+-fi
+-
+-if [ test -n "$FREETYPE_CONFIG" ]; then
+- if [ test -n "$FREETYPE_DIR" ]; then
+- freetype_cflags="`$FREETYPE_CONFIG --cflags` -I$FREETYPE_DIR/include"
+- freetype_libs=`$FREETYPE_CONFIG --libs`
+- else
+- freetype_cflags=`$FREETYPE_CONFIG --cflags`
+- freetype_libs=`$FREETYPE_CONFIG --libs`
+- fi
+-else
+- if [ test -n "$FREETYPE_DIR" ]; then
+- freetype_cflags="-I$FREETYPE_DIR/include/freetype2 -I$FREETYPE_DIR/include"
+- freetype_libs="-L$FREETYPE_DIR/lib -lfreetype"
+- else
+- freetype_cflags=""
+- freetype_libs="-lfreetype"
+- fi
+-fi
+-
+-CPPFLAGS="$freetype_cflags $CPPFLAGS"
+-LDFLAGS="$LDFLAGS $freetype_libs"
++PKG_CHECK_MODULES(FREETYPE2, freetype2,
++ CFLAGS="$CFLAGS $FREETYPE2_CFLAGS"
++ LDFLAGS="$LDFLAGS $FREETYPE2_LIBS",
++ AC_MSG_ERROR([*** Unable to find FreeType2 library (http://www.freetype.org/)])
++)
+
+ AC_CHECK_LIB(freetype,FT_Init_FreeType,[
+- WMF_FT_LDFLAGS="$freetype_libs"
++ WMF_FT_LDFLAGS="$FREETYPE2_LIBS"
+ ],[ AC_MSG_ERROR([* * * freetype(2) is required * * *])
+ ])
+ AC_CHECK_HEADER(ft2build.h,[
+- WMF_FT_CFLAGS="$freetype_cflags"
+- WMF_FT_CONFIG_CFLAGS="$freetype_cflags"
++ WMF_FT_CFLAGS="$FREETYPE2_CFLAGS"
++ WMF_FT_CONFIG_CFLAGS="$FREETYPE2_CFLAGS"
+ ],[ AC_MSG_ERROR([* * * freetype(2) is required * * *])
+ ])
+
+
+
diff --git a/community/libwmf/libpng14.patch b/community/libwmf/libpng14.patch
deleted file mode 100644
index 3d38c717aa..0000000000
--- a/community/libwmf/libpng14.patch
+++ /dev/null
@@ -1,12 +0,0 @@
-diff -Nur libwmf-0.2.8.4.orig/src/extra/gd/gd_png.c libwmf-0.2.8.4/src/extra/gd/gd_png.c
---- libwmf-0.2.8.4.orig/src/extra/gd/gd_png.c 2005-07-27 23:35:06.000000000 +0300
-+++ libwmf-0.2.8.4/src/extra/gd/gd_png.c 2010-01-17 01:33:58.000000000 +0200
-@@ -136,7 +136,7 @@
- /* first do a quick check that the file really is a PNG image; could
- * have used slightly more general png_sig_cmp() function instead */
- gdGetBuf (sig, 8, infile);
-- if (!png_check_sig (sig, 8))
-+ if (png_sig_cmp (sig, 0, 8))
- return NULL; /* bad signature */
-
- #ifndef PNG_SETJMP_NOT_SUPPORTED