[Scipy-svn] r3594 - branches/scipy.scons/scipy/stats

scipy-svn@scip... scipy-svn@scip...
Sun Nov 25 23:32:18 CST 2007


Author: cdavid
Date: 2007-11-25 23:32:08 -0600 (Sun, 25 Nov 2007)
New Revision: 3594

Added:
   branches/scipy.scons/scipy/stats/SConstruct
Modified:
   branches/scipy.scons/scipy/stats/setupscons.py
Log:
stats now builds with scons

Copied: branches/scipy.scons/scipy/stats/SConstruct (from rev 3593, branches/scipy.scons/scipy/special/SConstruct)
===================================================================
--- branches/scipy.scons/scipy/special/SConstruct	2007-11-25 17:51:34 UTC (rev 3593)
+++ branches/scipy.scons/scipy/stats/SConstruct	2007-11-26 05:32:08 UTC (rev 3594)
@@ -0,0 +1,39 @@
+# Last Change: Mon Nov 26 02:00 PM 2007 J
+# vim:syntax=python
+from os.path import join as pjoin, basename as pbasename
+import sys
+import glob
+from distutils.sysconfig import get_python_inc
+
+from numpy.distutils.misc_util import get_numpy_include_dirs
+from numpy.distutils.scons import GetNumpyEnvironment
+from numpy.distutils.scons import CheckF77Clib
+
+env = GetNumpyEnvironment(ARGUMENTS)
+
+env.AppendUnique(CPPPATH = [get_python_inc(), get_numpy_include_dirs()])
+env.AppendUnique(CPPPATH = env['F2PYINCLUDEDIR'])
+
+config = env.NumpyConfigure(custom_tests = {'CheckF77Clib' : CheckF77Clib})
+if not config.CheckF77Clib():
+    raise RuntimeError("Could not get C/F77 runtime information")
+config.Finish()
+
+# Statlib library
+src = glob.glob(pjoin(env['src_dir'], 'statlib', '*.f' ))
+env.NumpyStaticExtLibrary('statlib', 
+                          source = [pjoin('statlib', pbasename(i)) for i in src])
+
+env.AppendUnique(LIBPATH = env['build_dir'])
+
+# Statlib extension
+env.NumpyPythonExtension('statlib', source = 'statlib.pyf', 
+                         F2PYOPTIONS = ["--no-wrap-functions"],
+                         LIBS = 'statlib',
+                         LINKFLAGSEND = env['F77_LDFLAGS'])
+
+# futil extension
+futil_src = env.F2py(pjoin(env['build_dir'], 'futilmodule.c'), 
+                     pjoin(env['build_dir'], 'futil.f'))
+env.NumpyPythonExtension('futil', source = futil_src + ['futil.f'],
+                         LINKFLAGSEND = env['F77_LDFLAGS'])

Modified: branches/scipy.scons/scipy/stats/setupscons.py
===================================================================
--- branches/scipy.scons/scipy/stats/setupscons.py	2007-11-25 17:51:34 UTC (rev 3593)
+++ branches/scipy.scons/scipy/stats/setupscons.py	2007-11-26 05:32:08 UTC (rev 3594)
@@ -6,7 +6,7 @@
     from numpy.distutils.misc_util import Configuration
     config = Configuration('stats', parent_package, top_path, setup_name = 'setupscons.py')
 
-    config.add_subpackage('models')
+    #config.add_subpackage('models')
     config.add_data_dir('tests')
 
     config.add_sconscript('SConstruct')



More information about the Scipy-svn mailing list