Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Plimpton's FFT library is licensed under GPLv2 not BSD-3 #266

Open
felker opened this issue Apr 28, 2019 · 4 comments
Open

Plimpton's FFT library is licensed under GPLv2 not BSD-3 #266

felker opened this issue Apr 28, 2019 · 4 comments
Assignees
Labels
bug Broken functionality or unexpected result question Source code inquiries (not for asking about code usage) style Consistency of codebase conventions
Milestone

Comments

@felker
Copy link
Contributor

felker commented Apr 28, 2019

Summary of issue

The software licensing topic came up again during my development of #263, specifically regarding the prospect of adding a third-party library for Gaussian-Legendre quadrature #263 (comment).

Athena++ is licensed under the 3-clause Berkeley Software Distribution (BSD) license:
https://github.com/PrincetonUniversity/athena/blob/91421866c865c10ad053c243e7e8d63167ab1d30/LICENSE
As far as I understand, this is a requirement from some national laboratories since they refuse to work with open-source software that has a copyleft license.

However, I noticed that Plimpton's Parallel FFT Package, which we keep an (unmodified?) copy of in src/fft/plimpton/ is actually licensed under GNU General Public License (GPL) 2. In fact, we keep a copy of this license text in our repository:
https://github.com/PrincetonUniversity/athena/blob/91421866c865c10ad053c243e7e8d63167ab1d30/src/fft/plimpton/LICENSE

Even though this library comes from Sandia National Laboratory, I believe we are in violation of the GPLv2 license by distributing Athena++ under BSD-3 while src/fft/plimpton/ is contained in our repository.

@tomidakn raised the possibility of creating a new top-level directory ext/ where the source code for such external dependencies could be added via patches, but not provided with the main Athena++ repository. This might also be a better overall practice for storing source code that was not authored by Athena++ developers. @jmstone mentioned that the mixing of Steve Plimpton's source code in src/ was less-than-ideal. @changgoo, you mentioned that src/fft/plimpton/ was not verbatim Plimpton's library, but a modified version written by Nicole Lemaster?

We would not need to worry about this for other software like SUNDIALS that are licensed under BSD-3 like Athena++.

@felker felker changed the title Plimpton Plimpton's FFT library is licensed under GPLv2 not BSD-3 Apr 28, 2019
@felker felker added bug Broken functionality or unexpected result question Source code inquiries (not for asking about code usage) style Consistency of codebase conventions labels Apr 28, 2019
@felker felker added this to the v1.1.x milestone Apr 28, 2019
@changgoo
Copy link
Contributor

changgoo commented Apr 29, 2019

@changgoo, you mentioned that src/fft/plimpton/ was not verbatim Plimpton's library, but a modified version written by Nicole Lemaster?

yes, Nicole made changes to make it only works with FFTW.

@felker
Copy link
Contributor Author

felker commented Jun 26, 2019

Even worse, I am realizing that Athena++ (and a ton of files in Athena 4.2) is likely in violation of the Numerical Recipes license. See Boycott Numerical Recipes for a discussion.

The NR source code cannot be redistributed, nor can derivative works such as the code adapted to double precision in:

//----------------------------------------------------------------------------------------
//! \fn double ran2(std::int64_t *idum)
// \brief Extracted from the Numerical Recipes in C (version 2) code. Modified
// to use doubles instead of floats. -- T. A. Gardiner -- Aug. 12, 2003

There are no exceptions for noncommerical or scientific/academic use. At a minimum, we cannot relicense it under the BSD-3 header. I think we need to replace double ran2(std::int64_t *idum).

"recipes" appears in the comments of 6x more Athena++ files for relativistic calculations in the context of what I believe are all root-finding applications. I think these files are fine, since the source code is not pulled from NR; the comments merely identify steps of the generic algorithm. Can you confirm this @c-white?

@c-white
Copy link
Contributor

c-white commented Jun 26, 2019

I wouldn't use NR code even if it were public domain -- it's pretty terrible all around. Those are just convenient formula references for the quadratic formula (including the form no one knows about) and cubic equation roots.

@changgoo
Copy link
Contributor

Just realized that the new version of the Plimpton's parallel FFT library is noe released with BSD license. If I port it, it will resolve the issue. I just tested the performance and there's no improvement on it, which gave me little motivation for porting it. But, at some point, I may need to port the new version anyway with somewhat large modifications.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Broken functionality or unexpected result question Source code inquiries (not for asking about code usage) style Consistency of codebase conventions
Projects
None yet
Development

No branches or pull requests

5 participants