-
Notifications
You must be signed in to change notification settings - Fork 118
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
MACOSX nrniv -python does not allow use with gui. #3248
Comments
Ironically, readline was already
But in creating a pkg file for another machine, static linking is needed,
|
As a side note, I think any libraries from homebrew should not be used to make redistributable wheels, since the "bottles" are usually very machine-specific (should be fine for local installs though). I recall working on a project that needed some external libraries, and the homebrew versions were completely incompatible for portable wheels, so I ended up having to build them from source. |
I think we can let this ferment for a few days. At least macosx wheels should not have the problem as readline is statically linked in their creation. For pkg installers, the developer just needs to first prepare universal libreadline.a and dependent libraries to allow static linking (in bldnrnmacpkgcmake.sh (that needs a new name!) perhaps we can leverage packaging/python/build_static_readline_osx.bash to do that for us). For a normal user build from sources, there is a need to modify our cmake support to make sure we don't inadvertently get libedit.3.so (or else figure out how to make that work for nrniv -python with from neuron import gui) |
Since #3239 the gui does not work on MACOSX arm64 for
nrngui -python
(either for python 3.12 or 3.13).This may not be a problem for mac wheels as the issue appears to be related to building the software such that by default libedit replaces libreadline.
Solution:
All issues for nrniv -python are resolved when using the latest master merged into hines/universal2-wheel and using the wheels. Both python-3.12 and python-3.13 work. Basically the fix is to link a static build of libreadline.a from readline-7.0 and ncurses-6.4. A default build on the mac, I believe, uses libedit instead of libreadline. I don't know why the problems are experienced with libedit.
Also note that, after building universal2 wheels on maxosx, readline and ncurses libraries are "installed" at
It then becomes possible to build with:
and one can successfully
nrngui -python
and press NEURONMainMenu/File/QuitThe text was updated successfully, but these errors were encountered: