SuSE GmbH

SuSE Support-Datenbank

Titel: Mathematica: Template-Compiler

----------

Übersicht o Stichwortsuche o History o Versionen o Kategorien o Alle Artikel
English

----------

Mathematica: Template-Compiler

Bezieht sich auf

SuSE Linux: Version 4.2
Mathematic: Version 2.2.4

Symptom:

Nach der Installation steht unter /usr/local/bin/mcc der MathLink Template-Compiler zur Verfügung. Dieses Script wird benötigt, um Mathematica Template Files (*.tm) vorzuverarbeiten und an den C-Compiler weiterzureichen.

Dieser funktioniert leider so nicht.

Ursache:

Da die beim Linken benoetigte MathLink Library libML.a im a.out Format vorliegt (zumindest bei mir, Mathematica fuer Linux 2.2.4), muss auf einem ELF System der C-Aufruf (ziemlich am Schluss in mcc) fuer a.out Complieren und Linken umgeschrieben werden.

Lösung:

Im File:
   cc $outfile -I$mlinclude $passtocc -L$mllibrary ... 
wird
   cc $outfile -b i486-linuxaout -I$mlinclude $passtocc -L$mllibrary
Ein diff-patch liegt bei. ACHTUNG: Wo "mcc" steht, ist installationsabhängig.

Patch:

*** /usr/local/bin/mcc.orig	Mon Aug  5 15:21:48 1996
--- /usr/local/bin/mcc	Mon Aug  5 15:20:32 1996
***************
*** 69,77 ****
     mlteddotofiles="$mlteddotofiles $mloutfile.o"
     passtocc="$passtocc $mloutfile.c"
  fi
  
!    cc $outfile -I$mlinclude $passtocc -L$mllibrary -lML -lm -DSTANDALONEMLINK
  
  if [ ".$mloutfile" != "." ] ; then
      if [ ".$debug" = "." ] ; then
        rm -f $mloutfile.c
--- 69,77 ----
     mlteddotofiles="$mlteddotofiles $mloutfile.o"
     passtocc="$passtocc $mloutfile.c"
  fi
  
!    cc $outfile -b i486-linuxaout -I$mlinclude $passtocc -L$mllibrary -lML -lm -DSTANDALONEMLINK
  
  if [ ".$mloutfile" != "." ] ; then
      if [ ".$debug" = "." ] ; then
        rm -f $mloutfile.c

Credits:

Dieser Bug wurde uns freundlicherweise beschrieben und gelöst von:

Albrecht Gebhardt
Institut fuer Mathematik
Universitaet Klagenfurt

----------

Siehe auch:

----------

Stichwörter:

----------

Übersicht o Stichwortsuche o History o Versionen o Kategorien o Alle Artikel
English

----------

SDB-mathematica2, Copyright SuSE GmbH, Nuremberg, Germany - Version: 08. Aug 1996
SuSE GmbH - Zuletzt generiert: 23. Nov 1999 16:45:04 by snbarth with sdb_gen 1.00.0