On Wed, 2007-12-12 at 23:00 -0800, Asheesh Laroia wrote: 
> X-Debbugs-CC:  Hubert Figuiere <[EMAIL PROTECTED]>
> 
> On Wed, 12 Dec 2007, Martin Michlmayr wrote:
> 
> > Package: exempi
> > Version: 1.99.5-1
> > Usertags: ftbfs-gcc-4.3
> >
> > Your package fails to build with GCC 4.3.  Version 4.3 has not been
> > released yet but I'm building with a snapshot in order to find errors
> > and give people an advance warning.  In GCC 4.3, the C++ header
> > dependencies have been cleaned up.  The advantage of this is that
> > programs will compile faster.  The downside is that you actually
> > need to directly #include everything you use (but you really should
> > do this anyway, otherwise your program won't work with any compiler
> > other than GCC).  There's some more information about this at
> > http://www.cyrius.com/journal/2007/05/10#gcc-4.3-include
> 
> Hubert, what do you think of all this?  Full information at 
> http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=456087 .
> 
> -

I have already put some patches for the build on SUSE factory (aka SUSE
11) that use some snapshot of gcc 4.3. 

See attachment. This is already in git for the next upstream release.


Hub
diff --git a/source/XMPCore/XMPCore_Impl.hpp b/source/XMPCore/XMPCore_Impl.hpp
index 29f814a..522b038 100644
--- a/source/XMPCore/XMPCore_Impl.hpp
+++ b/source/XMPCore/XMPCore_Impl.hpp
@@ -21,6 +21,7 @@
 
 #include <vector>
 #include <string>
+#include <cstring>
 #include <map>
 
 #include <cassert>
diff --git a/source/XMPFiles/FileHandlers/PostScript_Handler.cpp b/source/XMPFiles/FileHandlers/PostScript_Handler.cpp
index 316b37c..06b4959 100644
--- a/source/XMPFiles/FileHandlers/PostScript_Handler.cpp
+++ b/source/XMPFiles/FileHandlers/PostScript_Handler.cpp
@@ -7,6 +7,8 @@
 // of the Adobe license agreement accompanying it.
 // =================================================================================================
 
+#include <limits.h>
+
 #include "XMPScanner.hpp"
 
 #include "Scanner_Handler.hpp"
diff --git a/source/XMPFiles/XMPFiles_Impl.hpp b/source/XMPFiles/XMPFiles_Impl.hpp
index 0b776d9..9a65b38 100644
--- a/source/XMPFiles/XMPFiles_Impl.hpp
+++ b/source/XMPFiles/XMPFiles_Impl.hpp
@@ -16,6 +16,7 @@
 #include "EndianUtils.hpp"
 
 #include <string>
+#include <cstring>
 #define TXMP_STRING_TYPE std::string
 #define XMP_INCLUDE_XMPFILES 1
 #include "XMP.hpp"
diff --git a/source/XMPFiles/FormatSupport/IPTC_Support.hpp b/source/XMPFiles/FormatSupport/IPTC_Support.hpp
index 11ff28e..3581cf5 100644
--- a/source/XMPFiles/FormatSupport/IPTC_Support.hpp
+++ b/source/XMPFiles/FormatSupport/IPTC_Support.hpp
@@ -13,6 +13,7 @@
 #include "XMP_Environment.h"	// ! This must be the first include.
 
 #include <map>
+#include <stdlib.h>
 
 #include "XMP_Const.h"
 #include "XMPFiles_Impl.hpp"
diff --git a/source/XMPFiles/FormatSupport/PSIR_Support.hpp b/source/XMPFiles/FormatSupport/PSIR_Support.hpp
index 91d064b..ac5a9a5 100644
--- a/source/XMPFiles/FormatSupport/PSIR_Support.hpp
+++ b/source/XMPFiles/FormatSupport/PSIR_Support.hpp
@@ -13,6 +13,7 @@
 #include "XMP_Environment.h"	// ! This must be the first include.
 
 #include <map>
+#include <stdlib.h>
 
 #include "XMP_Const.h"
 #include "XMPFiles_Impl.hpp"
diff --git a/source/XMPFiles/FormatSupport/TIFF_Support.hpp b/source/XMPFiles/FormatSupport/TIFF_Support.hpp
index ea4d92d..09580c8 100644
--- a/source/XMPFiles/FormatSupport/TIFF_Support.hpp
+++ b/source/XMPFiles/FormatSupport/TIFF_Support.hpp
@@ -13,6 +13,7 @@
 #include "XMP_Environment.h"	// ! This must be the first include.
 
 #include <map>
+#include <stdlib.h>
 
 #include "XMP_Const.h"
 #include "XMPFiles_Impl.hpp"
diff --git a/source/XMPFiles/FormatSupport/XMPScanner.cpp b/source/XMPFiles/FormatSupport/XMPScanner.cpp
index acfdce6..52f021f 100644
--- a/source/XMPFiles/FormatSupport/XMPScanner.cpp
+++ b/source/XMPFiles/FormatSupport/XMPScanner.cpp
@@ -19,6 +19,7 @@
 
 #include <cassert>
 #include <string>
+#include <cstring>
 #include <cstdlib>
 
 #if DEBUG
diff --git a/samples/source/XMPCoreCoverage.cpp b/samples/source/XMPCoreCoverage.cpp
index feb6306..5256531 100644
--- a/samples/source/XMPCoreCoverage.cpp
+++ b/samples/source/XMPCoreCoverage.cpp
@@ -2,6 +2,7 @@
 #include <iostream>
 #include <iomanip>
 #include <fstream>
+#include <cstring>
 
 #include <stdio.h>
 #include <stdlib.h>
diff --git a/samples/source/XMPScanner.cpp b/samples/source/XMPScanner.cpp
index 6527b0e..0b8a023 100644
--- a/samples/source/XMPScanner.cpp
+++ b/samples/source/XMPScanner.cpp
@@ -24,7 +24,7 @@
 #include <iomanip>
 #include <fstream>
 #include <cstdlib>
-
+#include <cstring>
 
 #ifndef UseStringPushBack	// VC++ 6.x does not provide push_back for strings!
 	#define UseStringPushBack	0
diff --git a/samples/source/XMPFilesCoverage.cpp b/samples/source/XMPFilesCoverage.cpp
index 768d055..cf59250 100644
--- a/samples/source/XMPFilesCoverage.cpp
+++ b/samples/source/XMPFilesCoverage.cpp
@@ -3,6 +3,7 @@
 #include <stdexcept>
 #include <errno.h>
 #include <time.h>
+#include <cstring>
 
 #define TXMP_STRING_TYPE std::string
 #define XMP_INCLUDE_XMPFILES 1
diff --git a/samples/source/DumpScannedXMP.cpp b/samples/source/DumpScannedXMP.cpp
index c8c5f94..e337cba 100644
--- a/samples/source/DumpScannedXMP.cpp
+++ b/samples/source/DumpScannedXMP.cpp
@@ -13,6 +13,7 @@
 #include <stdlib.h>
 #include <stdexcept>
 #include <errno.h>
+#include <cstring>
 
 #if WIN_ENV
 	#pragma warning ( disable : 4127 )	// conditional expression is constant
diff --git a/samples/source/DumpMainXMP.cpp b/samples/source/DumpMainXMP.cpp
index 805b999..185966b 100644
--- a/samples/source/DumpMainXMP.cpp
+++ b/samples/source/DumpMainXMP.cpp
@@ -16,6 +16,7 @@
 #include <stdlib.h>
 #include <stdexcept>
 #include <errno.h>
+#include <cstring>
 
 #if WIN_ENV
 	#pragma warning ( disable : 4127 )	// conditional expression is constant
diff --git a/exempi/tests/test1.cpp b/exempi/tests/test1.cpp
index 7e74d31..bddf2b3 100644
--- a/exempi/tests/test1.cpp
+++ b/exempi/tests/test1.cpp
@@ -36,6 +36,7 @@
 
 #include <stdlib.h>
 #include <stdio.h>
+#include <string.h>
 
 #include <string>
 
diff --git a/exempi/tests/test2.cpp b/exempi/tests/test2.cpp
index 0534858..8b3efff 100644
--- a/exempi/tests/test2.cpp
+++ b/exempi/tests/test2.cpp
@@ -36,6 +36,7 @@
 
 #include <stdlib.h>
 #include <stdio.h>
+#include <string.h>
 
 #include <string>
 
diff --git a/exempi/tests/test3.cpp b/exempi/tests/test3.cpp
index 3d0ec07..3ed8023 100644
--- a/exempi/tests/test3.cpp
+++ b/exempi/tests/test3.cpp
@@ -36,6 +36,7 @@
 
 #include <stdlib.h>
 #include <stdio.h>
+#include <string.h>
 
 #include <string>
 #include <iostream>

Reply via email to