Services & Resources / Wolfram Forums
-----
 /
MathGroup Archive
1996
*January
*February
*March
*April
*May
*June
*July
*August
*September
*October
*November
*December
*Archive Index
*Ask about this page
*Print this page
*Give us feedback
*Sign up for the Wolfram Insider

MathGroup Archive 1996

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

Search the Archive

Re: MathLink in C++

  • To: mathgroup at smc.vnet.net
  • Subject: [mg3129] Re: MathLink in C++
  • From: evans at gte.net (Mark Evans)
  • Date: Tue, 6 Feb 1996 22:48:24 -0500
  • Organization: GTE Intelligent Network Services, GTE INS
  • Sender: owner-wri-mathgroup at wolfram.com

In article <4ept6f$jk0 at dragonfly.wri.com>, sherod at boussinesq.Colorado.EDU
(Scott Herod) wrote:

> I'm trying to learn to use MathLink at the some time I'm trying
> to learn C++.  Anyway, on our sparc20 running Solaris2.3 I am having
> trouble with the mprep routine.  It appears that we have mprep
> version 2.2.2 which accepts a -prototypes flag but which by no means
> is writing code which our C++ or g++ will compile.
> 
> Is there a more recent version of mprep for Suns which can write 
> C++ or should I give up on C++ for awhile?
> 
> Scott Herod

This may not help, but remember to declare all the MathLink calls "extern
C" so that the compiler and linker will know how to treat them.

MathLink expects to call C functions, not C++ functions.  Much of the
functionality of C++ arises from behind-the-scenes compiler maneuvers, so
that, for example, function names become something other than what you
declared them to be.

Just something to check.

Mark Evans

==== [MESSAGE SEPARATOR] ====


  • Prev by Date: Notebo0k==>>>TeX
  • Next by Date: Re: MathLink in C++
  • Previous by thread: MathLink in C++
  • Next by thread: Re: MathLink in C++