Changeset 7627:5971d008a590


Ignore:
Timestamp:
12/13/07 15:45:13 (6 years ago)
Author:
mabshoff@…
Branch:
default
Message:

Make all code linked against BLAS also link against BLAS2, since ATLAS is two libraries. This solution isn't very clean.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • setup.py

    r7617 r7627  
    1616if os.environ.has_key('SAGE_BLAS'): 
    1717    BLAS=os.environ['SAGE_BLAS'] 
     18    BLAS2=os.environ['SAGE_BLAS'] 
    1819elif os.path.exists('/usr/lib/libcblas.dylib') or \ 
    1920     os.path.exists('/usr/lib/libcblas.so'): 
    2021    BLAS='cblas' 
     22    BLAS2='atlas' 
    2123elif os.path.exists('/usr/lib/libblas.dll.a'):    
    2224    BLAS='gslcblas' 
     25    BLAS2='gslcblas' 
    2326else: 
    2427    # This is very slow  (?), but *guaranteed* to be available.  
    2528    BLAS='gslcblas'  
    26  
     29    BLAS2='gslcblas' 
    2730if len(sys.argv) > 1 and sys.argv[1] == "sdist": 
    2831    sdist = True 
     
    282285                   ['sage/libs/linbox/linbox.pyx'], 
    283286                   # For this to work on cygwin, linboxwrap *must* be before ntl. 
    284                    libraries = ['linboxwrap', 'ntl', 'linbox', 'gmp', 'gmpxx', 'stdc++', 'givaro', BLAS], 
     287                   libraries = ['linboxwrap', 'ntl', 'linbox', 'gmp', 'gmpxx', 'stdc++', 'givaro', BLAS, BLAS2], 
    285288                   language = 'c++') 
    286289 
     
    336339matrix_integer_dense = Extension('sage.matrix.matrix_integer_dense', 
    337340                                 ['sage/matrix/matrix_integer_dense.pyx'], 
    338                                   libraries = ['iml', 'gmp', 'm', BLAS])  # order matters for cygwin!! 
     341                                  libraries = ['iml', 'gmp', 'm', BLAS, BLAS2])  # order matters for cygwin!! 
    339342 
    340343matrix_real_double_dense=Extension('sage.matrix.matrix_real_double_dense', 
    341    ['sage/matrix/matrix_real_double_dense.pyx'],libraries=['gsl',BLAS], 
     344   ['sage/matrix/matrix_real_double_dense.pyx'],libraries=['gsl', BLAS, BLAS2], 
    342345   define_macros=[('GSL_DISABLE_DEPRECATED','1')],include_dirs=[SAGE_ROOT+'/local/lib/python2.5/site-packages/numpy/core/include/numpy']) 
    343346 
    344347matrix_complex_double_dense=Extension('sage.matrix.matrix_complex_double_dense', 
    345    ['sage/matrix/matrix_complex_double_dense.pyx'],libraries=['gsl',BLAS], 
     348   ['sage/matrix/matrix_complex_double_dense.pyx'],libraries=['gsl', BLAS, BLAS2], 
    346349   define_macros=[('GSL_DISABLE_DEPRECATED','1')],include_dirs=[SAGE_ROOT+'/local/lib/python2.5/site-packages/numpy/core/include/numpy']) 
    347350 
    348351 
    349 solve = Extension('sage.matrix.solve',['sage/matrix/solve.pyx'],libraries = ['gsl',BLAS],define_macros =  
     352solve = Extension('sage.matrix.solve',['sage/matrix/solve.pyx'],libraries = ['gsl', BLAS, BLAS2],define_macros =  
    350353   [('GSL_DISABLE_DEPRECATED','1')]) 
    351354 
     
    378381 
    379382################ GSL wrapping ###################### 
    380 gsl_probability=Extension('sage.gsl.probability_distribution',['sage/gsl/probability_distribution.pyx'],libraries=['gsl',BLAS],define_macros=[('GSL_DISABLE_DEPRECATED','1')]) 
    381 gsl_integration=Extension('sage.gsl.integration',['sage/gsl/integration.pyx'],define_macros=[('GSL_DISABLE_DEPRECATED','1')], libraries=['gsl',BLAS]) 
     383gsl_probability=Extension('sage.gsl.probability_distribution',['sage/gsl/probability_distribution.pyx'],libraries=['gsl', BLAS, BLAS2],define_macros=[('GSL_DISABLE_DEPRECATED','1')]) 
     384gsl_integration=Extension('sage.gsl.integration',['sage/gsl/integration.pyx'],define_macros=[('GSL_DISABLE_DEPRECATED','1')], libraries=['gsl',BLAS, BLAS2]) 
    382385 
    383386gsl_ode = Extension('sage.gsl.ode',['sage/gsl/ode.pyx'],libraries=['gsl',BLAS],define_macros=[('GSL_DISABLE_DEPRECATED','1')]) 
     
    385388gsl_fft = Extension('sage.gsl.fft', 
    386389                ['sage/gsl/fft.pyx'], 
    387                 libraries = ['gsl', BLAS],define_macros=[('GSL_DISABLE_DEPRECATED','1')]) 
     390                libraries = ['gsl', BLAS, BLAS2],define_macros=[('GSL_DISABLE_DEPRECATED','1')]) 
    388391 
    389392gsl_interpolation = Extension('sage.gsl.interpolation', 
    390393                ['sage/gsl/interpolation.pyx'], 
    391                 libraries = ['gsl', BLAS],  
     394                libraries = ['gsl', BLAS, BLAS2],  
    392395define_macros=[('GSL_DISABLE_DEPRECATED','1')]) 
    393396 
    394397gsl_callback = Extension('sage.gsl.callback', 
    395398                ['sage/gsl/callback.pyx'], 
    396                 libraries = ['gsl', BLAS] 
     399                libraries = ['gsl', BLAS, BLAS2] 
    397400,define_macros=[('GSL_DISABLE_DEPRECATED','1')]) 
    398401 
    399402real_double = Extension('sage.rings.real_double', 
    400403                ['sage/rings/real_double.pyx'], 
    401                 libraries = ['gsl', 'gmp', BLAS],define_macros=[('GSL_DISABLE_DEPRECATED','1')]) 
     404                libraries = ['gsl', 'gmp', BLAS, BLAS2],define_macros=[('GSL_DISABLE_DEPRECATED','1')]) 
    402405 
    403406complex_double = Extension('sage.rings.complex_double', 
    404407                           ['sage/rings/complex_double.pyx'], 
    405                            libraries = ['gsl', BLAS, 'pari', 'gmp']) 
     408                           libraries = ['gsl', BLAS, BLAS2, 'pari', 'gmp']) 
    406409 
    407410real_double_vector = Extension('sage.modules.real_double_vector',['sage/modules/real_double_vector.pyx'], 
    408                               libraries = ['gsl',BLAS,'pari','gmp'],define_macros = [('GSL_DISABLE_DEPRECAED','1')],include_dirs=[SAGE_ROOT+'/local/lib/python2.5/site-packages/numpy/core/include/numpy']) 
     411                              libraries = ['gsl', BLAS, BLAS2, 'pari','gmp'],define_macros = [('GSL_DISABLE_DEPRECAED','1')],include_dirs=[SAGE_ROOT+'/local/lib/python2.5/site-packages/numpy/core/include/numpy']) 
    409412 
    410413complex_double_vector = Extension('sage.modules.complex_double_vector',['sage/modules/complex_double_vector.pyx'], 
    411                            libraries = ['gsl', BLAS, 'pari', 'gmp'],define_macros=[('GSL_DISABLE_DEPRECATED','1')],include_dirs=[SAGE_ROOT+'/local/lib/python2.5/site-packages/numpy/core/include/numpy']) 
     414                           libraries = ['gsl', BLAS, BLAS2, 'pari', 'gmp'],define_macros=[('GSL_DISABLE_DEPRECATED','1')],include_dirs=[SAGE_ROOT+'/local/lib/python2.5/site-packages/numpy/core/include/numpy']) 
    412415 
    413416 
     
    428431 
    429432gsl_array = Extension('sage.gsl.gsl_array',['sage/gsl/gsl_array.pyx'], 
    430                 libraries=['gsl',BLAS],define_macros=[('GSL_DISABLE_DEPRECATED','1')]) 
     433                libraries=['gsl', BLAS, BLAS2],define_macros=[('GSL_DISABLE_DEPRECATED','1')]) 
    431434 
    432435gsl_ode = Extension('sage.gsl.ode',['sage/gsl/ode.pyx'],libraries=['gsl',BLAS], 
Note: See TracChangeset for help on using the changeset viewer.