Skip to content
This repository was archived by the owner on Mar 20, 2023. It is now read-only.

Commit 17eb114

Browse files
authored
NMODL PYTHONPATH fixes (#333)
* Fix PYTHONPATH for new NMODL pythonpath * Added sympy --analytic flag on NMODL build on the CI
1 parent f0daaa4 commit 17eb114

File tree

2 files changed

+5
-4
lines changed

2 files changed

+5
-4
lines changed

.travis.yml

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,6 @@ matrix:
3232
- os: linux
3333
dist: xenial
3434
env:
35-
- cmake_option="-DCORENRN_ENABLE_NMODL=ON"
3635
- PYTHON_VERSION=3.6.7 # for nmodl pip3 install
3736
- USE_NMODL=ON
3837
- os: osx
@@ -54,7 +53,6 @@ matrix:
5453
- os: osx
5554
osx_image: xcode10.2
5655
env:
57-
- cmake_option="-DCORENRN_ENABLE_NMODL=ON"
5856
- USE_NMODL=ON
5957
- os: linux
6058
dist: xenial
@@ -119,7 +117,7 @@ before_install:
119117
fi
120118
# install NMODL dependencies
121119
- if [[ "$USE_NMODL" == "ON" || "$USE_ISPC" == "ON" ]]; then
122-
pip3 install jinja2 pyyaml pytest sympy;
120+
pip3 install jinja2 pyyaml pytest "sympy<1.6";
123121
fi
124122
- if [ -n "$GCC_VERSION" ]; then
125123
export CXX="g++-${GCC_VERSION}" CC="gcc-${GCC_VERSION}";
@@ -148,6 +146,9 @@ script:
148146
- if [[ "$USE_ISPC" == "ON" ]]; then
149147
cmake -DCORENRN_ENABLE_ISPC=ON -DCMAKE_ISPC_COMPILER=../ispc/bin/ispc
150148
-DCMAKE_INSTALL_PREFIX=$HOME/CoreNeuron -DPYTHON_EXECUTABLE=$(which python3) ..;
149+
elif [[ "$USE_NMODL" == "ON" ]]; then
150+
cmake -DCORENRN_ENABLE_NMODL=ON -DCORENRN_NMODL_FLAGS="sympy --analytic"
151+
-DCMAKE_INSTALL_PREFIX=$HOME/CoreNeuron -DPYTHON_EXECUTABLE=$(which python3) ..;
151152
else
152153
cmake ${cmake_option} -DCMAKE_INSTALL_PREFIX=$HOME/CoreNeuron -DPYTHON_EXECUTABLE=$(which python3) ..;
153154
fi

coreneuron/CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ include(NmodlHelper)
5959
# Command for MOD to CPP conversion
6060
# =============================================================================
6161
set(CORENRN_NMODL_COMMAND env "MODLUNIT=${NMODL_UNITS_FILE}"
62-
"PYTHONPATH=$ENV{PYTHONPATH}:${CMAKE_BINARY_DIR}/lib/python"
62+
"PYTHONPATH=${CORENRN_NMODL_PYTHONPATH}"
6363
${CORENRN_NMODL_BINARY})
6464

6565
if(${CORENRN_ENABLE_ISPC})

0 commit comments

Comments
 (0)