MathGroup Archive 1999

[Date Index] [Thread Index] [Author Index]

Search the Archive

Compiling Mathlink Module under Redhat 6.0

  • To: mathgroup at
  • Subject: [mg17957] Compiling Mathlink Module under Redhat 6.0
  • From: ottffss <ottffss at>
  • Date: Mon, 7 Jun 1999 02:51:17 -0400
  • Sender: owner-wri-mathgroup at

I just finished installing Mathematica 4.0 on my Redhat 6.0 Linux
system.  I compiled the mathlink examples (addtwo etc.) and when I try
to run them I get:

link = Install[
    LinkMode -> Launch]

LinkConnect::"linkc": \
MathLinkExamples/addtwo'\", 2, 2\)\)]\) is dead; attempt to connect


However, when I link against the prebuilt addtwo that shipped with
Mathematica 4.0, everything works fine.  Furthermore, Mathlink modules
which I compiled under Redhat 4.2 work fine.

So I appear to be able to run old Mathlink executables and prebuilt
executables from Wolfram, but modules compiled under RedHat 6.0 will not

I have several Mathematica Licenses and I've installed one of them on
another computer running RedHat 5.2 Linux.  Everything works fine there:
old Mathelink modules, Prebuilt Examples shipped with Mathematica 4.0,
and modules compiled under Redhat 5.2.

I've downloaded the latest Mathlink software from Wolfram (the one which
is glibc 2.0 compatible) just in case it shipped with a non glibc ML
library.  I get the same results cited above.

I think that my problem goes back to an incompatibility between the
libraries that the ML library will link with.  If I check the libraries
against which my RH60 compiled modules will link I get:
[msh at localhost MathLinkExamples]$ ldd addtwo => /lib/ (0x4001a000) => /lib/ (0x40036000)
 /lib/ => /lib/ (0x40000000)
[msh at localhost MathLinkExamples]$

The prebuild examples however, link against:
[msh at localhost PrebuiltExamples]$ ldd addtwo => /usr/i486-linux-libc5/lib/ (0x4000e000) => /usr/i486-linux-libc5/lib/ (0x40016000)
[msh at localhost PrebuiltExamples]$
(By the way, these libraries are installed with RH 6.0, but they're in
/usr/i486-linux-libc5/lib/.  I think this is why the old and prebuilt
modules work.)

I've called Wolfram tech support with this question and their
preliminary position is that I should be able to compile and run
mathlink modules under Redhat 6.0.  Has anyone out there been able to do
this.  If so, would you mind sending me a makefile showing exactly how
you did it?

I suspect that the current MathLink libraries are glibc2.0 compatible,
while RedHat 6.0 is based on glibc2.1.

  • Prev by Date: Aborting execution -- a hard stop
  • Next by Date: Re: need help hiding display formulas
  • Previous by thread: Aborting execution -- a hard stop
  • Next by thread: need to plot an arc