[fpc-pascal] some problem in SVN FPC for arm linux (v 2.3.1)
Helmut Hartl
helmut.hartl at firmos.at
Fri May 4 18:37:50 CEST 2007
Hello again Henry,
> >
> > i used the "mastermakefile" to build the tool chain:
> > http://www.nslu2-linux.org/wiki/Development/MasterMakefile
> >
I followed the
http://www.nslu2-linux.org/wiki/HowTo/CrossCompileWithCentOS
Worked for me for CentOS 5, i built the slugosle 4.4 and flashed it.
Then i copy'ed the generated crosstoolchain and used it to make a
cross compileing fpc 2.3.1 from svn head.
Many thanks for your help !!
A simple "FPC only Hello World" programm compiled works perfect on the
NSLU2.
> > this is the _only_ toolchain that worked for me, since i had
> > to link against external libs. if you're writing a
> > stand-alone fpc app, you might get away by using any old binutils.
> >
But a you predicted :-( i now have problems linking against an external
library.
I want to use unit "dynlibs" to dynamically load the "libc.so.6" on the
NLSU2
(i have done this under i386 linux sucessfully)
But i get the following error:
Free Pascal Compiler version 2.3.1 [2007/05/03] for arm
Copyright (c) 1993-2007 by Florian Klaempfl
Target OS: Linux for ARM
Compiling nslu_test.lpr
Assembling nslu_test
Linking nslu_test
/usr/local/lib/fpc/2.3.1/units/arm-linux/rtl/cprt0.o: In function
`_haltproc':
: undefined reference to `_fini'
/usr/local/lib/fpc/2.3.1/units/arm-linux/rtl/cprt0.o: In function
`_haltproc':
: undefined reference to `_init'
nslu_test.lpr(6,17) Error: Error while linking
nslu_test.lpr(6,17) Fatal: There were 1 errors compiling module,
stopping
The source is:
---
program nslu_test;
{$mode objfpc}{$H+}
uses dynlibs;
begin
writeln('Hello');
end.
---
Have you again any hints for me ?
Thanks,
helmut
More information about the fpc-pascal
mailing list