Is It Okay To Learn From GPL'd Code?
scenic asks: "I was wondering if it's okay to learn from GPL'd code if I plan on creating a closed source product. I'm developing a product for work which has an undetermined license (open or closed) at this point. I don't plan on using code from another project directly, but I'd like to see how other projects deal with problems I will likely face in development. I've been reluctant to even look at GPL'd products because I don't want to violate the letter or the spirit of the GPL. I'm wondering if I'm just being too worried, though. Specifically, I'd like to know what other people think? Is there a definitive answer? " Learning from GPL'd code is one thing, then there's plagiarizing whole blocks of code into your own closed apps, which is a no-no. How do you all feel about this. If you know you are planning on coding another project, is it OK to look through GPL code for ideas or should a programmer be safe and avoid GPL'd code until his obligations to the current project are satisfied?
Indeed, that was my point. I am very much aware of RMS standpoints on this - I've discussed it with him. I'm also very aware of the GNU literature. Please don't assume otherwise.
As I stated, and you quoted, RMS very much is against the control of ideas. That's what I was talking about. IDEAS, not code. He's all for the free exchange and non-ownership of ideas.
The GPL is a piece of legalism used to protect the concrete expression of ideas (that is, source code). It has nothing to do with the ideas itself. The only reason it exists is that currently, the concrete expression of ideas is controllable. The GPL is an attempt to end-run around this, for a reasonable social cause. And, as such, it's solely focused on code, not ideas. Nothing in the GPL, the GNU Manifesto, or otherwise indicates that RMS believes in any control or restriction of ideas (even the so-called "good" restrictions of the GPL w/r/t enabling free code). By attempting to control the use of his ideas, RMS would be hypocritical in the extreme, which I can definately say he's not. By controlling the use of the expression of his ideas (the code), he's actually attempting to move people in a direction where ideas currently sit: complete non-control.
The GPL (and GNU) are all about protecting the freedom of implementation, don't deal at all with design.
Anyhow, this is all rhetorical. You can't own an idea ( funky business-method patents aside ). So there's nothing preventing you from sharing them with others, and gleening what knowledge you can from elsewhere.
And, if you read my post, I say explicity point out that stealing code is verboten.
Please, take a couple minutes to think before hitting the Reply button. I find that usually helps me stop from putting my foot in my mouth.
-Erik
There are always four sides to every story: your side, their side, the truth, and what really happened.
.. Go for It!
All the legalism aside, and contrary to other poster's opinions, I belive that the spirit of the GPL is to insure that ideas are free. I don't think that even in a grouchy mood RSM would insist that you must "free" your own ideas because you like his. And, anyhow, just because you write proprietary code, there isn't any reason why you can't share your idea with someone else (unenforcable NDAs and ill-advised patents notwithstanding...), so I think the proper way to "honor" the GPL in this case is to talk about how you solved the problem with others. Share the ideas.
In essence, that's what you're looking for: ideas. You want to see how other people have solved a problem that is important to you. GPL'd software is intended to be a great bank of knowledge - use it.
Now, of course, is the tricky part - writing your own project. My suggestion to avoid lots of problems is this:
Best of Luck.
-Erik
There are always four sides to every story: your side, their side, the truth, and what really happened.
My real intent in releasing source is to allow others to learn from it. If those "others" turn out to be developers of closed-source programs, well, that's unfortunate, but I knew that I was taking that risk when I GPLed the code. I consider it inauthentic and somewhat elitist to say "my source code is open as long as you share my conviction that source code should be open." If I wanted to share my code, and the ideas it contains, with people whose philosophical or political leanings match mine, I'd start a mailing list. But I want to share it with any member of society interested in seeing it, so I GPLed it and posted it on the web.
Do I wish that everyone who looked at my code also believed in GPLing theirs? Sure. Am I going to try to use legal maneuvering and the terms of the GPL to force them to? No. I'm going to talk rationally with them about tghe benefits of open source, maybe I'll write an essay about it, and I'll hope to convince them of the value of my perspective. If I don't succeed, oh well. It takes all types of people, you know.
It's interesting to note that, as the "from-dept." line suggested, this question is really one of where lies the line between learning and plagiarism. This is signigficantly more difficult to discern when dealing with computer code than when dealing with most other forms of expression. If I read 1984, get ideas from it, and write a book using those ideas, I've learned, not plagiarised. If I write a book using Orwell's exact wording (and don't attribute the quote), then I've plagiarised. Now, if I read the source to, say, WordPerfect 8, and write the capability to do that shadow-cursor thing into my own word processor, have I learned or plagiarised? I mean, there are probably only a very few different algorithms I could use to achieve the same result. All would necessarily have some structural similarity, refer to similar variables and parameters, etc. If I change the variable names, is it still plagiarism? If I change the indentation style, is it still plagiarism? If I use a while-loop instead of a for-loop, is it still plagiarism? How different does my algorithm have to be from its prototype to be merely a derivative work and not a copy? How different can it be? I mean, Perl excluded, most languages don't leave you much room to play around with your diction. The variety of ways to achieve a similar effect with different wording in your typical C program is pretty slim.
Disclaimer: I haven't written that much code that's been worth plagiarising. I'm just speaking on principle here.
[We Have No Product] [The Swindle
It is OK to use what you learn. Absolutely.
Same situation as with learning on the job. You will probably end up walking out the door of your current job with lots of valuable experience. Nothing you can do about it even if you wanted to.
There are details, though. You can walk out a better {whatever} than you walked in. You can't walk out with the customer list or the specs to the next big project. And you can't "learn" GPL code by copy and paste.
Use it to improve yourself, use it to see how things work. But write your own non-GPL code.
Our secret is gamma-irradiated cow manure
Mitsubishi ad
We apologize for the inconvenience.