help-octave
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Porting Octave to MacOSX


From: Per Persson
Subject: Re: Porting Octave to MacOSX
Date: Thu, 22 Mar 2001 16:32:40 +0100

On torsdag, mars 22, 2001, at 02:45 , John W. Eaton wrote:

On 22-Mar-2001, Per Persson <address@hidden> wrote:

| First the good news: CVS version of Octave compiles nicely under MacOSX
| (post-beta with the latest set of tools). Replacing config.guess and
| config.sub and running autogen.sh works smoothly. The only hack needed
| is replacing ":" with \":\" in oct-conf.h.

Where? Can you please explain why this is needed? What error message
did you encounter that prompted the change?


c++ -c -I. -I.. -I../liboctave -I../src -I../libcruft/misc -I../glob -I../glob -DHAVE_CONFIG_H -fno-implicit-templates -g -O2 -Wall toplev.cc -o toplev.o
toplev.cc: In function `class octave_value_list Foctave_config_info(const octave_value_list &, int)':
toplev.cc:674: parse error before `:'
toplev.cc:675: parse error before `:'

In toplev.cc:674-675
m ["UGLY_DEFS"] = OCTAVE_CONF_DEFS;
m ["UGLY_DEFS"] = OCTAVE_CONF_UGLY_DEFS;

from oct-conf.h
#ifndef OCTAVE_CONF_DEFS
#define OCTAVE_CONF_DEFS "-DOCTAVE_SOURCE=1 -DSEPCHAR=':' -DSEPCHAR_STR=":" -DU
...
#ifndef OCTAVE_CONF_UGLY_DEFS
#define OCTAVE_CONF_UGLY_DEFS "-DOCTAVE_SOURCE=1 -DSEPCHAR=':' -DSEPCHAR_STR=":" -DUSE_READLINE=1 -D__NO\

Its the -DSEPCHAR_STR=":" that needs to be changed to -DSEPCHAR_STR=\":\"
Apparently the same fix is needed for MachTen according to the README.MachTen file.


| Bad news: in the final linking stage a number of symbols are undefined
| (NOT related to link errors in previous versions of OSX). The usual
| suspect here is a peculiarity with apple's linker where a symbol has to
| be requested before it is defined, otherwise it will be disposed of.
| However, I couldn't find any of the missing symbols _anywhere_ which
| means the problem could be something else.

Did you search .o files? They are mangled symbol names. You'll
probably need to use something like

for f in *.o ; do echo $f ; nm $f | grep get_size__Ct6Array21Zcii ; done

to find them.

I searched the *.o files with nm -o and couldn't find the missing symbols. e.g.:

[:~/Develop/octave/liboctave] % nm -arch all -o *.o | grep get_size__Ct6Array21Zcii
Array-ch.o:00006640 S __Q2t6Array21Zc26get_size__Ct6Array21Zcii.0.MALLOC_OVERHEAD
Array-ch.o:00000004 C __Q2t6Array21Zc26get_size__Ct6Array21Zcii.1.nl
Array-ch.o:00000008 C __Q2t6Array21Zc26get_size__Ct6Array21Zcii.2.dl
Array-ch.o:00000004 C __Q2t6Array21Zc26get_size__Ct6Array21Zcii.3.max_items
Array-ch.o:000014bc S _get_size__Ct6Array21Zcii
MArray-ch.o: U _get_size__Ct6Array21Zcii
chMatrix.o: U _get_size__Ct6Array21Zcii

I could be missing something here. I've only used the gcc/Unix combo the last couple of months...

/Per


reply via email to

[Prev in Thread] Current Thread [Next in Thread]