Monday, 2 December 2019

macos - Symlinking executable surrounded with dylib not working


The executable


$ /Applications/Mathematica.app/Contents/MacOS/WolframKernel

works fine:


Mathematica 10.0 for Mac OS X x86 (64-bit)
Copyright 1988-2014 Wolfram Research, Inc.

In[1]:=

However if I symlink it under math in /usr/local/bin (or if I add /Applications/Mathematica.app/Contents/MacOS/ to PATH), then I get the following error :


$ math
dlopen(/SystemFiles, 1): image not found

In its directory, MathKernel is surrounded with dylib files, so I believe it's the cause of the error. But then I thought adding a directory to PATH would avoid this kind of problem.


Running OSX Yosemite 10.10.3



Answer



I have the same problem creating a symbolic link to Mathematica.


Try to use an alias like this:


alias math="/Applications/Mathematica.app/Contents/MacOS/MathKernel"

No comments:

Post a Comment

How can I VLOOKUP in multiple Excel documents?

I am trying to VLOOKUP reference data with around 400 seperate Excel files. Is it possible to do this in a quick way rather than doing it m...