Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Why is this being down-voted? It's totally correct. GPLed code linked into a program doesn't magically make the program GPLed. The GPL guarantees that as long as you provide the source code of your code under the GPL, you automatically get a license to use other GPLed code in your code. If you use GPLed code, but don't provide your code under the GPL, then you are probably infringing copyrights. That can be mitigated (assuming you're honorable and don't just hide it) by possibly paying the authors of the GPLed code to get a license under different terms, or possibly removing the code in question and maybe paying the original authors, or by fighting in court and possibly being forced to stop distributing the code and then removing the code and paying fines, or (as many assume is the only option) releasing their own code under the GPL as well.

The details of what would occur almost certainly depend on the circumstances (was it known, when was it known, was it on purpose, did it have any real effect or was it a random bit of source code that was basically unused, etc.) and jurisdiction as well. Regardless it's definitely not the case that the GPL just magically infects any code it touches. That is a ridiculous simplification that is mostly spread by ignorance or those spreading FUD. Hell the GPL doesn't even do anything at all until the programs themselves is distributed.

It's perfectly reasonable to prefer other licenses over the GPL, but let's not make up reasons to dislike it.



I think that the topic is too complicated. Too many developers not firmly on the FOSS-side simply follow the FUD, or they follow their lawyer's [typically overly risk-averse] lead when saying to steer away, or when the virality is described elsewhere. The knowledge that even GPL2-definition of virality for linked code is debatable (what exactly is linked code, what does being part of something mean exactly? To not get started with derived work), what GPL3 means in this context, and that the court's decisions in different jurisdictions are not straightforward is simply not there. Thus downvotes, as you saw.

The questions with the monorepo and having code checked in is the perfect example.

On the other hand, it is understandable. In a crazy jurisdiction like the US where Oracle can win with absurdly claiming copyright on Java-APIs I can understand everyone trying to minimize risk.


This is splitting hairs. If you link GPL’d code to your proprietary code (and distribute your proprietary code to users in executable form), your only options are to release your code under the GPL or violate copyright law. You can address your illegal action in the ways you’ve described but you’re absolutely engaging in illegal behavior at the point you link the GPL code without licensing your own code under the GPL.

The “viral” description of the GPL is reasonably accurate. At least for people don’t who want to engage in illegal behavior. Forced (re)licensing is specifically the intent of the GPL.


It absolutely is not splitting hairs. This means that if you have a large codebase and accidentally link GPLed code into it, you have many different options that do not involve GPLing your code. Many people incorrectly believe that is not the case which is proved by many of the responses in this very thread.

One of the original examples here in this thread (by bryanlarsen above) was even about checking GPLed code into a repo. Any company can do that and can experiment and decide they really like the code and then they can e.g. contact the copyright holders and offer to license under different terms or another large number of options. This sort of misconception is widespread only one example of why most people's understanding of the "GPL is viral" is simply wrong. Calling this splitting hairs is ridiculous. It's fundamental.


Who thinks that “accidental” linking is the problem? And how does that really even happen? You accidentally check in some GPL code, build and link to it, and then also accidentally distribute the resulting binaries?

Bryanlarsen above specifically called out that checking into a repo is not linking.

The only real misconception is that use of GPL software by a company will somehow result in all software owned by that company becoming GPL licensed. This is of course not true. It is true that linking proprietary software to GPL code and then distributing executables must result in either the proprietary software being licensed under the GPL or a copyright violation.

Your comments about getting different license terms is proving my point. Your proposed solutions to the GPL redistribution clause all boil down to not using GPL software.


> The only real misconception is that use of GPL software by a company will somehow result in all software owned by that company becoming GPL licensed. This is of course not true. It is true that linking proprietary software to GPL code and then distributing executables must result in either the proprietary software being licensed under the GPL or a copyright violation.

Other than the fact that you can of course negotiate another license to that GPLed software, I agree. Said more succinctly, distributing copyrighted materials without a license is a copyright violation and that has nothing to do with the GPL. My point is that the remedy for the copyright violation need not result in your original codebase being GPLed. This is even true if the original authors absolutely refuse to issue you a separate non-GPL license or refuse to negotiate. In that case they can probably get an injunction and statutory damages (of course assuming they pursue legal action).

Regardless, I don't think we disagree here. However, you seem to be ignorant of the FUD that is often spread about the GPL. Many people believe claims like if Microsoft linked GPLed code into Office that they would have no choice but to GPL all of Office. That is false. As long as we agree about this I don't see any point in discussing this further.

> Your comments about getting different license terms is proving my point. Your proposed solutions to the GPL redistribution clause all boil down to not using GPL software.

Well if you'd like a clear statement about my beliefs it's this: Don't use software if you aren't prepared to meet the terms of its license. But that doesn't really have anything to do with the GPL specifically.


I concur that we generally agree on the facts. We seem to have different interpretations of what those facts imply, though. This comment I disagree with:

“Regardless it's definitely not the case that the GPL just magically infects any code it touches. That is a ridiculous simplification that is mostly spread by ignorance or those spreading FUD.”

The GPL does infect the code it touches. If you link your proprietary software to GPL software, now and forever the binaries you produced with that linking are “tainted”. You distribute the source under the GPL or you do not distribute those binaries (or you violate the law). You can certainly back out the offending change and future binaries will clean and clear, but the GPL does, by design, force the choice between copyright violation and opening up proprietary software. It does not, however, perpetually “taint” source that touched it in the past and anyone who thinks it does is misinformed.

The characterization as viral/infectious remains reasonable, though, given the intent and the legal implications.


> If you link your proprietary software to GPL software, now and forever the binaries you produced with that linking are “tainted”. You distribute the source under the GPL or you do not distribute those binaries (or you violate the law). You can certainly back out the offending change and future binaries will clean and clear, but the GPL does, by design, force the choice between copyright violation and opening up proprietary software.

We are in agreement that you can of course also negotiate another license right? (Assuming the copyright holder(s) go along.) I don't want to beat a dead horse here, but I just want to make sure we're clear about that one thing. Your sentence here seems to present a binary choice when of course it isn't binary.

edit: I only bring this up because another misconception many (not necessarily you) have is that software cannot be simultaneously GPL as well as another license. This should be basically obvious to most when they think about it (basically all business to business software is negotiated under different licenses for example), but most somehow still don't realize it when it comes to the GPL for some reason.


> We are in agreement that you can of course also negotiate another license right? (Assuming the copyright holder(s) go along.) I don't want to beat a dead horse here, but I just want to make sure we're clear about that one thing. Your sentence here seems to present a binary choice when of course it isn't binary.

Of course. If you negotiate a different license, then of course you are no longer bound by the terms of the GPL. That doesn't say anything about the intent or effects of the GPL itself, though.

> edit: I only bring this up because another misconception many (not necessarily you) have is that software cannot be simultaneously GPL as well as another license. This should be basically obvious to most when they think about it (basically all business to business software is negotiated under different licenses for example), but most somehow still don't realize it when it comes to the GPL for some reason.

That is an option in theory, and lots of software is dual- or multiple-licensed. It depends on how the software was written, though. If a single entity (or small number of entities) owns the copyright to the software, this is definitely viable. Lots of authors who retain their own copyright on their contributions gets a lot harder. You technically need all contributors to agree to the relicensing if they haven't signed over their copyrights to someone else (as the FSF requires for software they maintain).

I'm actually not sure about the legality of some of the open-source relicensing that happens. I've seen projects announce that they are relicensing without getting signoff from all contributors. This is shady and unlikely to be legal. Using software that's been relicensed this way is probably a terrible idea (from a dev standpoint; doesn't matter much for end users).


"GPLed code linked into a program doesn't magically make the program GPLed"

Lots of people for debatable but legitimate reasons believe that GPLv2 does this.

They don't realize that this doesn't apply to GPLv3, nor to the AGPLv3.


> "GPLed code linked into a program doesn't magically make the program GPLed"

> Lots of people for debatable but legitimate reasons believe that GPLv2 does this.

> They don't realize that this doesn't apply to GPLv3, nor to the AGPLv3.

Honestly I simply think you're not understanding me. Let me summarize: linking GPLed code without GPLing your own code and without having any other license to do so is copyright infringement. There are multiple ways to avoid infringement. You can pay the authors for another license, you can possibly remove the code and pay the authors enough so they're drop the matter, you can go to court, or you can release your own code under the GPL.

You do understand that that is not the same as saying that "linking GPLed code to your code makes your code GPLed" right?

edit: Apologies if I misunderstood you when you said: "Lots of people for debatable but legitimate reasons believe that GPLv2 does this." Maybe you don't believe this yourself (which is what I assumed when drafting my reply here). I agree with you that lots of people believe this, but it basically isn't debatable and certainly is wrong. Put another way: What is the legal rationale for the claim that linking GPLed code immediately makes the linking code GPLed?


Assuming that linked code is distributed. You can use it internally as much as you want. (With the caveat that distribution has a broader meeting under AzGPL.)


You are 100% correct that you can execute/link/etc. GPLed code without following the terms of the license when you're not distributing your code. But I'm not referring to distribution. I'm saying that if you were to link your own non-GPLed code to GPLed code _and_ you were to distribute it, your code would not automatically become GPLed code. You would be infringing upon copyright. There are multiple options to stop that infringement which do not involve GPLing your code.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: