-
Notifications
You must be signed in to change notification settings - Fork 0
/
cmd_bullpen.script
44 lines (30 loc) · 980 Bytes
/
cmd_bullpen.script
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
#!/usr/bin/tcsh -X
# this is a bullpen of commands to build components or generated results
#
#
set v=`python -V | sed -e "s/\..\+//"`
echo "Python Version:"
echo $v
if ( "$v" != "Python 3" ) then
set python=python3
else
set python=python
endif
#Python
#Cythonizing Artificials
cd WDS-Python/WDS/Comp
set NUMPY_LOC="`${python} -c 'import numpy; print(numpy.__file__)'`"
if ( $?CPPLFAGS ) then
setenv CPPFLAGS "${CPPFLAGS} -I${NUMPY_LOC:h}/core/include"
else
setenv CPPFLAGS "-I${NUMPY_LOC:h}/core/include"
endif
${python} setup.py build_ext --inplace
${python} setup.py clean --all
/usr/bin/rm Artificials_CythonWrapped.c
/usr/bin/rm Artificials_CythonWrapped.h
cd -
#generating Bindings
./WDS-Python/scripts/generateDS_all_script
#Test of bindings
${python} WDS-Python/scripts/WDSModel_test1.py -x WDS-XML/XML-Examples/WDSModel-Example.xml