mirror of
https://github.com/Cantera/cantera.git
synced 2025-02-25 18:55:29 -06:00
perform configuration of setup.py
This commit is contained in:
parent
323310bffd
commit
27b6aa9f5c
@ -29,12 +29,16 @@ SRCS = src/ctphase_methods.cpp \
|
||||
all: _build
|
||||
|
||||
_build: $(SRCS) $(LIB_DEPS)
|
||||
touch src/pycantera.cpp
|
||||
touch src/pycantera.cpp
|
||||
@PYTHON_CMD@ setup.py build
|
||||
echo 'ok' > _build
|
||||
|
||||
install:
|
||||
ifeq (@local_inst@,1)
|
||||
@PYTHON_CMD@ setup.py install --prefix=@prefix@
|
||||
else
|
||||
@PYTHON_CMD@ setup.py install
|
||||
endif
|
||||
|
||||
clean:
|
||||
@PYTHON_CMD@ setup.py clean
|
||||
|
13
Cantera/python/setup.py → Cantera/python/setup.py.in
Executable file → Normal file
13
Cantera/python/setup.py → Cantera/python/setup.py.in
Executable file → Normal file
@ -1,9 +1,12 @@
|
||||
#!/usr/bin/python2
|
||||
|
||||
from distutils.core import setup, Extension
|
||||
|
||||
libs = []
|
||||
import sys
|
||||
try:
|
||||
from distutils.core import setup, Extension
|
||||
except:
|
||||
print 'could not import distutils. Skipping Python interface.'
|
||||
sys.exit(0)
|
||||
|
||||
libs = []
|
||||
platform = sys.platform
|
||||
|
||||
if platform == "win32":
|
||||
@ -35,7 +38,7 @@ setup(name="Cantera",
|
||||
["src/pycantera.cpp"],
|
||||
include_dirs=["../../build/include",
|
||||
"src", "../clib/src"],
|
||||
library_dirs = ["../../build/lib"], libraries = libs)
|
||||
library_dirs = ["@buildlib@"], libraries = libs)
|
||||
],
|
||||
)
|
||||
|
Loading…
Reference in New Issue
Block a user