[Scipy-svn] r2193 - trunk/Lib/sandbox/svm

scipy-svn at scipy.org scipy-svn at scipy.org
Fri Sep 8 11:14:47 CDT 2006


Author: fullung
Date: 2006-09-08 11:14:39 -0500 (Fri, 08 Sep 2006)
New Revision: 2193

Modified:
   trunk/Lib/sandbox/svm/libsvm.py
Log:
Load library built with distutils.


Modified: trunk/Lib/sandbox/svm/libsvm.py
===================================================================
--- trunk/Lib/sandbox/svm/libsvm.py	2006-09-08 10:40:47 UTC (rev 2192)
+++ trunk/Lib/sandbox/svm/libsvm.py	2006-09-08 16:14:39 UTC (rev 2193)
@@ -1,13 +1,15 @@
 import inspect
 
 from ctypes import *
+import distutils.sysconfig
 import numpy as N
 
 __all__ = [
     'svm_node_dtype'
     ]
 
-_libsvm = N.ctypeslib.load_library('libsvm_', __file__)
+so_ext = distutils.sysconfig.get_config_vars('SO')[0]
+_libsvm = N.ctypeslib.load_library('libsvm_%s' % so_ext, __file__)
 
 svm_node_dtype = \
     N.dtype({'names' : ['index', 'value'],



More information about the Scipy-svn mailing list