Sign in Join

Live chat for Free Pascal, Lazarus, Delphi and every Pascal programmer.

Mailing lists / fpc-pascal / 2008-07

Complying with LGPL using FPC

5 messages · 4 people ·

Reply by email Subscribe to this list Your subscription

Read-only archive. Use j and k to move between messages.

Vladimir Zhirov

Hi,

Would you please help me to find out the steps I should follow to comply with LGPL if my application is built using FPC and uses pascal source code of LGPL'ed library?

Section 4 of LGPL requires to

Show quoted text 7 lines
d) Do one of the following: 0) Convey the Minimal Corresponding Source under the terms of this License, and the Corresponding Application Code in a form suitable for, and under terms that permit, the user to recombine or relink the Application with a modified version of the Linked Version to produce a modified Combined Work, in the manner specified by section 6 of the GNU GPL for conveying Corresponding Source.

Suppose application and library files are:

project1.pas
project1.o
project1.compiled
lgpled_lib.pas
lgpled_lib.o
lgpled_lib.ppu

What files I must make public, and how people are supposed to use them in order to relink my application with newer/modified version of the library?

Thanks in advance.

Best regards, Vladimir

Reply by email

Tomas Hajny
to Vladimir Zhirov

On Fri, July 4, 2008 18:15, Vladimir Zhirov wrote:

Hi,

Show quoted text 26 lines
Would you please help me to find out the steps I should follow to comply with LGPL if my application is built using FPC and uses pascal source code of LGPL'ed library? Section 4 of LGPL requires to > d) Do one of the following: > 0) Convey the Minimal Corresponding Source under the terms of this > License, and the Corresponding Application Code in a form suitable for, > and under terms that permit, the user to recombine or relink > the Application with a modified version of the Linked Version > to produce a modified Combined Work, in the manner specified > by section 6 of the GNU GPL for conveying Corresponding Source. Suppose application and library files are: project1.pas project1.o project1.compiled lgpled_lib.pas lgpled_lib.o lgpled_lib.ppu What files I must make public, and how people are supposed to use them in order to relink my application with newer/modified version of the library?

I believe that one of the ways would be compiling lgpled_lib.pas into a shared library/DLL and having it linked to your program dynamically, another solution would be providing interested users with all the required object files (*.o), libraries (.a) and a linker script. The linker script is created and preserved if compiling with -s parameter, all the required .o and .a files are listed in that script.

Tomas

Reply by email

Jonas Maebe
to Vladimir Zhirov: Would you please help me to find out the steps I should follow to comply with LGPL if my…
Vladimir Zhirov wrote 12 lines
Suppose application and library files are: project1.pas project1.o project1.compiled lgpled_lib.pas lgpled_lib.o lgpled_lib.ppu What files I must make public, and how people are supposed to use them in order to relink my application with newer/modified version of the library?

Compile the program with -Cn.

Then supply the users with all .o files referenced from the generated link.res file (including those from the rtl/flc/packages/...), as well as with the link.res file itself and the generated ppas.sh/ppas.bat file.

Or, as Tomas mentioned, you can also use the LGPL code as a shared library. In that case the linking is done by the dynamic linker, and you don't have to distribute the parts of your program as linkable components.

Jonas

Reply by email

Vladimir Zhirov
Tomas Hajny wrote 6 lines
I believe that one of the ways would be compiling lgpled_lib.pas into a shared library/DLL and having it linked to your program dynamically, another solution would be providing interested users with all the required object files (*.o), libraries (.a) and a linker script. The linker script is created and preserved if compiling with -s parameter, all the required .o and .a files are listed in that script.

Thanks for the solution, Tomas.

Felipe Monteiro de Carvalho wrote
Which library are you using that is LGPL?

It is Pascal Data Objects (http://pdo.sourceforge.net/index.shtml). This library is derived from ZeosLib, so it is covered by LGPL. I'm not actually using it, just examining the possibility of its use.

Best regards, Vladimir

Reply by email