Revision: 7985
          http://matplotlib.svn.sourceforge.net/matplotlib/?rev=7985&view=rev
Author:   mdboom
Date:     2009-11-24 18:45:18 +0000 (Tue, 24 Nov 2009)

Log Message:
-----------
Reduce compiler warnings with Sun Studio

Modified Paths:
--------------
    trunk/matplotlib/setupext.py

Modified: trunk/matplotlib/setupext.py
===================================================================
--- trunk/matplotlib/setupext.py        2009-11-24 18:15:49 UTC (rev 7984)
+++ trunk/matplotlib/setupext.py        2009-11-24 18:45:18 UTC (rev 7985)
@@ -121,6 +121,10 @@
            'build_windowing': True,
            'backend': None}
 
+defines = [
+       ('PY_ARRAYAUNIQUE_SYMBOL', 'MPL_ARRAY_API'),
+       ('PYCXX_ISO_CPP_LIB', '1')]
+
 # Based on the contents of setup.cfg, determine the build options
 if os.path.exists("setup.cfg"):
     config = ConfigParser.SafeConfigParser()
@@ -1105,7 +1109,7 @@
     deps.extend(glob.glob('CXX/*.c'))
 
     module = Extension('matplotlib.ft2font', deps,
-                       define_macros=[('PY_ARRAYAUNIQUE_SYMBOL', 
'MPL_ARRAY_API')])
+                       define_macros=defines)
     add_ft2font_flags(module)
     ext_modules.append(module)
     BUILT_FT2FONT = True
@@ -1118,7 +1122,8 @@
             'ttconv/pprdrv_tt2.cpp',
             'ttconv/ttutil.cpp']
 
-    module = Extension('matplotlib.ttconv', deps)
+    module = Extension('matplotlib.ttconv', deps,
+                      define_macros=defines)
     add_base_flags(module)
     ext_modules.append(module)
     BUILT_TTCONV = True
@@ -1132,7 +1137,7 @@
 
     module = Extension('matplotlib.backends._gtkagg',
                        deps,
-                       define_macros=[('PY_ARRAY_UNIQUE_SYMBOL', 
'MPL_ARRAY_API')]
+                       define_macros=defines
                        )
 
     # add agg flags before pygtk because agg only supports freetype1
@@ -1155,7 +1160,7 @@
 
     module = Extension('matplotlib.backends._tkagg',
                        deps,
-                       define_macros=[('PY_ARRAY_UNIQUE_SYMBOL', 
'MPL_ARRAY_API')]
+                       define_macros=defines
                        )
 
     add_tk_flags(module) # do this first
@@ -1198,7 +1203,7 @@
     module = Extension('matplotlib.backends._macosx',
                        deps,
                        extra_link_args = ['-framework','Cocoa'],
-                       define_macros=[('PY_ARRAY_UNIQUE_SYMBOL', 
'MPL_ARRAY_API')]
+                       define_macros=defines
                       )
     add_numpy_flags(module)
     add_agg_flags(module)
@@ -1217,7 +1222,7 @@
         'matplotlib._png',
         deps,
         include_dirs=numpy_inc_dirs,
-        define_macros=[('PY_ARRAY_UNIQUE_SYMBOL', 'MPL_ARRAY_API')]
+        define_macros=defines
         )
 
     add_png_flags(module)
@@ -1249,7 +1254,7 @@
         'matplotlib.backends._backend_agg',
         deps,
         include_dirs=numpy_inc_dirs,
-        define_macros=[('PY_ARRAY_UNIQUE_SYMBOL', 'MPL_ARRAY_API')]
+        define_macros=defines
         )
 
     add_numpy_flags(module)
@@ -1282,7 +1287,7 @@
         'matplotlib._path',
         deps,
         include_dirs=numpy_inc_dirs,
-        define_macros=[('PY_ARRAY_UNIQUE_SYMBOL', 'MPL_ARRAY_API')]
+        define_macros=defines
         )
 
     add_numpy_flags(module)
@@ -1311,7 +1316,7 @@
         'matplotlib._image',
         deps,
         include_dirs=numpy_inc_dirs,
-        define_macros=[('PY_ARRAY_UNIQUE_SYMBOL', 'MPL_ARRAY_API')]
+        define_macros=defines
         )
 
     add_numpy_flags(module)
@@ -1332,7 +1337,7 @@
     sourcefiles = [os.path.join('lib/matplotlib/delaunay',s) for s in 
sourcefiles]
     delaunay = Extension('matplotlib._delaunay',sourcefiles,
                          include_dirs=numpy_inc_dirs,
-                         define_macros=[('PY_ARRAY_UNIQUE_SYMBOL', 
'MPL_ARRAY_API')]
+                         define_macros=defines
                          )
     add_numpy_flags(delaunay)
     add_base_flags(delaunay)
@@ -1349,7 +1354,7 @@
         'matplotlib._cntr',
         [ 'src/cntr.c'],
         include_dirs=numpy_inc_dirs,
-        define_macros=[('PY_ARRAY_UNIQUE_SYMBOL', 'MPL_ARRAY_API')]
+        define_macros=defines
         )
     add_numpy_flags(module)
     add_base_flags(module)
@@ -1365,7 +1370,7 @@
         'matplotlib.nxutils',
         [ 'src/nxutils.c'],
         include_dirs=numpy_inc_dirs,
-        define_macros=[('PY_ARRAY_UNIQUE_SYMBOL', 'MPL_ARRAY_API')]
+        define_macros=defines
         )
     add_numpy_flags(module)
     add_base_flags(module)
@@ -1384,7 +1389,7 @@
         ['src/backend_gdk.c'],
         libraries = [],
         include_dirs=numpy_inc_dirs,
-        define_macros=[('PY_ARRAY_UNIQUE_SYMBOL', 'MPL_ARRAY_API')]
+        define_macros=defines
         )
 
     add_numpy_flags(module)


This was sent by the SourceForge.net collaborative development platform, the 
world's largest Open Source development site.

------------------------------------------------------------------------------
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day 
trial. Simplify your report design, integration and deployment - and focus on 
what you do best, core application coding. Discover what's new with
Crystal Reports now.  http://p.sf.net/sfu/bobj-july
_______________________________________________
Matplotlib-checkins mailing list
Matplotlib-checkins@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-checkins

Reply via email to