Managing license and copyright in Stack packages¶
All packages in the LSST Stack (EUPS-distributed packages installed with lsst_distrib
and qserv_distrib
, for example) are licensed under GPL-3.0 terms.
This page describes the three aspects developers need to know to properly implement the GPL-3.0 license in Stack packages:
For additional background information on licenses and copyright for LSST DM work, see the pages Licensing LSST DM source code and content and Copyrights for LSST DM work and the COPYRIGHT file.
The LICENSE file¶
Each Stack package must have a file called LICENSE
at its root.
You can find the LICENSE file in the stack_package template.
Be careful not to modify the LICENSE file.
The COPYRIGHT file¶
Each Stack package must have a file called COPYRIGHT
at its root where we record copyright assignments.
See The COPYRIGHT file for information on how to format the COPYRIGHT
file.
All DM developers are expected to participate in maintaining the COPYRIGHT
file on behalf of your institution.
Include additions to COPYRIGHT
files as part of your regular pull requests.
/legal/copyright.py
is a script that may help maintain COPYRIGHT
files.
License preambles in source files¶
The GPL-3.0 license requires each source file to have a preamble comment containing a license statement. This is the generic license preamble:
This file is part of {{ cookiecutter.package_name }}.
Developed for the LSST Data Management System.
This product includes software developed by the LSST Project
(https://www.lsst.org).
See the COPYRIGHT file at the top-level directory of this distribution
for details of code ownership.
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program. If not, see <https://www.gnu.org/licenses/>.
Replace {{ cookiecutter.package_name }}
with the repository’s name (afw
, for example).
This preamble is available as a template.
Python preamble¶
The license preamble specifically for use in Python files is:
# This file is part of {{ cookiecutter.package_name }}.
#
# Developed for the LSST Data Management System.
# This product includes software developed by the LSST Project
# (https://www.lsst.org).
# See the COPYRIGHT file at the top-level directory of this distribution
# for details of code ownership.
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <https://www.gnu.org/licenses/>.
Replace {{ cookiecutter.package_name }}
with the repository’s name (afw
, for example).
See also: Each Python file MUST contain the standard license preamble in the LSST DM Python Style Guide.
This preamble is available as a template.
C++ preamble¶
The license preamble specifically for use in C++ source and header files is:
/*
* This file is part of {{ cookiecutter.package_name }}.
*
* Developed for the LSST Data Management System.
* This product includes software developed by the LSST Project
* (https://www.lsst.org).
* See the COPYRIGHT file at the top-level directory of this distribution
* for details of code ownership.
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
Replace {{ cookiecutter.package_name }}
with the repository’s name (afw
, for example).
This preamble is available as a template.