changeset b072123bc071 in /z/repo/gem5
details: http://repo.gem5.org/gem5?cmd=changeset;node=b072123bc071
description:
        swig: Warn on use of incompatible swig/gcc combinations

        This patch removes the fixed swig warning concerning 2.0.9/2.0.10 and
        adds a warning message for incompatible combinations of swig and gcc.

diffstat:

 SConstruct |  14 ++++++++------
 1 files changed, 8 insertions(+), 6 deletions(-)

diffs (26 lines):

diff -r b47db5ac7d1c -r b072123bc071 SConstruct
--- a/SConstruct        Wed Sep 18 08:46:31 2013 -0400
+++ b/SConstruct        Wed Sep 18 08:46:32 2013 -0400
@@ -730,14 +730,16 @@
     print '       Installed version:', swig_version[2]
     Exit(1)
 
-if swig_version[2] in ["2.0.9", "2.0.10"]:
+# Older versions of swig do not play well with more recent versions of
+# gcc due to assumptions on implicit includes (cstddef) and use of
+# namespaces
+if main['GCC'] and compareVersions(gcc_version, '4.6') > 0 and \
+        compareVersions(swig_version[2], '2') < 0:
     print '\n' + termcap.Yellow + termcap.Bold + \
-        'Warning: SWIG version 2.0.9/10 sometimes generates broken code.\n' + \
+        'Warning: SWIG 1.x cause issues with gcc 4.6 and later.\n' + \
         termcap.Normal + \
-        'This problem only affects some platforms and some Python\n' + \
-        'versions. See the following SWIG bug report for details:\n' + \
-        'http://sourceforge.net/p/swig/bugs/1297/\n'
-
+        'Use SWIG 2.x to avoid assumptions on implicit includes\n' + \
+        'and use of namespaces\n'
 
 # Set up SWIG flags & scanner
 swig_flags=Split('-c++ -python -modern -templatereduce $_CPPINCFLAGS')
_______________________________________________
gem5-dev mailing list
[email protected]
http://m5sim.org/mailman/listinfo/gem5-dev

Reply via email to