diff --git a/.cvsignore b/.cvsignore
index 3bec80f..c3bd684 100644
--- a/.cvsignore
+++ b/.cvsignore
@@ -1 +1 @@
-djvulibre-3.5.16.tar.gz
+djvulibre-3.5.16cvs.tar.gz
diff --git a/djvulibre-3.5.15-gcc401.patch b/djvulibre-3.5.15-gcc401.patch
deleted file mode 100644
index db003fa..0000000
--- a/djvulibre-3.5.15-gcc401.patch
+++ /dev/null
@@ -1,27 +0,0 @@
-===================================================================
-RCS file: /cvsroot/djvu/djvulibre-3.5/libdjvu/GString.h,v
-retrieving revision 1.19
-retrieving revision 1.20
-diff -u -r1.19 -r1.20
---- djvulibre-3.5/libdjvu/GString.h 2004/08/06 15:11:29 1.19
-+++ djvulibre-3.5/libdjvu/GString.h 2005/07/22 15:28:07 1.20
-@@ -138,6 +138,10 @@
- # endif
- #endif
-
-+class GBaseString;
-+class GUTF8String;
-+class GNativeString;
-+
- // Internal string representation.
- class GStringRep : public GPEnabled
- {
-@@ -433,8 +437,6 @@
- virtual unsigned long getValidUCS4(const char *&source) const;
- };
-
--class GUTF8String;
--class GNativeString;
-
- /** General purpose character string.
- Each dirivied instance of class #GBaseString# represents a
diff --git a/djvulibre-3.5.16-extraqualif.patch b/djvulibre-3.5.16-extraqualif.patch
deleted file mode 100644
index 521e7b6..0000000
--- a/djvulibre-3.5.16-extraqualif.patch
+++ /dev/null
@@ -1,28 +0,0 @@
-diff -Naupr djvulibre-3.5.16.orig/libdjvu/ByteStream.h djvulibre-3.5.16/libdjvu/ByteStream.h
---- djvulibre-3.5.16.orig/libdjvu/ByteStream.h 2003-11-07 23:08:20.000000000 +0100
-+++ djvulibre-3.5.16/libdjvu/ByteStream.h 2006-01-30 11:22:17.000000000 +0100
-@@ -242,7 +242,7 @@ public:
- and writes it to the specified stream. */
- void formatmessage( const char *fmt, ... );
- /** Looks up the message and writes it to the specified stream. */
-- void ByteStream::writemessage( const char *message );
-+ void writemessage( const char *message );
- /** Writes a one-byte integer to a ByteStream. */
- void write8 (unsigned int card8);
- /** Writes a two-bytes integer to a ByteStream.
-diff -Naupr djvulibre-3.5.16.orig/libdjvu/GURL.h djvulibre-3.5.16/libdjvu/GURL.h
---- djvulibre-3.5.16.orig/libdjvu/GURL.h 2003-11-07 23:08:21.000000000 +0100
-+++ djvulibre-3.5.16/libdjvu/GURL.h 2006-01-30 11:18:17.000000000 +0100
-@@ -278,10 +278,10 @@ public:
- //@}
-
- /// Returns TRUE if #gurl1# and #gurl2# are the same
-- bool GURL::operator==(const GURL & gurl2) const;
-+ bool operator==(const GURL & gurl2) const;
-
- /// Returns TRUE if #gurl1# and #gurl2# are different
-- bool GURL::operator!=(const GURL & gurl2) const;
-+ bool operator!=(const GURL & gurl2) const;
-
- /// Assignment operator
- GURL & operator=(const GURL & url);
diff --git a/djvulibre.spec b/djvulibre.spec
index 08b0516..ef259b1 100644
--- a/djvulibre.spec
+++ b/djvulibre.spec
@@ -1,12 +1,11 @@
Summary: DjVu viewers, encoders and utilities
Name: djvulibre
Version: 3.5.16
-Release: 1%{?dist}
+Release: 3%{?dist}
License: GPL
Group: Applications/Publishing
URL: http://djvulibre.djvuzone.org/
-Source: http://dl.sf.net/djvu/djvulibre-%{version}.tar.gz
-Patch0: djvulibre-3.5.16-extraqualif.patch
+Source: http://dl.sf.net/djvu/djvulibre-%{version}cvs.tar.gz
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root
BuildRequires: qt-devel, libjpeg-devel, libtiff-devel
BuildRequires: mozilla, redhat-menus, hicolor-icon-theme
@@ -38,7 +37,9 @@ compatible with version 3.5 of the LizardTech DjVu software suite.
%prep
%setup
-%patch0 -p1 -b .extraqualif
+# In 3.5.15cvs, hardcoded "/usr/include/qt3" needs replacing
+. /etc/profile.d/qt.sh
+%{__perl} -pi -e "s|/usr/include/qt3|${QTINC}|g" gui/djview/Makefile.dep
%build
@@ -97,13 +98,19 @@ update-desktop-database /usr/share/applications || :
#files devel
#defattr(-, root, root, 0755)
%{_includedir}/libdjvu/
+%{_libdir}/pkgconfig/ddjvuapi.pc
%exclude %{_libdir}/*.la
%{_libdir}/*.so
%changelog
+* Tue Mar 14 2006 Matthias Saou 3.5.16-3
+- Update to CVS snapshot, fixes the build with gcc 4.1 (sf.net #1420522).
+- Include workaround for wrong qt3 includes in gui/djview/Makefile.dep.
+- Add new pkgconfig ddjvuapi.pc file.
+
* Mon Mar 6 2006 Matthias Saou 3.5.16-2
-- FC5 rebuild.
+- FC5 rebuild... nope.
* Mon Jan 30 2006 Matthias Saou 3.5.16-1
- Update to 3.5.16.
diff --git a/sources b/sources
index d9f2e5d..64e7658 100644
--- a/sources
+++ b/sources
@@ -1 +1 @@
-5591c99a50aed1613a796a5aa4978fc0 djvulibre-3.5.16.tar.gz
+45e3436ca4a0f2d791909464da03bf62 djvulibre-3.5.16cvs.tar.gz