Sign in Join

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

Mailing lists / fpc-other / 2009-07

FPCUnit, DUnit2 and JUnit licenses question

10 messages · 3 people ·

Reply by email Subscribe to this list Your subscription

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

Graeme Geldenhuys

Hi,

Michael Van Canneyt told me that we cannot include DUnit2 into the FPC source code tree, replacing FPCUnit (if we wanted to do that). The reason being that DUnit2 is developed under the MPL license which is incompatible with the GPL or LGPL license used by FPC.

Well here is a question.

FPCUnit is a port of JUnit
DUnit is a port of JUnit
DUnit2 is also a port of JUnit (it's a fork from DUnit with many parts totally rewritten)

In all these projects it is clearly stated in the headers that they derived from JUnit. So what licenses is JUnit distributed with? From their website, it is the "Common Public License".

http://junit.sourceforge.net/cpl-v10.html

So how does CPL compare to GPL and MPL. Shouldn't FPCUnit, DUnit and DUnit2 also use CPL license then? They are derived work are they not? [...then again, I have no knowledge about the CPL license...]

If so, is FPCUnit actually allowed in the FPC source tree? If it may, then maybe DUnit2's MPL license is actually invalid and should have been CPL instead, which ultimately means DUnit2 could also be bundled in the FPC source tree.

Or maybe CPL is incompatible with (L)GPL and none of the 3 products may actually be bundled with FPC? I have no clue.

Anybody got some thoughts on this?

Regards,
- Graeme -

fpGUI Toolkit - a cross-platform GUI toolkit using Free Pascal http://opensoft.homeip.net/fpgui/

Reply by email

Graeme Geldenhuys
to Graeme Geldenhuys
Graeme Geldenhuys wrote 6 lines
In all these projects it is clearly stated in the headers that they derived from JUnit. So what licenses is JUnit distributed with? From their website, it is the "Common Public License". http://junit.sourceforge.net/cpl-v10.html

And here is IBM's FAQ on the CPL license.

http://www.ibm.com/developerworks/library/os-cplfaq.html

And Wikipedia's take on the CPL

http://en.wikipedia.org/wiki/Common_Public_License

Regards,
- Graeme -

fpGUI Toolkit - a cross-platform GUI toolkit using Free Pascal http://opensoft.homeip.net/fpgui/

Reply by email

Jonas Maebe
to Graeme Geldenhuys: Michael Van Canneyt told me that we cannot include DUnit2 into the FPC source code tree,…
Graeme Geldenhuys wrote
Or maybe CPL is incompatible with (L)GPL and none of the 3 products may actually be bundled with FPC?

The CPL is not compatible with the (L)GPL: http://www.gnu.org/philosophy/license-list.html#CommonPublicLicense10

So unless the authors of both JUnit and DUnit gave permission to also distribute their code under the modified LGPL, fpcunit cannot be distributed under that license.

In general, packages should indeed be licensed under the modified LGPL for them to be distributed with FPC, but maybe an exception could be made for a unit testing framework. After all, you seldom distribute unit tests, so the license is of minor importance. But if fpcunit cannot be licensed under the modified LGPL, then the license headers in its source code definitely have to be changed.

Jonas

(CC'ing Michael, since he's not subscribed to fpc-other; Michael, Graeme's original message can be found here: http://lists.freepascal.org/lists/fpc-other/2009-July/000300.html )

Reply by email

Graeme Geldenhuys
to Jonas Maebe
Jonas Maebe wrote 5 lines
> Or maybe CPL is incompatible with (L)GPL and none of the 3 products > may actually be bundled with FPC? The CPL is not compatible with the (L)GPL: http://www.gnu.org/philosophy/license-list.html#CommonPublicLicense10

Correct, the IBM FAQ on CPL also states that the CPL is incompatible with (L)GPL.

So unless the authors of both JUnit and DUnit gave permission to also distribute their code under the modified LGPL, fpcunit cannot be distributed under that license.

But was FPCUnit allowed to use a different license? I'm trying to track down information regarding "derived work" where the original code was CPL. I haven't found anything yet.

made for a unit testing framework. After all, you seldom distribute unit tests, so the license is of minor importance.

Good to know.

(CC'ing Michael, since he's not subscribed to fpc-other; Michael, Graeme's original message can be found here: http://lists.freepascal.org/lists/fpc-other/2009-July/000300.html )

Thanks Jonas. I wasn't sure if this message thread should have been in FPC-devel or not. So I instead opted for fpc-other to be safe. But yeah, I don't know how many developers are subscribed to fpc-other.

Regards,
- Graeme -

fpGUI Toolkit - a cross-platform GUI toolkit using Free Pascal http://opensoft.homeip.net/fpgui/

Reply by email

Michael Van Canneyt
to Jonas Maebe: The CPL is not compatible with the (L)GPL: http://www.gnu.org/philosophy/license-list.html…

Hi,

The FPCunit implementation is compatible to JUnit, and was later made compatible to DUnit, but - to my knowledge - does not contain any code from either of those projects.

FPCunit was implemented from scratch by Dean Zobec, and he gave it to the FPC team with the permission to distribute it under the LGPL license.

Michael.

Jonas Maebe wrote 26 lines
On 21 Jul 2009, at 11:28, Graeme Geldenhuys wrote: > Or maybe CPL is incompatible with (L)GPL and none of the 3 products may > actually be bundled with FPC? The CPL is not compatible with the (L)GPL: http://www.gnu.org/philosophy/license-list.html#CommonPublicLicense10 So unless the authors of both JUnit and DUnit gave permission to also distribute their code under the modified LGPL, fpcunit cannot be distributed under that license. In general, packages should indeed be licensed under the modified LGPL for them to be distributed with FPC, but maybe an exception could be made for a unit testing framework. After all, you seldom distribute unit tests, so the license is of minor importance. But if fpcunit cannot be licensed under the modified LGPL, then the license headers in its source code definitely have to be changed. Jonas (CC'ing Michael, since he's not subscribed to fpc-other; Michael, Graeme's original message can be found here: http://lists.freepascal.org/lists/fpc-other/2009-July/000300.html )

Reply by email

Graeme Geldenhuys
to Michael Van Canneyt
Michael Van Canneyt wrote
FPCunit was implemented from scratch by Dean Zobec, and he gave it to

So porting a project (even to point where it shows exact same behaviour or not) to a different language does not constitute as "derivative work"? I would have thought it is still derivative work. Considering that even the Money example from JUnit was ported to FPCUnit.

If FPCUnit is deemed derivative work, that would mean it must still use the CPL license, not so?

Regards,
- Graeme -

fpGUI Toolkit - a cross-platform GUI toolkit using Free Pascal http://opensoft.homeip.net/fpgui/

Reply by email

Jonas Maebe
to Graeme Geldenhuys: So porting a project (even to point where it shows exact same behaviour or not) to a…
Graeme Geldenhuys wrote 6 lines
Michael Van Canneyt wrote: > FPCunit was implemented from scratch by Dean Zobec, and he gave it to So porting a project (even to point where it shows exact same behaviour or not) to a different language does not constitute as "derivative work"?

It does, but "implementation from scratch" "porting". Software interfaces/APIs cannot be copyrighted (at least not in the US, see http://www.eetimes.com/news/design/showArticle.jhtml?articleID=201801579 ), so writing a different implementation for an existing API does not constitute creating a derivative work.

I would have thought it is still derivative work. Considering that even the Money example from JUnit was ported to FPCUnit.<

Maybe the Money example should be under CPL (if it was distributed like that).

Jonas

Reply by email

Graeme Geldenhuys
to Jonas Maebe
Jonas Maebe wrote
It does, but "implementation from scratch" "porting".

And here follows the words from Dean Zobec himself. It was a discussion between him and myself on the fpc-pascal mailing list dated 2007-05-27.

======================
...
FPCUnit has a different structure then DUnit, is a literal port of the JUnit test framework, with only some changes that were required to adapt the Java code (callbacks instead of inner classes in some places iirc). TTest is an abstract class, TTestSuite is a composite pattern. Just look at the JUnit documentation, here you can find a UML diagram:

http://junit.sourceforge.net/doc/cookstour/cookstour.htm

and there is a good chapter available as an MIT Lecture on OOP and patterns that takes the JUnit framework as a Case Study: http://courses.csail.mit.edu/6.170/old-www/2001-Fall/lectures/lecture-17.pdf

I choose to adhere strictly to the JUnit framework as it was a standard when the FPCUnit port was created, and no additional documentation of the framework was needed (you could always refer to the JUnit documentation and practice, a lot of articles and books were written on the subject).

Still, it's not a good excuse for lack of documentation :)

Regards,
Dean
======================

Extract from the fpc-pascal archives...
http://lists.freepascal.org/lists/fpc-pascal/2007-May/013811.html

In that quoted piece he mentions twice that FPCUnit is a port of JUnit. Maybe we should silently delete that message from the mailing list archives. ;-) [...and once read, this message will self-destruct in 10 seconds...]

Regards,
- Graeme -

fpGUI Toolkit - a cross-platform GUI toolkit using Free Pascal http://opensoft.homeip.net/fpgui/

Reply by email

Graeme Geldenhuys
to Graeme Geldenhuys
Graeme Geldenhuys wrote 6 lines
Jonas Maebe wrote: > It does, but "implementation from scratch" "porting". Extract from the fpc-pascal archives... http://lists.freepascal.org/lists/fpc-pascal/2007-May/013811.html

We will have to delete this one as well, from the fpc-devel mailing list. ;-)

http://lists.freepascal.org/lists/fpc-devel/2009-May/016835.html

Regards,
- Graeme -

fpGUI Toolkit - a cross-platform GUI toolkit using Free Pascal http://opensoft.homeip.net/fpgui/

Reply by email