diff --git a/.cvsignore b/.cvsignore index 3e1c47a..b81f8a0 100644 --- a/.cvsignore +++ b/.cvsignore @@ -1,4 +1 @@ -clog -exiv2-0.12.tar.gz -exiv2-0.14.tar.gz -exiv2-0.15.tar.gz +exiv2-0.17.1.tar.gz diff --git a/exiv2-0.11-no_rpath.patch b/exiv2-0.11-no_rpath.patch deleted file mode 100644 index 27e02db..0000000 --- a/exiv2-0.11-no_rpath.patch +++ /dev/null @@ -1,11 +0,0 @@ ---- exiv2-0.11/src/Makefile.no_rpath 2006-09-19 13:49:19.000000000 -0500 -+++ exiv2-0.11/src/Makefile 2006-09-19 13:50:05.000000000 -0500 -@@ -196,7 +196,7 @@ - COMPILE.cc = $(CXX) $(CXXFLAGS) $(CXXDEFS) $(CXXINCS) -c - COMPILE.c = $(CC) $(CFLAGS) $(DEFS) $(INCS) -c - # LINK.cc does not need $(LIBS), libtool's dark magic takes care of that --LINK.cc = $(CXX) $(CXXFLAGS) $(LIBRARY) $(LDFLAGS) -rpath $(libdir) -+LINK.cc = $(CXX) $(CXXFLAGS) $(LIBRARY) $(LDFLAGS) #-rpath $(libdir) - - # ****************************************************************************** - # Rules diff --git a/exiv2-0.13-CVE-2007-6353.patch b/exiv2-0.13-CVE-2007-6353.patch deleted file mode 100644 index 13b7fe9..0000000 --- a/exiv2-0.13-CVE-2007-6353.patch +++ /dev/null @@ -1,89 +0,0 @@ -Index: exiv2-0.13/src/exif.cpp -=================================================================== ---- exiv2-0.13.orig/src/exif.cpp -+++ exiv2-0.13/src/exif.cpp -@@ -215,10 +215,12 @@ namespace Exiv2 { - ExifData::const_iterator sizes; - ExifKey key("Exif.Thumbnail.StripByteCounts"); - sizes = exifData.findKey(key); -- if (sizes == exifData.end()) return 2; -+ if (sizes == exifData.end()) return 1; - -- long totalSize = 0; -+ uint32_t totalSize = 0; - for (long i = 0; i < sizes->count(); ++i) { -+ uint32_t size = sizes->toLong(i); -+ if (size > 0xffffffff - totalSize) return 1; - totalSize += sizes->toLong(i); - } - DataBuf stripsBuf(totalSize); -@@ -228,21 +230,23 @@ namespace Exiv2 { - ExifData::iterator stripOffsets; - key = ExifKey("Exif.Thumbnail.StripOffsets"); - stripOffsets = exifData.findKey(key); -- if (stripOffsets == exifData.end()) return 2; -- if (stripOffsets->count() != sizes->count()) return 2; -+ if (stripOffsets == exifData.end()) return 1; -+ if (stripOffsets->count() != sizes->count()) return 1; - - std::ostringstream os; // for the strip offsets -- long currentOffset = 0; -- long firstOffset = stripOffsets->toLong(0); -- long lastOffset = 0; -- long lastSize = 0; -+ uint32_t currentOffset = 0; -+ uint32_t firstOffset = stripOffsets->toLong(0); -+ uint32_t lastOffset = 0; -+ uint32_t lastSize = 0; - for (long i = 0; i < stripOffsets->count(); ++i) { -- long offset = stripOffsets->toLong(i); -+ uint32_t offset = stripOffsets->toLong(i); - lastOffset = offset; -- long size = sizes->toLong(i); -+ uint32_t size = sizes->toLong(i); - lastSize = size; -- if (len < offset + size) return 1; -- -+ if ( size > 0xffffffff - offset -+ || static_cast(len) < offset + size) { -+ return 2; -+ } - memcpy(stripsBuf.pData_ + currentOffset, buf + offset, size); - os << currentOffset << " "; - currentOffset += size; -@@ -303,12 +307,15 @@ namespace Exiv2 { - ExifKey key("Exif.Thumbnail.JPEGInterchangeFormat"); - ExifData::iterator format = exifData.findKey(key); - if (format == exifData.end()) return 1; -- long offset = format->toLong(); -+ uint32_t offset = format->toLong(); - key = ExifKey("Exif.Thumbnail.JPEGInterchangeFormatLength"); - ExifData::const_iterator length = exifData.findKey(key); - if (length == exifData.end()) return 1; -- long size = length->toLong(); -- if (len < offset + size) return 2; -+ uint32_t size = length->toLong(); -+ if ( size > 0xffffffff - offset -+ || static_cast(len) < offset + size) { -+ return 2; -+ } - format->setDataArea(buf + offset, size); - format->setValue("0"); - if (pIfd1) { -@@ -595,8 +602,14 @@ namespace Exiv2 { - if (pIopIfd_) add(pIopIfd_->begin(), pIopIfd_->end(), byteOrder()); - if (pGpsIfd_) add(pGpsIfd_->begin(), pGpsIfd_->end(), byteOrder()); - if (pIfd1_) add(pIfd1_->begin(), pIfd1_->end(), byteOrder()); -- // Read the thumbnail (but don't worry whether it was successful or not) -- readThumbnail(); -+ // Finally, read the thumbnail -+ rc = readThumbnail(); -+ if (0 < rc) { -+#ifndef SUPPRESS_WARNINGS -+ std::cerr << "Warning: Failed to read thumbnail, rc = " -+ << rc << "\n"; -+#endif -+ } - - return 0; - } // ExifData::load diff --git a/exiv2-0.16-gcc43.patch b/exiv2-0.16-gcc43.patch new file mode 100644 index 0000000..9b00b63 --- /dev/null +++ b/exiv2-0.16-gcc43.patch @@ -0,0 +1,62 @@ +diff -up exiv2-0.16/xmpsdk/src/XMPCore_Impl.hpp.gcc43 exiv2-0.16/xmpsdk/src/XMPCore_Impl.hpp +--- exiv2-0.16/xmpsdk/src/XMPCore_Impl.hpp.gcc43 2007-12-08 10:52:25.000000000 -0600 ++++ exiv2-0.16/xmpsdk/src/XMPCore_Impl.hpp 2008-02-11 08:12:25.000000000 -0600 +@@ -20,6 +20,7 @@ + #include "client-glue/WXMPMeta.hpp" + + #include ++#include + #include + #include + +diff -up exiv2-0.16/xmpsdk/src/XMPMeta-Serialize.cpp.gcc43 exiv2-0.16/xmpsdk/src/XMPMeta-Serialize.cpp +--- exiv2-0.16/xmpsdk/src/XMPMeta-Serialize.cpp.gcc43 2007-10-05 23:46:22.000000000 -0500 ++++ exiv2-0.16/xmpsdk/src/XMPMeta-Serialize.cpp 2008-02-11 07:45:25.000000000 -0600 +@@ -22,8 +22,11 @@ + #include + #endif + ++#include ++ + using namespace std; + ++ + #if XMP_WinBuild + #pragma warning ( disable : 4533 ) // initialization of '...' is skipped by 'goto ...' + #pragma warning ( disable : 4702 ) // unreachable code +diff -up exiv2-0.16/xmpsdk/src/XMPMeta.cpp.gcc43 exiv2-0.16/xmpsdk/src/XMPMeta.cpp +--- exiv2-0.16/xmpsdk/src/XMPMeta.cpp.gcc43 2007-10-06 03:11:52.000000000 -0500 ++++ exiv2-0.16/xmpsdk/src/XMPMeta.cpp 2008-02-11 07:43:12.000000000 -0600 +@@ -24,6 +24,8 @@ + #include + #endif + ++#include ++ + using namespace std; + + #if XMP_WinBuild +diff -up exiv2-0.16/xmpsdk/src/XMPMeta-GetSet.cpp.gcc43 exiv2-0.16/xmpsdk/src/XMPMeta-GetSet.cpp +--- exiv2-0.16/xmpsdk/src/XMPMeta-GetSet.cpp.gcc43 2007-10-01 12:59:06.000000000 -0500 ++++ exiv2-0.16/xmpsdk/src/XMPMeta-GetSet.cpp 2008-02-11 07:48:01.000000000 -0600 +@@ -25,6 +25,8 @@ + #include + #endif + ++#include ++ + using namespace std; + + #if XMP_WinBuild +diff -up exiv2-0.16/xmpsdk/src/XMPMeta-Parse.cpp.gcc43 exiv2-0.16/xmpsdk/src/XMPMeta-Parse.cpp +--- exiv2-0.16/xmpsdk/src/XMPMeta-Parse.cpp.gcc43 2008-02-11 07:46:47.000000000 -0600 ++++ exiv2-0.16/xmpsdk/src/XMPMeta-Parse.cpp 2008-02-11 07:47:00.000000000 -0600 +@@ -23,6 +23,8 @@ + #include + #endif + ++#include ++ + using namespace std; + + #if XMP_WinBuild diff --git a/exiv2.spec b/exiv2.spec index d6aaf47..d951449 100644 --- a/exiv2.spec +++ b/exiv2.spec @@ -6,23 +6,24 @@ Summary: Exif and Iptc metadata manipulation library Name: exiv2 -Version: 0.15 -Release: 5%{?dist} +Version: 0.17.1 +Release: 1%{?dist} License: GPLv2+ Group: Applications/Multimedia URL: http://www.exiv2.org/ -Source0: http://www.exiv2.org/exiv2-%{version}.tar.gz +Source0: http://www.exiv2.org/exiv2-%{version}%{?pre:-%{pre}}.tar.gz BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) -BuildRequires: zlib-devel +BuildRequires: chrpath +BuildRequires: expat-devel BuildRequires: gettext +BuildRequires: zlib-devel # docs -BuildRequires: doxygen graphviz libxslt +#BuildRequires: doxygen graphviz libxslt -Patch1: exiv2-0.11-no_rpath.patch -Patch2: exiv2-0.9.1-deps.patch -Patch3: exiv2-0.13-CVE-2007-6353.patch +Patch1: exiv2-0.9.1-deps.patch +Patch2: exiv2-0.16-gcc43.patch %if 0%{?libs} Requires: %{name}-libs = %{version}-%{release} @@ -31,6 +32,7 @@ Obsoletes: %{name}-libs < %{version}-%{release} Provides: %{name}-libs = %{version}-%{release} %endif + %description A command line utility to access image metadata, allowing one to: * print the Exif metadata of Jpeg images as summary info, interpreted values, @@ -68,37 +70,42 @@ methods for Exif thumbnails, classes to access Ifd and so on. %prep -%setup -q +%setup -q -n %{name}-%{version}%{?pre:-%{pre}} -%patch1 -p1 -b .no_rpath -%patch2 -p1 -b .deps -%patch3 -p1 -b .CVE-2007-6353 +%patch1 -p1 -b .deps +%patch2 -p1 -b .gcc43 mkdir doc/html %build -%configure --disable-static +%configure \ + --disable-rpath \ + --disable-static make %{?_smp_mflags} %install -rm -rf $RPM_BUILD_ROOT +rm -rf %{buildroot} -make install DESTDIR=$RPM_BUILD_ROOT +make install DESTDIR=%{buildroot} %find_lang exiv2 # Unpackaged files -rm -f $RPM_BUILD_ROOT%{_libdir}/lib*.la +rm -f %{buildroot}%{_libdir}/lib*.la # fix perms on installed lib -chmod 755 $RPM_BUILD_ROOT%{_libdir}/lib*.so* +chmod 755 %{buildroot}%{_libdir}/lib*.so* + +# nuke rpaths +chrpath --list %{buildroot}%{_bindir}/exiv2 +chrpath --delete %{buildroot}%{_bindir}/exiv2 %clean -rm -rf $FPM_BUILD_ROOT +rm -rf %{buildroot} %post %{?libs:libs} -p /sbin/ldconfig @@ -116,7 +123,7 @@ rm -rf $FPM_BUILD_ROOT %files libs -f exiv2.lang %defattr(-,root,root,-) %endif -%{_libdir}/libexiv2.so.* +%{_libdir}/libexiv2.so.4* %files devel %defattr(-,root,root,-) @@ -127,8 +134,24 @@ rm -rf $FPM_BUILD_ROOT %changelog -* Mon Dec 17 2007 Rex Dieter 0.15-5 -- CVE-2007-6353 (#425922) +* Mon Jun 23 2008 Rex Dieter 0.17.1-1 +- exiv2-0.17.1 + +* Mon Feb 11 2008 Rex Dieter 0.16-2 +- respin (gcc43) +- gcc43 patch + +* Sun Jan 13 2008 Rex Dieter 0.16-1 +- eviv2-0.16 + +* Mon Dec 17 2007 Rex Dieter 0.16-0.3.pre1 +- CVE-2007-6353 (#425924) + +* Mon Nov 26 2007 Rex Dieter 0.16-0.2.pre1 +- -libs subpkg toggle (f8+) + +* Tue Nov 13 2007 Rex Dieter 0.16-0.1.pre1 +- exiv2-0.16-pre1 * Tue Sep 18 2007 Rex Dieter 0.15-4 - -libs: -Requires: %%name diff --git a/sources b/sources index b712859..fb56a45 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -bb18d19e1d6fb255dadda456cadec00e exiv2-0.15.tar.gz +52a602f4f0d9e89b7084ac795b7547ac exiv2-0.17.1.tar.gz