hnn icon indicating copy to clipboard operation
hnn copied to clipboard

can't compile HNN source code

Open lpntc opened this issue 2 years ago • 5 comments

Dear HNN team,

on my ARM mac pro, I get the following error after trying to compile the source code:

(hnn) ➜ hnn_source_code make nrnivmodl mod /usr/bin/xcrun /Users/zahrasadat/hnn_source_code -n Mod files: -n "mod/ar.mod" -n "mod/beforestep_py.mod" -n "mod/ca.mod" -n "mod/cad.mod" -n "mod/cat.mod" -n "mod/dipole.mod" -n "mod/dipole_pp.mod" -n "mod/hh2.mod" -n "mod/kca.mod" -n "mod/km.mod" -n "mod/lfp.mod" -n "mod/mea.mod" -n "mod/vecevent.mod"

COBJS='' -> Compiling beforestep_py.c -> Compiling mod_func.c -> Compiling ar.c /Users/runner/miniforge3/conda-bld/neuron_1647273739170/_build_env/bin/clang -g -O2 -march=core2 -mtune=haswell -mssse3 -ftree-vectorize -fPIC -fPIE -fstack-protector-strong -O2 -pipe -isystem /usr/local/Caskroom/miniforge/base/envs/hnn/include -fdebug-prefix-map=/Users/runner/miniforge3/conda-bld/neuron_1647273739170/work=/usr/local/src/conda/neuron-8.0.2 -fdebug-prefix-map=/usr/local/Caskroom/miniforge/base/envs/hnn=/usr/local/src/conda-prefix -I"../mod" -I. -I/usr/local/Caskroom/miniforge/base/envs/hnn/include -fPIC -c beforestep_py.c -o beforestep_py.o -> Compiling ca.c /Users/runner/miniforge3/conda-bld/neuron_1647273739170/_build_env/bin/clang -g -O2 -march=core2 -mtune=haswell -mssse3 -ftree-vectorize -fPIC -fPIE -fstack-protector-strong -O2 -pipe -isystem /usr/local/Caskroom/miniforge/base/envs/hnn/include -fdebug-prefix-map=/Users/runner/miniforge3/conda-bld/neuron_1647273739170/work=/usr/local/src/conda/neuron-8.0.2 -fdebug-prefix-map=/usr/local/Caskroom/miniforge/base/envs/hnn=/usr/local/src/conda-prefix -I"../mod" -I. -I/usr/local/Caskroom/miniforge/base/envs/hnn/include -fPIC -c ca.c -o ca.o /Users/runner/miniforge3/conda-bld/neuron_1647273739170/_build_env/bin/clang -g -O2 -march=core2 -mtune=haswell -mssse3 -ftree-vectorize -fPIC -fPIE -fstack-protector-strong -O2 -pipe -isystem /usr/local/Caskroom/miniforge/base/envs/hnn/include -fdebug-prefix-map=/Users/runner/miniforge3/conda-bld/neuron_1647273739170/work=/usr/local/src/conda/neuron-8.0.2 -fdebug-prefix-map=/usr/local/Caskroom/miniforge/base/envs/hnn=/usr/local/src/conda-prefix -I"../mod" -I. -I/usr/local/Caskroom/miniforge/base/envs/hnn/include -fPIC -c ar.c -o ar.o /Users/runner/miniforge3/conda-bld/neuron_1647273739170/_build_env/bin/clang -g -O2 -march=core2 -mtune=haswell -mssse3 -ftree-vectorize -fPIC -fPIE -fstack-protector-strong -O2 -pipe -isystem /usr/local/Caskroom/miniforge/base/envs/hnn/include -fdebug-prefix-map=/Users/runner/miniforge3/conda-bld/neuron_1647273739170/work=/usr/local/src/conda/neuron-8.0.2 -fdebug-prefix-map=/usr/local/Caskroom/miniforge/base/envs/hnn=/usr/local/src/conda-prefix -I. -I/usr/local/Caskroom/miniforge/base/envs/hnn/include -fPIC -c mod_func.c -o mod_func.o make[1]: /Users/runner/miniforge3/conda-bld/neuron_1647273739170/_build_env/bin/clang: No such file or directory make[1]: *** [mod_func.o] Error 1 make[1]: *** Waiting for unfinished jobs.... /bin/sh: /Users/runner/miniforge3/conda-bld/neuron_1647273739170/_build_env/bin/clang: No such file or directory make[1]: *** [beforestep_py.o] Error 127 /bin/sh: /Users/runner/miniforge3/conda-bld/neuron_1647273739170/_build_env/bin/clang: No such file or directory make[1]: *** [ca.o] Error 127 /bin/sh: /Users/runner/miniforge3/conda-bld/neuron_1647273739170/_build_env/bin/clang: No such file or directory make[1]: *** [ar.o] Error 127 make: *** [x86_64/special] Error 2

and here it is the post install check result:

(hnn) ➜ hnn_source_code installer/mac/check-post.sh

Performing post-install checks for HNN

Checking for XQuartz...ok Checking if HNN is compiled...failed Found a source code directory at /Users/zahrasadat/hnn_source_code, but it needs to be compiled (run make).

Checking for miniconda...ok Checking for existing python...ok Checking PATH environment variable for nrniv...ok Checking PATH environment variable for mpiexec...ok Checking PYTHONHOME environment variable is not set...ok Checking NRN_PYLIB environment variable is not set...ok Checking MPI functionality...ok Checking NEURON nrniv funtionality...ok Checking Python can import pyqtgraph module...ok Checking Python can import matplotlib module...ok Checking Python can import scipy module...ok Checking Python can import psutil module...ok Checking Python can import numpy module...ok Checking Python can import nlopt module...ok Checking Python can import neuron module...ok Checking NEURON nrniv funtionality with Python...ok Checking for setting LD_LIBRARY_PATH...ok Checking NEURON nrniv funtionality with MPI...ok Checking NEURON nrniv funtionality with Python and MPI...ok

Done with post-install checks

FAILED: there were one or more failed checks

I'd appreciate your help, Best regards.

lpntc avatar Apr 21 '22 00:04 lpntc

Hi @lpntc, the checks that are failing are related to environment variables associated with Neuron. Are you installing Neuron from source as well?

ntolley avatar Apr 21 '22 19:04 ntolley

Hi @lpntc, the checks that are failing are related to environment variables associated with Neuron. Are you installing Neuron from source as well?

Hi @ntolley, thanks for the prompt response, I'd actually installed it over a month ago and can't clearly remember the process. But as I can pip install it in another environment right now, I guess that I had done the same before.

lpntc avatar Apr 22 '22 11:04 lpntc

I’ve heard ARM is a pain for compiling stuff. That said I think the latest version of Neuron is built for ARM. To help in the debugging process, would you mind attempting to install hnn-core in a fresh conda environment : https://jonescompneurolab.github.io/hnn-core/stable/index.html

Do you have the same problem there?

On Fri 22 Apr 2022 at 07:16, lpntc @.***> wrote:

Hi @lpntc https://github.com/lpntc, the checks that are failing are related to environment variables associated with Neuron. Are you installing Neuron from source as well?

Hi @ntolley https://github.com/ntolley, thanks for the prompt response, I'd actually installed it over a month ago and can't clearly remember the process. But as I can pip install it in another environment right now, I guess that I had done the same before.

— Reply to this email directly, view it on GitHub https://github.com/jonescompneurolab/hnn/issues/320#issuecomment-1106412436, or unsubscribe https://github.com/notifications/unsubscribe-auth/ADY6FIVYBF5MBYKRH7FA5RLVGKC7RANCNFSM5T5TUAQQ . You are receiving this because you are subscribed to this thread.Message ID: @.***>

-- Sent from my iPhone

jasmainak avatar Apr 22 '22 14:04 jasmainak

That said I think the latest version of Neuron is built for ARM. To help in the debugging process, would you mind attempting to install hnn-core in a fresh conda environment : https://jonescompneurolab.github.io/hnn-core/stable/index.html Do you have the same problem there?

Hi @jasmainak, hnn_core installation went on very softly and no errors occurred.

lpntc avatar Apr 22 '22 18:04 lpntc

okay, you have 3 options:

  1. use hnn-core :)
  2. wait 3 months when we make the new GUI around hnn-core
  3. try debugging HNN install further (might be painful though ...)

If you want to go by 3, maybe try cloning hnn and running the main script python hnn.py after installing the additional dependencies nlopt and PyQt5 in the same environment

jasmainak avatar Apr 22 '22 19:04 jasmainak