UnixLib with the Castle tools

John Tytgat John.Tytgat at aaug.net
Thu Feb 16 01:21:02 PST 2006


In message <042e00fa4d.pittdj+ at pittdj.plus.com>
          David Pitt <pittdj at pittdj.co.uk> wrote:

> Hi,
> 
> I am trying to use UnixLib with the Castle C/C++. There is no great 
> reason for this other than that it is there and should be good 
> "learning curve". How to do it is in !UnixLib.!Help. Using UnixLib 4.3 
> that is with gcc 3.4.5 release 1 I get these errors compiling a simple 
> "Hello world".
> 
> Norcroft RISC OS ARM C vsn 5.64 [01 Feb 2006] (David_Pitt)
> ARM Linker: (Error) Undefined symbol(s).
> ARM Linker:     ___arm_alloca_alloc, referred to from 
> UnixLib:o.unixlib(o).
> ARM Linker:     __muldi3, referred to from UnixLib:o.unixlib(o).
> ARM Linker: Errors in link, no output generated.
> ARM Linker: finished,  3 informational, 0 warning and 1 error 
> messages.
> 
> With an earlier UnixLib 4.0 from gcc 2.95.4 the linking completes and 
> a working absolute results.

These GCC symbols are normally found in the libgcc library.  I really
wouldn't recommend link a GCC compiled UnixLib with Norcroft object
files because their float argument passing is differnt.  Something I
worked around in the libscl stubs we have.

I think you better recompile UnixLib yourself with Norcroft and use
that.

> I have seen this subject in archived posts where some source changes 
> are suggested. At this point my enthusiasm collided with my ignorance. 
> How do I compile UnixLib. Setting the directory with the MakeFile to 
> be current I get no further than this :-
> 
> *make
> Makefile:1050: *** target pattern contains no `%'.  Stop.

I used to do this myself for a long time but it has been a while since I
last did this myself.  I assume you created unixlib/objs/Makefile like
mentioned in the 'Building' section of UnixLib doc ? And the make you are
using is the GNU make ? Or the Castle amu/make ?

John.
-- 
John Tytgat, in his comfy chair at home                                 BASS
John.Tytgat at aaug.net                             ARM powered, RISC OS driven




More information about the gcc mailing list