Re: [fpc-pascal] arm-linux, program does not start when using unit pthreads

2008-01-14 Thread Bernd Mueller

Koenraad Lelong wrote:

Bernd Mueller schreef:

Koenraad Lelong wrote:

I tried on my arm-linux board, AFAIK NOT uClibc. It works fine.

Thanks.
Are you crosscompiling? Do you use static or dynamic linking?

Regards, Bernd.


When I read you reply about linking I realised I didn't think about the
fact that the linker would remove unused units (does it, without adding
smartlining ?). Sorry about this.
I crosscompiled the program with dynamic linking, at least I didn't add
a switch for static linking. Maybe you can send me you command-line.
Dynamic linking seems to work for me now too. It was mainly a linker 
issue. Thanks.


Regards, Bernd.

___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] arm-linux, program does not start when using unit pthreads

2008-01-13 Thread Koenraad Lelong
Bernd Mueller schreef:
 Koenraad Lelong wrote:

 I tried on my arm-linux board, AFAIK NOT uClibc. It works fine.
 Thanks.
 Are you crosscompiling? Do you use static or dynamic linking?
 
 Regards, Bernd.
 
When I read you reply about linking I realised I didn't think about the
fact that the linker would remove unused units (does it, without adding
smartlining ?). Sorry about this.
I crosscompiled the program with dynamic linking, at least I didn't add
a switch for static linking. Maybe you can send me you command-line.
Regards,
Koenraad.
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] arm-linux, program does not start when using unit pthreads

2008-01-11 Thread Bernd Mueller

Koenraad Lelong wrote:


I tried on my arm-linux board, AFAIK NOT uClibc. It works fine.

Thanks.
Are you crosscompiling? Do you use static or dynamic linking?

Regards, Bernd.


___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] arm-linux, program does not start when using unit pthreads

2008-01-10 Thread Bernd Mueller

Bernd Mueller wrote:

when I try to start a simple Hello-Program, which uses the unit 
pthreads, on an arm-linux target (uClibc), I get the message not 
found. The program is crosscompiled from win32, using the fpc 2.2.0 
compiler:



program project1;
{$mode objfpc}{$H+}
uses pthreads;

begin
   Writeln('Hello');
end.

There seems to be a problem with the shared libraries. I checked the 
directory /lib for the libraries and symlinks, but the required 
libraries seem to be present.


the reason for the not found message was, that the dynamic linker on 
my target was not found. I fixed that, but I get now an Segmentation 
fault :-( I fear this one will be hard to find. Thanks.


Regards, Bernd.
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] arm-linux, program does not start when using unit pthreads

2008-01-10 Thread Koenraad Lelong
Bernd Mueller schreef:
 Bernd Mueller wrote:
 
 when I try to start a simple Hello-Program, which uses the unit
 pthreads, on an arm-linux target (uClibc), I get the message not
 found. The program is crosscompiled from win32, using the fpc 2.2.0
 compiler:
 
 program project1;
 {$mode objfpc}{$H+}
 uses pthreads;

 begin
Writeln('Hello');
 end.

 There seems to be a problem with the shared libraries. I checked the
 directory /lib for the libraries and symlinks, but the required
 libraries seem to be present.
 
 the reason for the not found message was, that the dynamic linker on
 my target was not found. I fixed that, but I get now an Segmentation
 fault :-( I fear this one will be hard to find. Thanks.
 
 Regards, Bernd.

I tried on my arm-linux board, AFAIK NOT uClibc. It works fine.
Regards,
Koenraad.
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


[fpc-pascal] arm-linux, program does not start when using unit pthreads

2008-01-09 Thread Bernd Mueller

Hello,

when I try to start a simple Hello-Program, which uses the unit 
pthreads, on an arm-linux target (uClibc), I get the message not 
found. The program is crosscompiled from win32, using the fpc 2.2.0 
compiler:


program project1;
{$mode objfpc}{$H+}
uses pthreads;

begin
   Writeln('Hello');
end.

There seems to be a problem with the shared libraries. I checked the 
directory /lib for the libraries and symlinks, but the required 
libraries seem to be present.


ldd project1
checking sub-depends for '/lib/libpthread.so.0'
checking sub-depends for '/lib/libc.so.0'
libpthread.so.0 = /lib/libpthread.so.0 (0x)
libc.so.0 = /lib/libc.so.0 (0x)
/lib/ld-uClibc.so.0 = /lib/ld-uClibc.so.0 (0x)

Then I compiled a gcc Hello-program with the library pthread linked 
in. This program runs fine. This is the ldd output:


ldd p
libpthread.so.0 = /lib/libpthread.so.0 (0x4000e000)
libgcc_s.so.1 = /lib/libgcc_s.so.1 (0x40028000)
libc.so.0 = /lib/libc.so.0 (0x40038000)
ld-uClibc.so.0 = /lib/ld-uClibc.so.0 (0x4000)

I am also wondering about the differences in the address fields of the 
ldd ouput. All fpc address fields are set to 0x, while the gcc 
address fields have different values.


Thank you for any hints and pointers.

Regards, Bernd.
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal