Simplified setup.py for new Python module

The removed parts are not necessary since the compiled module no
longer links to the Cantera shared library.
This commit is contained in:
Ray Speth 2012-09-06 19:57:13 +00:00
parent 4bd19494a6
commit 2bd25f52b4
2 changed files with 2 additions and 12 deletions

View file

@ -3,20 +3,13 @@ from setuptools import setup, find_packages, Extension
from distutils.sysconfig import get_config_var
from Cython.Distutils import build_ext
dataFiles = ['_cantera%s' % get_config_var('SO')]
if os.name == 'nt':
dataFiles.append('cantera_shared.dll')
else:
dataFiles.append('libcantera_shared.so')
exts = [Extension("cantera._cantera",
["cantera/_cantera.pyx"],
include_dirs=@py_include_dirs@,
language="c++",
libraries=@py_cantera_libs@,
library_dirs=@py_libdirs@,
extra_compile_args=@py_extra_compiler_args@,
extra_link_args=@py_extra_link_args@)]
extra_compile_args=@py_extra_compiler_args@)]
setup(name="Cantera",
version="@cantera_version@",
@ -29,5 +22,4 @@ setup(name="Cantera",
packages = find_packages(),
cmdclass = {'build_ext': build_ext},
ext_modules = exts,
package_data = {'cantera': dataFiles,
'cantera.data': ['*.xml', '*.cti']})
package_data = {'cantera.data': ['*.xml', '*.cti']})

View file

@ -121,10 +121,8 @@ localenv['py_cantera_libs'] = repr(localenv['cantera_libs'])
localenv['py_libdirs'] = repr([x for x in libDirs if x])
if localenv['CC'] == 'cl':
localenv['py_extra_link_args'] = repr([])
localenv['py_extra_compiler_args'] = repr(['/EHsc'])
else:
localenv['py_extra_link_args'] = repr(['-Wl,-rpath=$$ORIGIN'])
localenv['py_extra_compiler_args'] = repr([])
dataFiles = localenv.RecursiveInstall('#interfaces/cython/cantera/data',