# # spec file for package libwmf # # Copyright (c) 2018 SUSE LINUX GmbH, Nuernberg, Germany. # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed # upon. The license for this file, and modifications and additions to the # file, is the same license as for the pristine package itself (unless the # license for the pristine package is not an Open Source License, in which # case the license is the MIT License). An "Open Source License" is a # license that conforms to the Open Source Definition (Version 1.9) # published by the Open Source Initiative. # Please submit bugfixes or comments via http://bugs.opensuse.org/ # %define lname libwmf-0_2-7 Name: libwmf Version: 0.2.8.4 Release: 248.2 Summary: Utilities for Displaying and Converting Metafile Images License: LGPL-2.1-or-later Group: Productivity/Graphics/Other Url: http://wvWare.sourceforge.net/ Source: http://downloads.sourceforge.net/project/wvware/%{name}/%{version}/%{name}-%{version}.tar.gz Source2: baselibs.conf Patch0: libwmf-0.2.8.4-ia64.patch Patch1: libwmf-0.2.8.4-fix.patch Patch2: libwmf-0.2.8.4-config.patch Patch3: libwmf-0.2.8.4-overflow-CVE-2006-3376.patch Patch4: libwmf-0.2.8.4-gd_libpng.patch Patch5: libwmf-0.2.8.4-bnc495842.patch Patch6: libwmf-0.2.8.4-CVE-2015-0848.patch Patch7: libwmf-0.2.8.4-badrle.patch Patch8: libwmf-0.2.8.4-CVE-2015-4696.patch Patch9: libwmf-0.2.8.4-CVE-2015-4695.patch Patch10: reproducible.patch Patch11: use-pkg-config-for-freetype.patch BuildRequires: autoconf BuildRequires: automake BuildRequires: gd-devel BuildRequires: gtk2-devel BuildRequires: libjpeg-devel BuildRequires: libtiff-devel BuildRequires: libtool BuildRequires: libxml2-devel BuildRequires: update-desktop-files BuildRequires: xorg-x11-proto-devel BuildRequires: pkgconfig(x11) BuildRequires: pkgconfig(xt) Provides: mswordvw:%{_bindir}/wmftopng Provides: wv:%{_bindir}/wmftopng BuildRoot: %{_tmppath}/%{name}-%{version}-build %description This library interprets metafile images and can either display them using the X Window System or convert them to standard formats such as PNG, JPEG, PS, EPS, and more. %package tools Summary: Utilities for Displaying and Converting Metafile Images # Prov/Obs added on 2011-11-22 (post openSUSE 12.1) Group: Productivity/Graphics/Other Provides: libwmf = %{version}-%{release} Provides: wmf-utils = %{version}-%{release} Obsoletes: libwmf < %{version}-%{release} Obsoletes: wmf-utils < %{version}-%{release} %description tools These utilities read metafile images and can either display them using the X Window System or convert them to standard formats such as PNG, JPEG, PS, EPS, and more. %package -n %{lname} Summary: Library for reading Metafile Images Group: System/Libraries %description -n %{lname} This library reads metafile images. %package devel Summary: Static libraries, header files and documentation for libwmf Group: Development/Libraries/C and C++ Requires: %{lname} = %{version} Requires: libwmf-gnome = %{version} Requires: pkgconfig(freetype2) Requires: pkgconfig(x11) Requires: pkgconfig(xproto) Requires: pkgconfig(zlib) Provides: mswordvd:%{_libexecdir}/libwmf.a Provides: wv-devel:%{_libexecdir}/libwmf.a %description devel The libwmf-devel package contains the header files and static libraries necessary for developing programs using libwmf. %package gnome Summary: GNOME plugin for displaying and Converting Metafile Images Group: System/Libraries %description gnome This library interprets metafile images and can either display them using the X Window System or convert them to standard formats such as PNG, JPEG, PS, EPS, and more. %prep %setup -q %patch0 %patch1 %patch2 %patch3 %patch4 %patch5 %patch6 -p1 %patch7 -p1 %patch8 -p1 %patch9 -p1 %patch10 -p1 %patch11 -p1 %build # Patch11 modifies configure.ac autoreconf -fi %configure --disable-static \ --prefix=%{_prefix} \ --enable-magick \ --libdir=%{_libdir} \ --with-gsfontmap=/usr/share/fonts/ghostscript/Fontmap \ --with-gsfontdir=/usr/share/fonts/ghostscript \ --with-fontdir=/usr/share/fonts/libwmf make %{?_smp_mflags} %install mkdir -p %{buildroot}%{_includedir}/libwmf make DESTDIR=%{buildroot} \ wmfdocdir=%{_defaultdocdir}/libwmf \ wmfonedocdir=%{_defaultdocdir}/libwmf/caolan \ install find %{buildroot} -type f -name "*.la" -delete -print cp AUTHORS COPYING CREDITS ChangeLog README TODO %{buildroot}/%{_defaultdocdir}/libwmf %post -n %{lname} -p /sbin/ldconfig %postun -n %{lname} -p /sbin/ldconfig %files tools %defattr(-,root,root) %{_bindir}/libwmf-fontmap %{_bindir}/wmf2eps %{_bindir}/wmf2fig %{_bindir}/wmf2gd #/usr/bin/wmf2magick #/usr/bin/wmf2plot %{_bindir}/wmf2svg %{_bindir}/wmf2x # # %{_datadir}/fonts/libwmf # %dir %{_defaultdocdir}/libwmf %doc %{_defaultdocdir}/libwmf/AUTHORS %doc %{_defaultdocdir}/libwmf/COPYING %doc %{_defaultdocdir}/libwmf/CREDITS %doc %{_defaultdocdir}/libwmf/ChangeLog %doc %{_defaultdocdir}/libwmf/README %doc %{_defaultdocdir}/libwmf/TODO %files -n %{lname} %defattr(-,root,root) %{_libdir}/libwmf*-0.2.so.7* %files gnome %defattr(-,root,root) %dir %{_libdir}/gtk-*/*/loaders %{_libdir}/gtk-*/*/loaders/*.so %files devel %defattr(-,root,root) %{_bindir}/libwmf-config %{_includedir}/libwmf %{_libdir}/libwmf*.so %dir %{_libdir}/gtk-*/*/loaders # %doc %{_defaultdocdir}/libwmf/*.html %doc %{_defaultdocdir}/libwmf/*.png %doc %{_defaultdocdir}/libwmf/*.gif %doc %{_defaultdocdir}/libwmf/caolan %doc %{_defaultdocdir}/libwmf/html %changelog * Fri May 4 2018 idonmez@suse.com - Add use-pkg-config-for-freetype.patch to use pkgconfig to detect Freetype libraries. Add BR autoconf, automake, libtool due to above. * Tue Mar 13 2018 crrodriguez@opensuse.org - libwmf-0.2.8.4-config.patch: update so -config --libs do not inject bogus dependencies to other packages. - build with disable-static too. * Thu Mar 1 2018 crrodriguez@opensuse.org - Fix -devel package Requires not to still include xorg-x11-devel * Mon Jan 29 2018 sndirsch@suse.com - removed unneeded 'BuildRequires: xorg-x11-util-devel' (bsc#1077489) * Tue Jun 20 2017 bwiedemann@suse.com - Add reproducible.patch to sort input files to make build reproducible (boo#1041090) * Tue Jun 30 2015 fstrba@suse.com - Added patches: * libwmf-0.2.8.4-CVE-2015-4695.patch - Fix CVE-2015-4695: meta_pen_create heap buffer over read (bsc#936058) * libwmf-0.2.8.4-CVE-2015-4696.patch - Fix CVE-2015-4696: wmf2gd/wmf2eps use after free (bsc#936062) * Thu Jun 11 2015 fstrba@suse.com - Added patches: * libwmf-0.2.8.4-CVE-2015-0848.patch - Fix CVE-2015-0848: Heap overflow on libwmf0.2-7 (bsc#933109) * libwmf-0.2.8.4-badrle.patch - Fix CVE-2015-4588: DecodeImage() does not check that the run-length "count" fits into the total size of the image, which can lead to a heap-based buffer overflow (bsc#933109) * Wed Aug 20 2014 nadvornik@suse.com - dropped libwmf-devel -> libwmf-tools dependency (bnc#892356) * Wed May 28 2014 fstrba@suse.com - Clean spec file with spec-cleaner - Do not distribute *.la files * Wed Mar 5 2014 nadvornik@suse.com - Add libwmf-0.2.8.4-bnc495842.patch to fix realloc return value usage (bnc#495842, bnc#831299) * Tue Apr 16 2013 mmeister@suse.com - Added url as source. Please see http://en.opensuse.org/SourceUrls * Mon Jun 18 2012 dimstar@opensuse.org - Add libwmf-0_2-7 to baselibs.conf. * Sat Mar 3 2012 jengelh@medozas.de - Add libjpeg-devel as BuildRequires, needed to resolve build error - Add selected Xorg packages to BR to have wmf2x be built again * Mon Jan 30 2012 jengelh@medozas.de - Remove further redundant sections * Tue Nov 29 2011 jengelh@medozas.de - Actually use "libwmf-tools" instead of wmf-utils, this goes much more in line with the preexisting libwpd-tools and libwps-tools. * Tue Nov 15 2011 jengelh@medozas.de - Remove redundant/unwanted tags/section (cf. specfile guidelines) - Apply shlib packaging (-> new libwmf-0_2-7 subpackage), create "wmf-utils" subpackage as suggested by namtrac * Fri Dec 17 2010 coolo@novell.com - fix file list * Sun Apr 4 2010 ro@suse.de - fix build of in-tree copy of gd to build with new libpng14 (long deprecated function has been removed) * Thu Dec 24 2009 jengelh@medozas.de - package baselibs.conf - enable parallel build * Mon Dec 21 2009 coolo@novell.com - rediff another patch * Tue Dec 8 2009 meissner@suse.de - rediffed without fuzz, some spec cleanups * Tue Nov 25 2008 sbrabec@suse.cz - Supplement gtk2-32bit/gtk2-64bit in baselibs.conf (bnc#354164). * Tue Jan 16 2007 nadvornik@suse.cz - changed gnome prefix to /usr * Thu Aug 24 2006 cthiel@suse.de - fix build * Tue Aug 22 2006 nadvornik@suse.cz - branched libwmf-gnome subpackage [#195613] * Wed Jul 12 2006 nadvornik@suse.cz - fixed integer overflow [CVE-2006-3376. #189924] * Tue Jun 27 2006 nadvornik@suse.cz - updated to bugfix release 0.2.8.4 * fixes various compiler warnings [#185398] * Thu Jan 26 2006 nadvornik@suse.cz - fixed undefined code [#136822] * Wed Jan 25 2006 mls@suse.de - converted neededforbuild to BuildRequires * Thu Jan 12 2006 nadvornik@suse.cz - compile with -fstack-protector * Tue Sep 20 2005 nadvornik@suse.cz - fixed uninitialized variables and missing includes * Tue Jul 26 2005 nadvornik@suse.cz - fixed devel requirements [#98131] * Mon Apr 4 2005 nadvornik@suse.cz - fixed more missing return values * Mon Apr 19 2004 nadvornik@suse.cz - fixed missing return values * Sat Jan 10 2004 adrian@suse.de - add %%defattr and %%run_ldconfig * Wed Jan 7 2004 nadvornik@suse.cz - updated to 0.2.8.2 to build with new freetype * Thu Jul 31 2003 ro@suse.de - move gtk-stuff to /opt/gnome * Mon Jul 14 2003 sbrabec@suse.cz - GNOME prefix change to /opt/gnome. * Mon Jun 16 2003 sbrabec@suse.cz - Updated to version 0.2.8. - Updated neededforbuild and %%files. * Thu May 29 2003 nadvornik@suse.cz - packaged html documentation * Tue Sep 10 2002 pthomas@suse.de - Change libwmf-config to omit /usr/include from output. * Tue Sep 3 2002 nadvornik@suse.cz - fixed crash with ImageMagick * Fri Jul 26 2002 adrian@suse.de - fix neededforbuild * Thu Jun 20 2002 nadvornik@suse.cz - update to 0.2.6 * Mon Apr 29 2002 nadvornik@suse.cz - used macro %%{_libdir} * Wed Mar 13 2002 nadvornik@suse.cz - added /usr/share/doc/packages/libwmf to filelist * Thu Jan 31 2002 ro@suse.de - changed neededforbuild to * Wed Nov 28 2001 nadvornik@suse.cz - update to 0.2.2: - the .fig export uses scaling now, and has options to save images as PNG or JPEG - the .svg export now supports inline images and compression to .svgz - a slight change in the API * Thu Jun 28 2001 nadvornik@suse.cz - splited from wv - update to 0.2.0