Thanks for the speedy reply.
I wonder if the python you launched directly is the same as
the python that nrniv is using. ie. check in both cases with
import sys
sys.path
when I do that, the results look to me as though NEURON is pointing in the right place (i.e. same as direct launch python). But maybe you can see further than me:
Code: Select all
$ python
Python 2.6.6 (r266:84374, Aug 31 2010, 11:00:51)
[GCC 4.0.1 (Apple Inc. build 5493)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> import sys
>>> sys.path
['', '/Users/codonn', '/Users/codonn/lib/python/site-packages', '/Library/Frameworks/Python.framework/Versions/2.6/lib/python26.zip', '/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6', '/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/plat-darwin', '/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/plat-mac', '/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/plat-mac/lib-scriptpackages', '/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/lib-tk', '/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/lib-old', '/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/lib-dynload', '/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages']
and
Code: Select all
$ nrniv -python
NEURON -- Release 7.1 (359:7f113b76a94b) 2009-10-26
Duke, Yale, and the BlueBrain Project -- Copyright 1984-2008
See http://www.neuron.yale.edu/credits.html
>>> import sys
>>> sys.path
['', '', '/Library/Python/2.6/site-packages/setuptools-0.6c11-py2.6.egg', '/Library/Python/2.6/site-packages/brian-1.3.0-py2.6.egg', '/Library/Python/2.6/site-packages/numpy-1.5.1-py2.6-macosx-10.6-universal.egg', '/Library/Python/2.6/site-packages/ipython-0.10.2-py2.6.egg', '/Library/Python/2.6/site-packages/nose-1.0.0-py2.6.egg', '/Users/codonn', '/Users/codonn/lib/python/site-packages', '/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python26.zip', '/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6', '/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/plat-darwin', '/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/plat-mac', '/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/plat-mac/lib-scriptpackages', '/System/Library/Frameworks/Python.framework/Versions/2.6/Extras/lib/python', '/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/lib-tk', '/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/lib-old', '/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/lib-dynload', '/Library/Python/2.6/site-packages', '/System/Library/Frameworks/Python.framework/Versions/2.6/Extras/lib/python/PyObjC', '/System/Library/Frameworks/Python.framework/Versions/2.6/Extras/lib/python/wx-2.8-mac-unicode', '/Applications/NEURON-7.1/nrn/share/nrn/lib/python']
As for
Also, I wonder if python, nrniv, and scipy are all using the same arch (i386 vs x86_64).
I checked my architecture:
and when I installed NEURON I explicitly told it that it was i386 by adding
Code: Select all
CFLAGS='-arch i386' CXXFLAGS='-arch i386'
to the configure line. So pretty sure that is OK.
The stdarg.h file problem is a puzzle without further details. If it was an x86_64 vs i386
problem I would have expecte a complaint about different architectures during linking.
stdarg.h is certainly a standard system include file. Can you find it on your hard drive?
Yes, sorry I should have given more info. The stdarg.h file is exactly where the compiler looks for it, but the problem seems to happen on line 4 of the function when it refers to itself. Here is the error message:
Code: Select all
$ python setup.py install
running install
running build
running build_py
running build_ext
building 'neuron.hoc' extension
gcc -fno-strict-aliasing -fno-common -dynamic -isysroot /Developer/SDKs/MacOSX10.4u.sdk -arch ppc -arch i386 -g -O2 -DNDEBUG -g -O3 -I../.././src/oc -I../oc -I/Library/Frameworks/Python.framework/Versions/2.6/include/python2.6 -c inithoc.cpp -o build/temp.macosx-10.3-fat-2.6/inithoc.o
In file included from /Library/Frameworks/Python.framework/Versions/2.6/include/python2.6/unicodeobject.h:4,
from /Library/Frameworks/Python.framework/Versions/2.6/include/python2.6/Python.h:85,
from inithoc.cpp:8:
/Developer/SDKs/MacOSX10.4u.sdk/usr/include/stdarg.h:4:25: error: stdarg.h: No such file or directory
inithoc.cpp:30: warning: deprecated conversion from string constant to ‘char*’
inithoc.cpp:30: warning: deprecated conversion from string constant to ‘char*’
In file included from /Library/Frameworks/Python.framework/Versions/2.6/include/python2.6/unicodeobject.h:4,
from /Library/Frameworks/Python.framework/Versions/2.6/include/python2.6/Python.h:85,
from inithoc.cpp:8:
/Developer/SDKs/MacOSX10.4u.sdk/usr/include/stdarg.h:4:25: error: stdarg.h: No such file or directory
inithoc.cpp:30: warning: deprecated conversion from string constant to ‘char*’
inithoc.cpp:30: warning: deprecated conversion from string constant to ‘char*’
lipo: can't figure out the architecture type of: /var/folders/ae/aeQlCfzNHwqdjzdsPm1RSk+++TI/-Tmp-//ccZZcOK1.out
error: command 'gcc' failed with exit status 1
and here is the stdarg.h file from /Developer/SDKs/MacOSX10.4u.sdk/usr/include/stdarg.h :
Code: Select all
/* This file is public domain. */
/* GCC uses its own copy of this header */
#if defined(__GNUC__)
#include_next <stdarg.h>
#elif defined(__MWERKS__)
#include "mw_stdarg.h"
#else
#error "This header only supports __MWERKS__."
#endif