diff --git a/ImageMagick-6.7.1-0-reason-error-message.patch b/ImageMagick-6.7.1-0-reason-error-message.patch new file mode 100644 index 0000000..efd2c03 --- /dev/null +++ b/ImageMagick-6.7.1-0-reason-error-message.patch @@ -0,0 +1,15 @@ +--- magick/exception.c 2011-09-06 15:31:15.000000000 +0200 ++++ magick/exception.c 2011-09-06 17:11:20.000000000 +0200 +@@ -458,7 +458,11 @@ MagickExport char *GetExceptionMessage(c + exception[MaxTextExtent]; + + #if defined(MAGICKCORE_HAVE_STRERROR_R) +- (void) strerror_r(error,exception,sizeof(exception)); ++ #if !defined(_GNU_SOURCE) ++ (void) strerror_r(error,exception,sizeof(exception)); ++ #else ++ (void) CopyMagickString(exception,strerror_r(error, exception, sizeof(exception)),sizeof(exception)); ++ #endif + #else + (void) CopyMagickString(exception,strerror(error),sizeof(exception)); + #endif diff --git a/ImageMagick.changes b/ImageMagick.changes index 2e78ee7..e56c99d 100644 --- a/ImageMagick.changes +++ b/ImageMagick.changes @@ -1,3 +1,8 @@ +------------------------------------------------------------------- +Wed Sep 7 08:53:45 UTC 2011 - pgajdos@suse.com + +- fixed wrong error messages [bnc#673303] + ------------------------------------------------------------------- Fri Jul 29 07:07:44 UTC 2011 - pgajdos@novell.com diff --git a/ImageMagick.spec b/ImageMagick.spec index 3ee9023..a882a35 100644 --- a/ImageMagick.spec +++ b/ImageMagick.spec @@ -33,7 +33,7 @@ Name: ImageMagick -BuildRequires: fdupes pkgconfig +BuildRequires: fdupes pkgconfig %if %{with DCraw} BuildRequires: dcraw @@ -108,6 +108,7 @@ Patch2: ImageMagick-6.6.8.9-doc.patch # see http://www.imagemagick.org/discourse-server/viewtopic.php?f=2&t=18435&hilit=include # for upstream progress Patch3: ImageMagick-6.6.9.1-inc-struct.diff +Patch4: ImageMagick-6.7.1-0-reason-error-message.patch BuildRoot: %{_tmppath}/%{name}-%{version}-build Provides: imagemag = %{version} Obsoletes: imagemag < %{version} @@ -145,7 +146,7 @@ Requires: libexif-devel Requires: libjasper-devel %endif %if %{with WEBP} -Requires: libwebp-devel +Requires: libwebp-devel %endif %package extra @@ -159,7 +160,6 @@ AutoReqProv: on %package -n libMagickCore%{libver} - License: PERMISSIVE-OSI-COMPLIANT Summary: Viewer and Converter for Images - runtime library Group: Productivity/Graphics/Other @@ -168,7 +168,6 @@ AutoReqProv: on %package -n libMagickWand%{libver} - License: PERMISSIVE-OSI-COMPLIANT Summary: Viewer and Converter for Images - runtime library Group: Productivity/Graphics/Other @@ -176,7 +175,6 @@ AutoReqProv: on %package -n libMagick++%{libver} - License: PERMISSIVE-OSI-COMPLIANT Requires: ImageMagick Summary: C++ Interface for ImageMagick - runtime library @@ -213,6 +211,7 @@ rm -rf xtp-%{xtp_version} %patch1 %patch2 %patch3 -p1 +%patch4 # remove together with inc-struct.diff ---- echo>header-test.c '#include "wand.h"' # echo>wand.h '#include "wand/MagickWand.h"' # @@ -566,4 +565,5 @@ Authors: %description doc HTML documentation for ImageMagick library and scene examples. + %changelog diff --git a/_service:format_spec_file:ImageMagick.spec b/_service:format_spec_file:ImageMagick.spec new file mode 100644 index 0000000..d72a24d --- /dev/null +++ b/_service:format_spec_file:ImageMagick.spec @@ -0,0 +1,570 @@ +# +# spec file for package ImageMagick +# +# Copyright (c) 2011 SUSE LINUX Products 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/ +# + +# norootforbuild + +%bcond_with xtp +%bcond_without DCraw +%bcond_without FreeType +%bcond_without CXX +%bcond_without Ghostscript +%bcond_without LCMS +%bcond_without TIFF +%bcond_without WMF +%bcond_without XML +%bcond_without DejaVu +%bcond_without EXIF +%bcond_without JPEG +%bcond_without WEBP + +Name: ImageMagick + +BuildRequires: fdupes pkgconfig + +%if %{with DCraw} +BuildRequires: dcraw +%endif + +%if %{with FreeType} +BuildRequires: freetype2-devel +%endif + +%if %{with CXX} +BuildRequires: gcc-c++ +%endif + +%if %{with Ghostscript} +BuildRequires: ghostscript-fonts-other ghostscript-fonts-std ghostscript-library +%endif + +%if %{with LCMS} +BuildRequires: liblcms-devel +%endif + +%if %{with TIFF} +BuildRequires: libtiff-devel +%endif + +%if %{with WMF} +BuildRequires: libwmf-devel +%endif + +%if %{with XML} +BuildRequires: libxml2-devel +%endif + +%if %{with DejaVu} +BuildRequires: libdjvulibre-devel +%endif + +%if %{with EXIF} +BuildRequires: libexif-devel +%endif + +%if %{with JPEG} +BuildRequires: libjasper-devel +%endif + +%if %{with WEBP} +BuildRequires: libwebp-devel +%endif + +%define xtp_version 5.4.3 +%define mfr_version 6.7.1 +%define mfr_revision 0 +%define source_version %{mfr_version}-%{mfr_revision} +License: Public Domain, Freeware +Group: Productivity/Graphics/Other +AutoReqProv: on +Version: %{mfr_version}.%{mfr_revision} +Release: 1 +%define libver 4 +Summary: Viewer and Converter for Images +Url: http://www.imagemagick.org +Source: ImageMagick-%{source_version}.tar.bz2 +# To get mtime of file +Source1: ImageMagick.changes +%if %{with xtp} +Source2: xtp-%{xtp_version}.tar.bz2 +%endif +Source3: baselibs.conf +Patch1: ImageMagick-6.6.8.9-examples.patch +Patch2: ImageMagick-6.6.8.9-doc.patch +# remove inc-struct.diff as soon as it will be not comfortable to port +# see http://www.imagemagick.org/discourse-server/viewtopic.php?f=2&t=18435&hilit=include +# for upstream progress +Patch3: ImageMagick-6.6.9.1-inc-struct.diff +Patch4: ImageMagick-6.7.1-0-reason-error-message.patch +BuildRoot: %{_tmppath}/%{name}-%{version}-build +Provides: imagemag = %{version} +Obsoletes: imagemag < %{version} + +%package -n perl-PerlMagick +License: Public Domain, Freeware +Requires: perl = %{perl_version} ImageMagick = %{version} libMagickCore%{libver} = %{version} +Summary: Perl interface for ImageMagick +Group: Development/Libraries/Perl +AutoReqProv: on + +%package devel +License: PERMISSIVE-OSI-COMPLIANT +Requires: libMagickCore%{libver} = %{version} libMagickWand%{libver} = %{version} +Requires: ImageMagick = %{version} +Summary: Include Files and Libraries Mandatory for Development +Group: Development/Libraries/C and C++ +AutoReqProv: on +%if %{with FreeType} +Requires: freetype2-devel +%endif +%if %{with LCMS} +Requires: liblcms-devel +%endif +%if %{with TIFF} +Requires: libtiff-devel +%endif +%if %{with WMF} +Requires: libwmf-devel +%endif +%if %{with EXIF} +Requires: libexif-devel +%endif +%if %{with JPEG} +Requires: libjasper-devel +%endif +%if %{with WEBP} +Requires: libwebp-devel +%endif + +%package extra +License: PERMISSIVE-OSI-COMPLIANT +Requires: ImageMagick = %{version} libMagickCore%{libver} = %{version} +Summary: Viewer and Converter for Images - extra codecs +Group: Productivity/Graphics/Other +#delegates configured in delegates.xml that imagemagick can use +Recommends: autotrace dcraw transfig ghostscript_any hp2xx netpbm ghostpcl libwmf +AutoReqProv: on + +%package -n libMagickCore%{libver} + +License: PERMISSIVE-OSI-COMPLIANT +Summary: Viewer and Converter for Images - runtime library +Group: Productivity/Graphics/Other +Suggests: ImageMagick-extra = %{version} +AutoReqProv: on + +%package -n libMagickWand%{libver} + +License: PERMISSIVE-OSI-COMPLIANT +Summary: Viewer and Converter for Images - runtime library +Group: Productivity/Graphics/Other +AutoReqProv: on + +%package -n libMagick++%{libver} + +License: PERMISSIVE-OSI-COMPLIANT +Requires: ImageMagick +Summary: C++ Interface for ImageMagick - runtime library +Group: Development/Libraries/C and C++ +AutoReqProv: on +# was last used in openSUSE 10.2 +Provides: ImageMagick-Magick++ = %{version} +Obsoletes: ImageMagick-Magick++ < %{version} + +%package -n libMagick++-devel +License: PERMISSIVE-OSI-COMPLIANT +Requires: ImageMagick-devel = %{version} libMagick++%{libver} = %{version} libstdc++-devel +Summary: C++ Interface for ImageMagick - files mandatory for development +Group: Development/Libraries/C and C++ +Provides: ImageMagick-Magick++-devel = %{version} +Obsoletes: ImageMagick-Magick++-devel < %{version} +AutoReqProv: on + +%package doc +License: PERMISSIVE-OSI-COMPLIANT +Summary: Document Files for ImageMagick Library +Group: Development/Libraries/C and C++ +%if 0%{?suse_version} >= 1120 +BuildArch: noarch +%endif + +%prep +rm -rf xtp-%{xtp_version} +%if %{with xtp} +%setup -n ImageMagick-%{source_version} -b 2 +%else +%setup -n ImageMagick-%{source_version} +%endif +%patch1 +%patch2 +%patch3 -p1 +%patch4 +# remove together with inc-struct.diff ---- +echo>header-test.c '#include "wand.h"' # +echo>wand.h '#include "wand/MagickWand.h"' # +%{__make} header-test.o # + +%build +%define CFLAGS ${RPM_OPT_FLAGS} -fstack-protector-all +%define LDFLAGS -L%{_libdir} +%define system_ltdl 0 +%if %system_ltdl +cp -f %{_datadir}/libtool/libltdl/*.{c,h} ltdl +mv ltdl/ltdl.c ltdl/ltdl.c.orig +sed -e "s:::" ltdl/ltdl.c.orig >ltdl/ltdl.c +%endif +CHANGES=`stat --format="%y" %SOURCE1|cut --characters=1-10` +# Use mtime of .changes for build time +sed -i -e "s|^PACKAGE_RELEASE_DATE.*$|PACKAGE_RELEASE_DATE=\"$CHANGES\"|" version.sh + +autoreconf --force --install -v + +%if %{with xtp} +pushd ../xtp-%{xtp_version} +autoreconf --force --install +popd +%endif + +%if %{suse_version} <= 1030 +# openmp does not work with perl module + OPENMP="--disable-openmp" +%endif +%configure \ + --enable-shared \ + --without-frozenpaths \ + --with-magick_plus_plus \ + --with-modules \ + --with-threads \ + --without-perl \ + --disable-static \ + --with-djvu=yes $OPENMP CFLAGS="%{CFLAGS}" CXXFLAGS="%{CFLAGS}" LDFLAGS="%{LDFLAGS}" +make %{?jobs:-j%jobs} all +cd PerlMagick +perl Makefile.PL +make %{?jobs:-j%jobs} LD_RUN_PATH="%{_libdir}:%{_prefix}/X11R6/%{_lib}" +# +%if %{with xtp} +cd ../../xtp-%{xtp_version} +%configure "CFLAGS=${RPM_OPT_FLAGS} -D_GNU_SOURCE" "CXXFLAGS=${RPM_OPT_FLAGS}" +make %{?jobs:-j%jobs} +%endif + +%check +export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$PWD/magick/.libs:$PWD/wand/.libs +export MAGICK_CODER_MODULE_PATH=$PWD/coders/.libs +export MAGICK_CODER_FILTER_PATH=$PWD/filters/.libs +export MAGICK_CONFIGURE_PATH=$PWD/config +cd PerlMagick +make test + +%install +%{__install} -d "${RPM_BUILD_ROOT%}"'{_defaultdocdir}/%{name}/images' +%{__make} install \ + DESTDIR=$RPM_BUILD_ROOT \ + pkgdocdir=%{_defaultdocdir}/%{name}/ +cd PerlMagick +%{__make} "DESTDIR=${RPM_BUILD_ROOT}" 'LD_RUN_PATH=%{_libdir}:%{_prefix}/X11R6/%{_lib}' install_vendor +%perl_process_packlist +cd '../Magick++' + %{__rm} -rf demo/{.deps,.libs,*.C,*.o,Makefile*,run_demos.bat} + PATH='/bin:/usr/bin' find demo -type f -perm +111 -execdir %{__rm} -rf '{}' ';' + %{__mv} demo/makefile.2 demo/Makefile +cd .. + +%if %{with xtp} +pushd ../xtp-%{xtp_version} + %{__make} DESTDIR=$RPM_BUILD_ROOT install +popd +%endif + +%{__mv} -t "${RPM_BUILD_ROOT}"'%{_sysconfdir}'/%{name}* "${RPM_BUILD_ROOT}"'%{_datadir}'/%{name}*/*.xml +%{__cp} -a -t "${RPM_BUILD_ROOT}"'%{_defaultdocdir}/%{name}/' scenes +PATH='/bin:/usr/bin' find "${RPM_BUILD_ROOT}/%{_libdir}" -name "*.la" ! -empty \ + -execdir %{__sed} -i -e 's@ -L/usr/src[^ ]*@@g' -e 's@ /usr/lib/libltdl.la@@g' '{}' ';' +%{__rm} -f "${RPM_BUILD_ROOT}"'%{_libdir}'/libltdl.* +%{__rm} -f "${RPM_BUILD_ROOT}"'%{_libdir}'/*.la +echo>'%{buildroot}%{_includedir}/%{name}/wand.h' '#include "wand/MagickWand.h"' +%if 0%{?suse_version} > 1020 +%fdupes $RPM_BUILD_ROOT%{_includedir}/%{name}/wand +%fdupes $RPM_BUILD_ROOT%{_defaultdocdir}/%{name}/www/api +%endif + +%clean +%{__rm} -rf $RPM_BUILD_ROOT + +%post -n libMagickCore%{libver} -p /sbin/ldconfig + +%postun -n libMagickCore%{libver} -p /sbin/ldconfig + +%post -n libMagickWand%{libver} -p /sbin/ldconfig + +%postun -n libMagickWand%{libver} -p /sbin/ldconfig + +%post -n libMagick++%{libver} -p /sbin/ldconfig + +%postun -n libMagick++%{libver} -p /sbin/ldconfig + +%files +%defattr(-,root,root) +%docdir %{_docdir}/%{name} +%doc QuickStart.txt README.txt NEWS.txt ChangeLog LICENSE +%define mfr_docdir %{_defaultdocdir}/../%{name}-%{mfr_version}/packages/%{name}/ +%exclude %{mfr_docdir}ChangeLog +%exclude %{mfr_docdir}LICENSE +%exclude %{mfr_docdir}NEWS.txt +%{_bindir}/[^MW]* +%doc %{_mandir}/man1/* +%exclude %{_mandir}/man1/*-config.1.gz + +%files -n libMagickCore%{libver} +%defattr(-,root,root) +%doc LICENSE +%dir %{_sysconfdir}/ImageMagick* +%config %{_sysconfdir}/ImageMagick*/* +%{_libdir}/libMagickCore.so.%{libver}* +%dir %{_libdir}/ImageMagick* +%dir %{_libdir}/ImageMagick*/modules* +%dir %{_libdir}/ImageMagick*/modules*/* +%exclude %{_libdir}/ImageMagick*/modules*/*/wmf.* +%exclude %{_libdir}/ImageMagick*/modules*/*/jp2.* +%exclude %{_libdir}/ImageMagick*/modules*/*/djvu.* +%{_libdir}/ImageMagick*/modules*/*/*.so +# don't remove la files, see bnc#579798 +%{_libdir}/ImageMagick*/modules*/*/*.la + +%files -n libMagickWand%{libver} +%defattr(-,root,root) +%doc LICENSE +%{_libdir}/libMagickWand.so.%{libver}* + +%files extra +%defattr(-,root,root) +%doc LICENSE +%{_libdir}/ImageMagick*/modules*/*/wmf.so +# don't remove la files, see bnc#579798 +%{_libdir}/ImageMagick*/modules*/*/wmf.la +%{_libdir}/ImageMagick*/modules*/*/jp2.so +%{_libdir}/ImageMagick*/modules*/*/jp2.la +%{_libdir}/ImageMagick*/modules*/*/djvu.so +%{_libdir}/ImageMagick*/modules*/*/djvu.la + +%files devel +%defattr(-,root,root) +%doc LICENSE +%{_libdir}/libMagickCore.so +%{_libdir}/libMagickWand.so +%dir %{_includedir}/ImageMagick +%{_includedir}/ImageMagick/magick +%{_includedir}/ImageMagick/wand +%{_includedir}/ImageMagick/wand.h +%{_bindir}/MagickCore-config +%{_bindir}/MagickWand-config +%{_bindir}/Magick-config +%{_bindir}/Wand-config +%{_libdir}/pkgconfig/ImageMagick.pc +%{_libdir}/pkgconfig/Wand.pc +%{_libdir}/pkgconfig/MagickCore.pc +%{_libdir}/pkgconfig/MagickWand.pc +%doc %{_mandir}/man1/*-config.1.gz +%exclude %{_mandir}/man1/Magick++-config.1.gz + +%files -n perl-PerlMagick +%defattr(-,root,root) +%doc LICENSE +%doc PerlMagick/README.txt +%doc PerlMagick/demo +%if %suse_version < 1140 +/var/adm/perl-modules/ImageMagick +%endif +%doc %{_mandir}/man3/Image::Magick.3pm* +%{perl_vendorarch}/auto/Image +%{perl_vendorarch}/Image + +%files -n libMagick++%{libver} +%defattr(-,root,root) +%doc LICENSE +%{_libdir}/libMagick++.so.%{libver}* + +%files -n libMagick++-devel +%defattr(-,root,root) +%doc LICENSE +%doc Magick++/demo +%doc Magick++/NEWS Magick++/README Magick++/AUTHORS +%{_libdir}/libMagick++.so +%{_includedir}/ImageMagick/Magick++.h +%{_includedir}/ImageMagick/Magick++ +%{_bindir}/Magick++-config +%{_libdir}/pkgconfig/ImageMagick++.pc +%{_libdir}/pkgconfig/Magick++.pc +%doc %{_mandir}/man1/Magick++-config.1.gz + +%files doc +%defattr(-,root,root) +%dir %{_docdir}/%{name} +%if 0 +%{_docdir}/%{name}/index.html +%{_docdir}/%{name}/www +%{_docdir}/%{name}/images +%{_docdir}/%{name}/scenes +%endif + +%description +ImageMagick is a robust collection of tools and libraries to read, +write, and manipulate an image in many image formats, including popular +formats like TIFF, JPEG, PNG, PDF, PhotoCD, and GIF. With ImageMagick, +you can create images dynamically, making it suitable for Web +applications. You can also resize, rotate, sharpen, color-reduce, or +add special effects to an image and save your completed work in many +different image formats. Image processing operations are available from +the command line as well as through C, C++, and PERL-based programming +interfaces. + + + +Authors: +-------- + John Cristy + +%description devel +ImageMagick is a robust collection of tools and libraries to read, +write, and manipulate an image in many image formats, including popular +formats like TIFF, JPEG, PNG, PDF, PhotoCD, and GIF. With ImageMagick, +you can create images dynamically, making it suitable for Web +applications. You can also resize, rotate, sharpen, color-reduce, or +add special effects to an image and save your completed work in many +different image formats. Image processing operations are available from +the command line as well as through C, C++, and PERL-based programming +interfaces. + + + +Authors: +-------- + John Cristy + +%description extra +This package adds support for djvu, wmf and jpeg2000 formats and +installs optional helper applications. + +ImageMagick is a robust collection of tools and libraries to read, +write, and manipulate an image in many image formats, including popular +formats like TIFF, JPEG, PNG, PDF, PhotoCD, and GIF. With ImageMagick, +you can create images dynamically, making it suitable for Web +applications. You can also resize, rotate, sharpen, color-reduce, or +add special effects to an image and save your completed work in many +different image formats. Image processing operations are available from +the command line as well as through C, C++, and PERL-based programming +interfaces. + + + +Authors: +-------- + John Cristy + +%description -n libMagickCore%{libver} +ImageMagick is a robust collection of tools and libraries to read, +write, and manipulate an image in many image formats, including popular +formats like TIFF, JPEG, PNG, PDF, PhotoCD, and GIF. With ImageMagick, +you can create images dynamically, making it suitable for Web +applications. You can also resize, rotate, sharpen, color-reduce, or +add special effects to an image and save your completed work in many +different image formats. Image processing operations are available from +the command line as well as through C, C++, and PERL-based programming +interfaces. + + + +Authors: +-------- + John Cristy + +%description -n libMagickWand%{libver} +ImageMagick is a robust collection of tools and libraries to read, +write, and manipulate an image in many image formats, including popular +formats like TIFF, JPEG, PNG, PDF, PhotoCD, and GIF. With ImageMagick, +you can create images dynamically, making it suitable for Web +applications. You can also resize, rotate, sharpen, color-reduce, or +add special effects to an image and save your completed work in many +different image formats. Image processing operations are available from +the command line as well as through C, C++, and PERL-based programming +interfaces. + + + +Authors: +-------- + John Cristy + +%description -n perl-PerlMagick +PerlMagick is an objected-oriented Perl interface to ImageMagick. Use +the module to read, manipulate, or write an image or image sequence +from within a Perl script. This makes it suitable for Web CGI scripts. + + + +Authors: +-------- + John Cristy + +%description -n libMagick++%{libver} +This is Magick++, the object-oriented C++ API for the ImageMagick +image-processing library. + +Magick++ supports an object model inspired by PerlMagick. Magick++ +should be faster than PerlMagick since it is written in a compiled +language which is not parsed at run-time. This makes it suitable for +Web CGI programs. Images support implicit reference counting so that +copy constructors and assignment incur almost no cost. The cost of +actually copying an image (if necessary) is done just before +modification and this copy is managed automatically by Magick++. +De-referenced copies are automatically deleted. The image objects +support value (rather than pointer) semantics so it is trivial to +support multiple generations of an image in memory at one time. + + + +Authors: +-------- + Bob Friesenhahn + +%description -n libMagick++-devel +This is Magick++, the object-oriented C++ API for the ImageMagick +image-processing library. + +Magick++ supports an object model inspired by PerlMagick. Magick++ +should be faster than PerlMagick since it is written in a compiled +language which is not parsed at run-time. This makes it suitable for +Web CGI programs. Images support implicit reference counting so that +copy constructors and assignment incur almost no cost. The cost of +actually copying an image (if necessary) is done just before +modification and this copy is managed automatically by Magick++. +De-referenced copies are automatically deleted. The image objects +support value (rather than pointer) semantics so it is trivial to +support multiple generations of an image in memory at one time. + + + +Authors: +-------- + Bob Friesenhahn + +%description doc +HTML documentation for ImageMagick library and scene examples. + + + +%changelog