A few thoughts about GPL and likes

Discussion of anything and everything relating to chess playing software and machines.

Moderator: Ras

User avatar
rhollay
Posts: 150
Joined: Wed Mar 08, 2006 8:26 pm

A few thoughts about GPL and likes

Post by rhollay »

These days there have been several debates about GPL, identical - equivalent - similar code in two programs,
how many code lines can be copy-pasted without violating GPL, etc.

Having been a programmer (not involved in chess programming) myself in past, just a few words about the topic.

The question is: is it possible for two independent programs to have identical (or equivalent or very similar) code snippets,
let's say a few hundred lines, without violating a license?

In my opinion it's possible. Easily.

1. There are many books, e-books about programming with examples, free code snippets for everyone, tutorials, other publications on internet,
even open-source programs not under GPL, so that everybody who reads them can copy-past several hundreds of lines of code very easily.
I suppose there are such publications about chess programming also...

What if somebody picks up let's say some sorting algorithm from one of the above mentioned free sources, uses it in his GPL-ed program,
while at the same time I use the same code snippets in my commercial program? Have I violated GPL?
On the other side, how can somebody who publishes under GPL prove that each line of program code is his own original work, so that nobody
is allowed to use them without publishing the sources?

2. Let's suppose that I have a closed-source program just being developed by me and some other programmers. One of them leaves the team,
and gives away parts of code to somebody else who is just writing an open-source program under GPL. He uses parts of my code and publishes
the sources under GPL, but I don't, because my program is closed-source.

Have I violated GPL? How can I prove that code snippets are mine, and not copy-pasted from his GPL-ed program?

One can find many other scenarios where two programs can have identical parts, still nobody violates GPL, at least not intentionally.
chrisw

Re: A few thoughts about GPL and likes

Post by chrisw »

What means the GPL really, in practice?

A programmer dcides he wants to release his source ideas, maybe he likes the concept that others will go on and develop his work furtjher. If he just slings the source out into cyberspace, anybody can do anything, there's no control at all. Programmer probably doesn't like this, doesn't want his work turned immediately into commercial products or seized as someone else's work, so he hunts around for something suitable. GPL springs up. GPL offers him the opportunity to pretty much decide case by case whether he is ok or not with what happens with his source.

rhollay wrote:These days there have been several debates about GPL, identical - equivalent - similar code in two programs,
how many code lines can be copy-pasted without violating GPL, etc.

Having been a programmer (not involved in chess programming) myself in past, just a few words about the topic.

The question is: is it possible for two independent programs to have identical (or equivalent or very similar) code snippets,
let's say a few hundred lines, without violating a license?

In my opinion it's possible. Easily.

1. There are many books, e-books about programming with examples, free code snippets for everyone, tutorials, other publications on internet,
even open-source programs not under GPL, so that everybody who reads them can copy-past several hundreds of lines of code very easily.
I suppose there are such publications about chess programming also...

What if somebody picks up let's say some sorting algorithm from one of the above mentioned free sources, uses it in his GPL-ed program,
while at the same time I use the same code snippets in my commercial program? Have I violated GPL?
On the other side, how can somebody who publishes under GPL prove that each line of program code is his own original work, so that nobody
is allowed to use them without publishing the sources?

2. Let's suppose that I have a closed-source program just being developed by me and some other programmers. One of them leaves the team,
and gives away parts of code to somebody else who is just writing an open-source program under GPL. He uses parts of my code and publishes
the sources under GPL, but I don't, because my program is closed-source.

Have I violated GPL? How can I prove that code snippets are mine, and not copy-pasted from his GPL-ed program?

One can find many other scenarios where two programs can have identical parts, still nobody violates GPL, at least not intentionally.
User avatar
Bo Persson
Posts: 260
Joined: Sat Mar 11, 2006 8:31 am
Location: Malmö, Sweden
Full name: Bo Persson

Re: A few thoughts about GPL and likes

Post by Bo Persson »

rhollay wrote:These days there have been several debates about GPL, identical - equivalent - similar code in two programs,
how many code lines can be copy-pasted without violating GPL, etc.
None. :-)

A copyright violation occurs when you do an unauthorized copy of something protected.


The rest is a matter of evaluating the evidence. Most of us can write lines like

int i = 0;

independently, so finding that in code doesn't prove anything.

On the other hand, if you find hundreds of lines of identical code, including misspelled comments, you have a very strong case.


Bo Persson
User avatar
rhollay
Posts: 150
Joined: Wed Mar 08, 2006 8:26 pm

Re: A few thoughts about GPL and likes

Post by rhollay »

Bo Persson wrote:
rhollay wrote:These days there have been several debates about GPL, identical - equivalent - similar code in two programs,
how many code lines can be copy-pasted without violating GPL, etc.
None. :-)

A copyright violation occurs when you do an unauthorized copy of something protected.


The rest is a matter of evaluating the evidence. Most of us can write lines like

int i = 0;

independently, so finding that in code doesn't prove anything.

On the other hand, if you find hundreds of lines of identical code, including misspelled comments, you have a very strong case.


Bo Persson
OK, Bo. But the question was which came first, the chicken or the egg?
How can you prove that all code in your GPL-ed program is your original work so that nobody can use them in a closed-source program?
User avatar
tiger
Posts: 819
Joined: Sat Mar 11, 2006 3:15 am
Location: Guadeloupe (french caribbean island)

Re: A few thoughts about GPL and likes

Post by tiger »

rhollay wrote:
Bo Persson wrote:
rhollay wrote:These days there have been several debates about GPL, identical - equivalent - similar code in two programs,
how many code lines can be copy-pasted without violating GPL, etc.
None. :-)

A copyright violation occurs when you do an unauthorized copy of something protected.


The rest is a matter of evaluating the evidence. Most of us can write lines like

int i = 0;

independently, so finding that in code doesn't prove anything.

On the other hand, if you find hundreds of lines of identical code, including misspelled comments, you have a very strong case.


Bo Persson
OK, Bo. But the question was which came first, the chicken or the egg?
How can you prove that all code in your GPL-ed program is your original work so that nobody can use them in a closed-source program?


You do not have to.

If someone thinks the code you have published under GPL is his code, then he will have to prove it.

If someone who is suspected to have used the code you have published under the GPL says it's not your code anyway, he will have to prove it.



// Christophe
jdart
Posts: 4406
Joined: Fri Mar 10, 2006 5:23 am
Location: http://www.arasanchess.org

Re: A few thoughts about GPL and likes

Post by jdart »

If someone thinks the code you have published under GPL is his code, then he will have to prove it.

If someone who is suspected to have used the code you have published under the GPL says it's not your code anyway, he will have to prove it.
Couple of other points (standard disclaimer: I am not a lawyer, this isn't legal advice):

There are multiple ways that copying code from program A into B could be illegal. Copyright infringement is one of them. Generally this means there has been literal copying. Algorithms are not protectable by copyright. So re-implementing an idea is possible.

But by open-sourcing some piece of code it is possible a person revealed a trade secret, or violated a license agreement - many companies rely on these rather than copyright alone to protect their works. GPL is one example of a license agreement.

Frequently these violations are prosecuted via a civil suit. To get an award or other compensation from a court, you'll generally have to prove you were damaged: for example. the copying was significant enough to deprive you of revenue. So you need to prove not only that you own the code and it was misused, but that it was misused in some non-trivial way.

The recent SCO/Novell court case is a fine illustration of a copying case that backfired. SCO couldn't prove they owned the copyrights, and they couldn't prove significant copying. Then it transpired that they had violated license agreements with Novell, and owed them money. Still pending is an action in which IBM is counter-suing them (http://en.wikipedia.org/wiki/SCO_v._IBM ... gainst_SCO) for among other things damanging their customer relationships with false claims.
User avatar
tiger
Posts: 819
Joined: Sat Mar 11, 2006 3:15 am
Location: Guadeloupe (french caribbean island)

Re: A few thoughts about GPL and likes

Post by tiger »

jdart wrote:
If someone thinks the code you have published under GPL is his code, then he will have to prove it.

If someone who is suspected to have used the code you have published under the GPL says it's not your code anyway, he will have to prove it.
Couple of other points (standard disclaimer: I am not a lawyer, this isn't legal advice):

There are multiple ways that copying code from program A into B could be illegal. Copyright infringement is one of them. Generally this means there has been literal copying. Algorithms are not protectable by copyright. So re-implementing an idea is possible.

But by open-sourcing some piece of code it is possible a person revealed a trade secret, or violated a license agreement - many companies rely on these rather than copyright alone to protect their works. GPL is one example of a license agreement.

Frequently these violations are prosecuted via a civil suit. To get an award or other compensation from a court, you'll generally have to prove you were damaged: for example. the copying was significant enough to deprive you of revenue. So you need to prove not only that you own the code and it was misused, but that it was misused in some non-trivial way.

The recent SCO/Novell court case is a fine illustration of a copying case that backfired. SCO couldn't prove they owned the copyrights, and they couldn't prove significant copying. Then it transpired that they had violated license agreements with Novell, and owed them money. Still pending is an action in which IBM is counter-suing them (http://en.wikipedia.org/wiki/SCO_v._IBM ... gainst_SCO) for among other things damanging their customer relationships with false claims.


Even if you provide source code for free and you do not get money from it, then someone who violates your license could own you money for damages.

This is from a recent court decision:

http://news.yahoo.com/s/zd/20080813/tc_ ... SAyI.or7oF

I think the message is clear.



// Christophe
bob
Posts: 20943
Joined: Mon Feb 27, 2006 7:30 pm
Location: Birmingham, AL

Re: A few thoughts about GPL and likes

Post by bob »

rhollay wrote:These days there have been several debates about GPL, identical - equivalent - similar code in two programs,
how many code lines can be copy-pasted without violating GPL, etc.

Having been a programmer (not involved in chess programming) myself in past, just a few words about the topic.

The question is: is it possible for two independent programs to have identical (or equivalent or very similar) code snippets,
let's say a few hundred lines, without violating a license?

In my opinion it's possible. Easily.

1. There are many books, e-books about programming with examples, free code snippets for everyone, tutorials, other publications on internet,
even open-source programs not under GPL, so that everybody who reads them can copy-past several hundreds of lines of code very easily.
I suppose there are such publications about chess programming also...
Actually there is not. But even with books, this is uncommon. I teach a course in network programming using the Stevens book "Unix Network Programming" which has all kinds of code in it, yet I do not get duplicate programs, or even close to duplicate blocks of code turned in.


What if somebody picks up let's say some sorting algorithm from one of the above mentioned free sources, uses it in his GPL-ed program,
while at the same time I use the same code snippets in my commercial program? Have I violated GPL?

If you_copy_ from a GPL program, then you are bound by GPL requirements. We are not talking about a 10 line sort being the determining factor. We are talking about _hundreds_ of lines. There is a big difference. If 10 people write a heap-sort, rather than a 10-line bubble sort, the programs will vary significantly.
On the other side, how can somebody who publishes under GPL prove that each line of program code is his own original work, so that nobody
is allowed to use them without publishing the sources?

2. Let's suppose that I have a closed-source program just being developed by me and some other programmers. One of them leaves the team,
and gives away parts of code to somebody else who is just writing an open-source program under GPL. He uses parts of my code and publishes
the sources under GPL, but I don't, because my program is closed-source.

Have I violated GPL? How can I prove that code snippets are mine, and not copy-pasted from his GPL-ed program?
This sounds like something Uri would ask. The person that stole _your_ code is the one guilty of a copyright infringement.

One can find many other scenarios where two programs can have identical parts, still nobody violates GPL, at least not intentionally.
In a chess program, the chances are so close to zero for this happening over a large number of lines of code, it is not worth discussing.
jdart
Posts: 4406
Joined: Fri Mar 10, 2006 5:23 am
Location: http://www.arasanchess.org

Re: A few thoughts about GPL and likes

Post by jdart »

That is interesting but in the case you cite it appears the owner hasn't gotten any damages yet: he still needs to get the lower court to agree to award any.

So in practice he might get something (besides just an injunction to prevent further copying/distribution) but it is TBD.
User avatar
Bill Rogers
Posts: 3562
Joined: Thu Mar 09, 2006 3:54 am
Location: San Jose, California

Re: A few thoughts about GPL and likes

Post by Bill Rogers »

Being totally unaware about GPL but knowing Copywright matters I would like to make the following information.
I worked in Silicon Valley for 15 years for a large software company. They wrote an accounting package that would run city and countys all over the US and in fact did do just that. Their package cost upwards of $50,000.00 depending on how many modules and how many users you wanted to be able to be on line at the same time.
We did on one occasion sue another software company for piracey. They just changed the front end of our package and claimed that it was their own. The FBI put them out of business.
The Copywright laws of the US simpley state that if over 10% of the code in a preticular piece of software has been change then it is considered a new work. This does not mean just changing variables or name of subroutines, etc., it means altering the original works by either adding 10% more code or deleting some code and changing at least 10% of the remaining code.
Now if someone else has written some kind of copywright laws, ie GPL and think they can overpower the US Government I have news for them.
It won't float at least in the United States.
Bill