bindings/python/wscript
changeset 4430 4a527879c7ab
parent 4395 489abe44ed7e
child 4440 c47d51e4b286
--- a/bindings/python/wscript	Wed Apr 29 20:55:56 2009 +0200
+++ b/bindings/python/wscript	Thu Apr 30 10:57:30 2009 +0100
@@ -71,7 +71,8 @@
         return
 
     # -fvisibility=hidden optimization
-    if conf.env['CXX_NAME'] == 'gcc' and conf.check_compilation_flag('-fvisibility=hidden'):
+    if (conf.env['CXX_NAME'] == 'gcc' and [int(x) for x in conf.env['CC_VERSION']] >= [4,0,0]
+        and conf.check_compilation_flag('-fvisibility=hidden')):
         conf.env.append_value('CXXFLAGS_PYEXT', '-fvisibility=hidden')
         conf.env.append_value('CCFLAGS_PYEXT', '-fvisibility=hidden')