Installing Neuron on macOS Mojave

Post Reply
bschneiders
Posts: 31
Joined: Thu Feb 02, 2017 11:30 am

Installing Neuron on macOS Mojave

Post by bschneiders » Mon Apr 22, 2019 12:22 pm

Hi, I updated to Mojave a couple months ago (unfortunately) and have not been able to get my model to run on Neuron since then. I've been using a Linux machine in the meantime, but I decided to give it a shot again on my own machine this past week - it'd be convenient to run it on my own laptop.

Last time, I had built Neuron from source code. This time, I tried both the packaged version and from source code. I uninstalled and reinstalled Anaconda2, and then downloaded the packaged version of Neuron 7.6. I tested nrngui, and also tried opening python and importing neuron, and they both worked. However, if I try to run my model it immediately seg faults. This was my original issue back in December. My model didn't seg fault before I updated.

So then I tried building from source code again. However, I have trouble when installing Neuron. No matter what configure options I use (I tried including "--with-readline=no", for example), I get the same following make error:

Code: Select all

duplicate symbol _nrnpy_o2loc_p_ in:
    .libs/point.o
    .libs/solve.o
ld: 1 duplicate symbol for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
make[4]: *** [libnrnoc.la] Error 1
make[3]: *** [all] Error 2
make[2]: *** [all-recursive] Error 1
make[1]: *** [all-recursive] Error 1
make: *** [all] Error 2

Does anyone know what I can do to get past this?

hines
Site Admin
Posts: 1580
Joined: Wed May 18, 2005 3:32 pm

Re: Installing Neuron on macOS Mojave

Post by hines » Tue Apr 23, 2019 8:32 am

Please do a git pull for nrn. A multiply defined function was introduced by
https://github.com/neuronsimulator/nrn/ ... e37123aa3c
and fixed by
https://github.com/neuronsimulator/nrn/ ... c586e23e6c

bschneiders
Posts: 31
Joined: Thu Feb 02, 2017 11:30 am

Re: Installing Neuron on macOS Mojave

Post by bschneiders » Tue Apr 23, 2019 3:15 pm

Thank you. With that, I get past the make error. Then, in the make install, I first was getting this error:

Code: Select all

clang: error: linker command failed with exit code 1 (use -v to see invocation)
error: command 'g++' failed with exit status 1
I didn't see this error on the Neuron forum, but on other forums it seemed to only pop up with people that had updated to Mojave. It turns out that since I updated to Mojave, I needed to run the following to update my headers (after "xcode-select --install" but I had already installed that):

Code: Select all

open /Library/Developer/CommandLineTools/Packages/macOS_SDK_headers_for_macOS_10.14.pkg
With that installed, I was finally able to get past that issue. However, now I am stuck at the following error:

Code: Select all

/Users/BritaBunnell/anaconda2/lib/python2.7/site-packages/numpy/core/include/numpy/npy_1_7_deprecated_api.h:17:2: warning: 
      "Using deprecated NumPy API, disable it with "          "#define
      NPY_NO_DEPRECATED_API NPY_1_7_API_VERSION" [-W#warnings]
#warning "Using deprecated NumPy API, disable it with " \
 ^
../../share/lib/python/neuron/rxd/geometry3d/ctng.cpp:815:14: fatal error: 
      'complex' file not found
    #include <complex>
             ^~~~~~~~~
2 warnings and 1 error generated.
error: command 'gcc' failed with exit status 1
Any suggestions? Thank you!

hines
Site Admin
Posts: 1580
Joined: Wed May 18, 2005 3:32 pm

Re: Installing Neuron on macOS Mojave

Post by hines » Thu Apr 25, 2019 9:42 pm

May want to update the xcode command line tools. Mine are Apple LLVM version 10.0.1 (see via gcc -v). Not the latest xcode but recent enough.
My Mojave is 10.14.5

bschneiders
Posts: 31
Joined: Thu Feb 02, 2017 11:30 am

Re: Installing Neuron on macOS Mojave

Post by bschneiders » Mon Apr 29, 2019 3:53 pm

Hmm. My xcode command line tools are Apple LLVM version 10.0.1, but my Mojave is 10.14.4, so maybe that needs to be updated. I'll see if that does it. Thanks!

bschneiders
Posts: 31
Joined: Thu Feb 02, 2017 11:30 am

Re: Installing Neuron on macOS Mojave

Post by bschneiders » Mon Apr 29, 2019 4:53 pm

By the way, thanks to help from Robert McDougal, I do have the packaged version of 7.6 working! For anyone else who was having issues with that on a Mac, it has been updated and it fixed what was causing my seg faults.

Post Reply