libXmu.so.6 and libgthread-2.0.so.0 error, or getting Wolfram CDF Player working on Ubuntu
Recently a colleague sent me some information on his model and a bunch of Mathematica .nb
files. I don’t use Mathematica (if I felt the need for that kind of thing I’d go for Sage) and I don’t have access to it, so I started looking around for a way to export the notebook, say to pdf.
I found an online nb to pdf converter hosted by Wolfram called NBtoPDF, so I uploaded the smallest file (quite a few M) while I kept searching for a solution.
I’m glad I did keep searching, because after a good deal of time the converter returned “Error uploading file” and that was the end of that.
It seems that over time Wolfram has released a few different reader and converter programs, like Mathreader and Mathematica Player, which seem to be differently-abled versions of Mathematica. All urls now lead to Wolfram CDF Player, which is available for Linux, but not with browser capability. I downloaded it and installed it
and gave it go:
Hrm.
I checked out the Official Forums for any Linux related stuff, and the first thread I came across had an Official Forum Moderator advising one student:
If you have the stand-alone CDF Player and cannot open and run CDF
files in it, contact Wolfram Technical Support at support@wolfram.com.
lol.
Then on the Ubuntu forums I found this post:
It looks like that MathematicaPlayerPro is a pure 32bit
application (according to WRI-support). Just doing:
sudo apt-get install ia32-libs
fixes the issue.
Rolf
So I did an apt-get install ia32-libs
, and retried invoking the Mathematica CDF Player:
Well I guess that’s progress.
I came across another message on the Official Wolfram Forums suggesting that the solution to the missing libXmu.so.6
library problem was to install libxmu-dev
. Perhaps that install had something extra? But no, I tried it on top of what I did before and still the libgthread-2.0.so.0: cannot open shared object file
problem persisted.
Both threads however mentioned the 32-bit library issue, that CDF Player uses that instead of the 64-bit types. I took a look in /usr/lib/
and I could see both libXmu.so.6
and libgthread-2.0.so.0
, but in /usr/lib32
the offending libgthread-2.0.so.0
library was missing.
A search landed me on this Debian bugs thread, where one user writes:
my ia32-libs creates a symlink /emul/ia32-linux/usr/lib/libgthread-2.so pointing to libgthread-2.0.so.0 in the same directory, but this file is missing
That vaguely sounded like my problem. Another replied:
The link is in the wrong packages. It belongs in ia32-libs-gtks. But if you install ia32-libs-gtk as well it will work.
So I tried
and success. I was then able to run it and open the notebook files.
The final experiment was to see if I could export the notebooks to pdf to make checking equations quicker. The GUI menu has a print to pdf option. Using evince to open it I got:
but evince managed to work around whatever error CDF Player had put in the file and I could read it just fine.