Re: [fpc-pascal] shared library on arm-linux (raspberry pi)

2014-07-01 Thread Fabio Luis Girardi
Hi all!! First (tests made on ARMHF): I did tests with latest FPC, built from trunk. The trouble persists. A simple program can't load a simple shared library, both built in FPC, but my program built in FPC can load a shared library built in gcc. As Marco said, stock fpc 2.6.4 don't works on armh

Re: [fpc-pascal] shared library on arm-linux (raspberry pi)

2014-06-28 Thread Jonas Maebe
On 28/06/14 16:48, Fabio Luis Girardi wrote: I'm testing any option that appears to be useful to build a shared library. Even If the help says that is unsupported. I'm desperate :) Unsupported options are much more likely to break things than fix things. Jonas

Re: [fpc-pascal] shared library on arm-linux (raspberry pi)

2014-06-28 Thread Fabio Luis Girardi
Em 28/06/2014 09:13, "Jonas Maebe" escreveu: > > And as the FPC help says, -CD is unsupported (nor needed; it is related to the as of yet unimplemented Delphi-style dynamic packages support). > I'm testing any option that appears to be useful to build a shared library. Even If the help says that

Re: [fpc-pascal] shared library on arm-linux (raspberry pi)

2014-06-28 Thread Jonas Maebe
On 27/06/14 16:24, Fabio Luis Girardi wrote: The output of "readelf -a" with libraries built in C and FPC... The command line used to build the library in fpc is: fpc ulib.pas fpc -Cg -Xc -CD -CX library1.fpr FPC does not support PIC code for ARM in 2.6.x. Additionally, if you want PIC, then

Re: [fpc-pascal] shared library on arm-linux (raspberry pi)

2014-06-26 Thread Fabio Luis Girardi
Hi! I did more tests, with a clean raspbian image, using fpc that comes with raspbian repositories. Now I can compile a program and the shared library, but I can't load my shared library on my program, but my program can load and use a shared library built in C. Maybe a FPC bug?? No, I installed F

Re: [fpc-pascal] shared library on arm-linux (raspberry pi)

2014-06-26 Thread Fabio Luis Girardi
No, I installed FPC on Rpi using this file: http://sourceforge.net/projects/freepascal/files/Linux/2.6.4/fpc-2.6.4.arm-linux.tar Using the FPC 2.6.4, I tried build a fresh FPC 2.7.1 on Rpi, but I found the same error. So, I have to go back and install FPC from Raspibian repositories... 2014

Re: [fpc-pascal] shared library on arm-linux (raspberry pi)

2014-06-26 Thread Marco van de Voort
In our previous episode, Fabio Luis Girardi said: > Someone can say if this is a problem with my raspbian image or a problem > with my FPC installation? Did you use the raspbian provided (and patched!) FPC or did you build your own? Stock 2.6.4 does NOT run armhf systems, Raspbian patched theirs.

Re: [fpc-pascal] shared library on arm-linux (raspberry pi)

2014-06-26 Thread Fabio Luis Girardi
I did more tests. If I try build a empty program linked with libc, this program cause a linker failure as mentioned on previous message. program program1; {$LINKLIB c} begin end. Someone can say if this is a problem with my raspbian image or a problem with my FPC installation? 2014-06-25 23:

[fpc-pascal] shared library on arm-linux (raspberry pi)

2014-06-25 Thread Fabio Luis Girardi
What's the current status of dynlibs unit for Linux ARM? I'm doing a project and a shared library, both on a raspberry pi with FPC 2.6.4. I built the shared library successfully, but when I try build a empty program only with dynlibs unit on uses, the program won't compile. The output is: pi@rasp

Re: [fpc-pascal] Shared library with resources which contain bitmaps on Linux -- second try

2008-07-02 Thread Giulio Bernardi
I'm sorry to say that at the moment, there is no support for resources in shared libraries in 2.3.1 on non-windows targets: that is, you can only embed resources in the program that uses them. It is planned though. bye Giulio ___ fpc-pascal maillist

RE: [fpc-pascal] Shared library with resources which contain bitmaps on Linux -- second try

2008-06-25 Thread Tomas Hajny
On Wed, June 25, 2008 13:07, Michael Van Canneyt wrote: > On Tue, 24 Jun 2008, Tom Carly wrote: > >> > With version 2.3.1, you can try the new support for resources, >> > and it should work "out of the box". >> >> How can you obtain 2.3.1? I cannot find it in the repository... > > You can get 2.3.1

Re: [fpc-pascal] Shared library with resources which contain bitmaps on Linux -- second try

2008-06-25 Thread Jonas Maebe
On 25 Jun 2008, at 13:40, Tom Carly wrote: You can get 2.3.1 only from subversion. I don't see it in the repository, the last release that is in there is 2_2_2. 2.3.1 is not a release, it's the version number of the current main development version. So you have to check out trunk to obt

RE: [fpc-pascal] Shared library with resources which contain bitmaps on Linux -- second try

2008-06-25 Thread Tom Carly
On Tue, 24 Jun 2008, Tom Carly wrote: > > With version 2.3.1, you can try the new support for resources, > > and it should work "out of the box". > > How can you obtain 2.3.1? I cannot find it in the repository... > You can get 2.3.1 only from subversion. I don't see it in the repository, the la

RE: [fpc-pascal] Shared library with resources which contain bitmaps on Linux -- second try

2008-06-25 Thread Michael Van Canneyt
On Tue, 24 Jun 2008, Tom Carly wrote: > > With version 2.3.1, you can try the new support for resources, > > and it should work "out of the box". > > How can you obtain 2.3.1? I cannot find it in the repository... You can get 2.3.1 only from subversion. Michael. __

RE: [fpc-pascal] Shared library with resources which contain bitmaps on Linux -- second try

2008-06-25 Thread Tom Carly
> With version 2.3.1, you can try the new support for resources, > and it should work "out of the box". How can you obtain 2.3.1? I cannot find it in the repository... BR Tom ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.fre

Re: [fpc-pascal] Shared library with resources which contain bitmaps on Linux -- second try

2008-06-24 Thread Michael Van Canneyt
On Tue, 24 Jun 2008, Roland Turcan wrote: > Hello FPC-Pascal users discussions! > > How can I build a shared library which contains many bitmaps loaded > dynamically from the code using by: > > procedure TForm1.Button1Click(Sender: TObject); > CONST MYRES_DLL='./libmyres.so'; > begin > F

[fpc-pascal] Shared library with resources which contain bitmaps on Linux -- second try

2008-06-24 Thread Roland Turcan
Hello FPC-Pascal users discussions! How can I build a shared library which contains many bitmaps loaded dynamically from the code using by: procedure TForm1.Button1Click(Sender: TObject); CONST MYRES_DLL='./libmyres.so'; begin FhMod := LoadLibrary (PCHAR (MYRES_DLL)); IF FhMod = 0 THEN b

[fpc-pascal] Shared library with resources which contain bitmaps on Linux

2008-06-23 Thread Roland Turcan
Hello FPC-Pascal users discussions! How can I build a shared library which contains many bitmaps loaded dynamically from the code using by: procedure TForm1.Button1Click(Sender: TObject); CONST MYRES_DLL='./libmyres.so'; begin FhMod := LoadLibrary (PCHAR (MYRES_DLL)); IF FhMod = 0 THEN b

Re: [fpc-pascal] Shared library

2006-09-13 Thread Marc Santhoff
Am Mittwoch, den 13.09.2006, 09:34 +0200 schrieb Carsten Bager: > If I create a shared library with this source code, the lib file has a > size of 368806 bytes. Can I do anything to reduce the size. Have you tried smart linking? I don't know if it works for libraries though ... fpc -XX ... HTH,

Re: [fpc-pascal] Shared library

2006-09-13 Thread Graeme Geldenhuys
Try the 'strip' command. I know it works with executables, not sure about libraries. It is included in the FPC bin directory. eg: strip Regards, - Graeme - On 13/09/06, Carsten Bager <[EMAIL PROTECTED]> wrote: If I create a shared library with this source code, the lib file has a s

[fpc-pascal] Shared library

2006-09-13 Thread Carsten Bager
If I create a shared library with this source code, the lib file has a size of 368806 bytes. Can I do anything to reduce the size. Carsten library u; Procedure Test; Begin WriteLn('--- Test OK '); End