diff --git a/icoutils-0.29.1-iconsize.patch b/icoutils-0.29.1-iconsize.patch new file mode 100644 index 0000000..549bfe7 --- /dev/null +++ b/icoutils-0.29.1-iconsize.patch @@ -0,0 +1,34 @@ +diff --git a/icotool/main.c b/icotool/main.c +--- a/icotool/main.c ++++ b/icotool/main.c +@@ -17,6 +17,7 @@ + */ + + #include ++#include + #include /* POSIX */ + #include /* C89 */ + #include /* C89 */ +diff --git a/wrestool/extract.c b/wrestool/extract.c +--- a/wrestool/extract.c ++++ b/wrestool/extract.c +@@ -172,7 +172,7 @@ + if (iconsize != icondir->entries[c].bytes_in_res) { + warn(_("%s: mismatch of size in icon resource `%s' and group (%d vs %d)"), fi->name, name, iconsize, icondir->entries[c].bytes_in_res); + } +- size += iconsize; /* size += icondir->entries[c].bytes_in_res; */ ++ size += iconsize < icondir->entries[c].bytes_in_res ? icondir->entries[c].bytes_in_res : iconsize; + + /* cursor resources have two additional WORDs that contain + * hotspot info */ +diff --git a/wrestool/main.c b/wrestool/main.c +--- a/wrestool/main.c ++++ b/wrestool/main.c +@@ -17,6 +17,7 @@ + */ + + #include ++#include + #include "gettext.h" /* Gnulib */ + #include "configmake.h" + #define _(s) gettext(s) diff --git a/icoutils.spec b/icoutils.spec index 85c54ef..def65a6 100644 --- a/icoutils.spec +++ b/icoutils.spec @@ -1,12 +1,17 @@ Name: icoutils Version: 0.29.1 -Release: 2%{?dist} +Release: 3%{?dist} Summary: Utility for extracting and converting Microsoft icon and cursor files Group: Applications/Multimedia License: GPLv3+ URL: http://www.nongnu.org/icoutils/ Source0: http://savannah.nongnu.org/download/%{name}/%{name}-%{version}.tar.bz2 + +# this patch fixes http://bugzilla.redhat.com/show_bug.cgi?id=701855 +# it has already been applied to the upstream Git repo +Patch0: %{name}-%{version}-iconsize.patch + BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildRequires: gettext libpng-devel @@ -19,12 +24,13 @@ libraries. %prep %setup -q -iconv -f ISO88592 -t UTF8 < NEWS > NEWS.utf8 -iconv -f ISO88592 -t UTF8 < AUTHORS > AUTHORS.utf8 -touch -r NEWS NEWS.utf8 -touch -r AUTHORS AUTHORS.utf8 -mv NEWS.utf8 NEWS -mv AUTHORS.utf8 AUTHORS +%patch0 -p1 + +for f in AUTHORS NEWS; do + iconv -f ISO88592 -t UTF8 < $f > $f.utf8 && \ + touch -r $f $f.utf8 && \ + mv $f.utf8 $f +done %build %configure @@ -44,11 +50,18 @@ rm -rf $RPM_BUILD_ROOT %files -f %{name}.lang %defattr(-,root,root,-) %doc README AUTHORS COPYING NEWS TODO ChangeLog -%{_mandir}/*/* -%{_bindir}/* +%{_bindir}/extresso +%{_bindir}/genresscript +%{_bindir}/icotool +%{_bindir}/wrestool +%{_mandir}/man1/*.1* %changelog +* Mon May 16 2011 Martin Gieseking - 0.29.1-3 +- fixed http://bugzilla.redhat.com/show_bug.cgi?id=701855 +- minor spec cleanup + * Wed Feb 09 2011 Fedora Release Engineering - 0.29.1-2 - Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild