How does Nixpkgs handle the “include a copy of the GPL” requirement?

Eventually, I want to create a package for the new open-source version of Descent 3’s engine. It was released under the GNU GPL v3. When distributing a copy of a GPL’d program, you must include a copy of of the GPL. How does Nixpkgs make sure that users always recieve a copy of the GPL? Is setting meta.license good enough, or do I need to make sure that the package’s output contains a copy of the GPL?

The default GPL 3 header says something different :joy:

You should have received a copy of the GNU General Public License
along with this program.  If not, see <https://www.gnu.org/licenses/>.

the copy of the source code you shall receive already includes one Descent3/LICENSE at 21e23f7972c0103d646c5bb97bb277c629b14231 · DescentDevelopers/Descent3 · GitHub

Does that mean that I don’t have to include a copy of the GPL with every copy of the program?

Oh, I know that the source code contains a copy of the GPL. I was trying to ask about the package that contains binaries.

My understanding is that as cache.nixos.org contains the source code for packages as well as the object code, it complies with section 6 of the GPL 3.0 The GNU General Public License v3.0 - GNU Project - Free Software Foundation through method d.

The source can be obtained through the src attribute e.g. nix build nixpkgs#gcc.src or nix-build -f <nixpkgs> -A gcc.src

1 Like

That makes sense. I think that the GNU licenses FAQ might be wrong here. The FAQ says “Why does the GPL require including a copy of the GPL with every copy of the program?”, but the text of the GPLv3 doesn’t seem to say that you need to include a copy of the GPL with every copy of the program. It just says that you need to include a copy of the GPL with every copy of the source code.

I sent an email to licensing@gnu.org. Hopefully, they’ll update the FAQ to make it less misleading.

4 Likes

The FSF’s Licensing and Compliance Manager, Krzysztof Siewicz, responded to my email. He gave me permission to post his answer here, but he asked that I reproduce the whole question and the answer and mention that FSF’s answers are not legal advice.

Here’s my original message:

Subject: Question about the GPL’s requirement to include a copy of the license

Hello,

I’m thinking about creating a Nix package for a piece of software that was recently released under the GNU GPL version 3, and I want to make sure that I’m doing everything correctly. The GNU licenses FAQ has a question titled “Why does the GPL require including a copy of the GPL with every copy of the program?” The title of that question makes is sound like I would have to make sure that both the source package and the binary package contain copies of the GPL.

That being said, the text of the GPL makes it seem like it’s OK to not include a copy of the GPL alongside binaries (as long as I include a copy of the GPL in the source code and give people an opportunity to download that source code). Section 6 of the GPLv3 says

You may convey a covered work in object code form under the terms of sections 4 and 5, provided that you also convey the machine-readable Corresponding Source under the terms of this License, in one of these ways:

  • d) Convey the object code by offering access from a designated place (gratis or for a charge), and offer equivalent access to the Corresponding Source in the same way through the same place at no further charge. You need not require recipients to copy the Corresponding Source along with the object code. If the place to copy the object code is a network server, the Corresponding Source may be on a different server (operated by you or a third party) that supports equivalent copying facilities, provided you maintain clear directions next to the object code saying where to find the Corresponding Source. Regardless of what server hosts the Corresponding Source, you remain obligated to ensure that it is available for as long as needed to satisfy these requirements.

Can I distribute binaries of a GPL’d program without including a copy of the GPL with those binaries? If so, then I think that that question in the FAQ should be changed to have a better title.

Thanks in advance,
Jason Yundt

And here’s his response:

Subject: [gnu.org #2048937] Question about the GPL’s requirement to include a copy of the license
On Fri Apr 26 13:08:25 2024, jason@jasonyundt.email wrote:

Hello,

Hello!

I’m thinking about creating a Nix https://nix.dev package for a piece
of software that was recently released under the GNU GPL version 3
https://github.com/DescentDevelopers/Descent3/, and I want to make
sure that I’m doing everything correctly. The GNU licenses FAQ has a

Thanks for writing in and for being mindful about your obligations under the GNU GPL.

question titled “Why does the GPL require including a copy of the GPL
with every copy of the program?”
https://www.gnu.org/licenses/gpl-faq.en.html#WhyMustIInclude The title
of that question makes is sound like I would have to make sure that both
the source package and the binary package contain copies of the GPL.

Yes, you are correct. Users should have full clarity about their freedom and this is provided by ensuring that they have the complete text of the GNU GPL.

That being said, the text of the GPL makes it seem like it’s OK to not
include a copy of the GPL alongside binaries (as long as I include a
copy of the GPL in the source code and give people an opportunity to
download that source code). Section 6 of the GPLv3 says

You may convey a covered work in object code form under the terms of
sections 4 and 5, provided that you also convey the machine-readable
Corresponding Source under the terms of this License, in one of
these ways:

…

  * d) Convey the object code by offering access from a designated
    place (gratis or for a charge), and offer equivalent access to
    the Corresponding Source in the same way through the same place
    at no further charge. You need not require recipients to copy
    the Corresponding Source along with the object code. If the
    place to copy the object code is a network server, the
    Corresponding Source may be on a different server (operated by
    you or a third party) that supports equivalent copying
    facilities, provided you maintain clear directions next to the
    object code saying where to find the Corresponding Source.
    Regardless of what server hosts the Corresponding Source, you
    remain obligated to ensure that it is available for as long as
    needed to satisfy these requirements.

Can I distribute binaries of a GPL’d program without including a copy of
the GPL with those binaries? If so, then I think that that question in
the FAQ should be changed to have a better title.

The part which you quoted does not refer to the obligation to give all recipients a copy of the license. That obligation is included in Sec. 4. Please note that Sec. 6 explicitly upholds obligations from Sec. 4 and 5 and it also requires to follow some additional obligations.

Please read carefully the “How to apply…” section at the end of the GNU GPL document for the recommended way of including the license with the program.

Additionally, as far as I understand your project is an effort to improve a nonfree game. The game itself is released under a nonfree EULA and it’s copyright holder may attempt to control efforts such as yours or simply change their policy at some time, which could likely invalidate your project. This means that even though your project is released under the GPL, the freedom that the GPL grants are rendered moot by the restrictions imposed on the base game. Releasing your project under the GPL is therefore misleading, as it effectively stimulates users to use the nonfree game and results in them being unable to exercise the freedom.

Perhaps there are some details about the game that we are not aware of. Please let us know if this is the case. But if we are right and the game is nonfree, I hope you understand that the ultimate consequence is that it is not possible for the users to exercise their freedom even if you release your project under the GPL.

This is not legal advice. The FSF does not provide legal advice, but we have considerable experience in answering licensing questions from the public and explaining how the GPL is intended to be applied.

I hope this helps.

Thanks in advance,
Jason Yundt


Best,
Krzysztof Siewicz | Licensing and Compliance Manager, Free Software Foundation
GPG Key: 6DC9 E663 36DB 9588 81AB 7E43 2671 24EF FC9C D84E
https://fsf.org

Register for LibrePlanet 2024: https://libreplanet.org/2024/

Follow the FSF on Mastodon: https://hostux.social/@fsf

Sign up for the FSF’s newsletter: Free Software Supporter — Free Software Foundation — Working together for free software

US government employee? Use CFC charity code 63210 to support us through
the Combined Federal Campaign. https://cfcgiving.opm.gov/

So, I guess that this brings me back to my original question: How does Nixpkgs make sure that users receive a copy of the GPL when they download binary packages?