Policies/Licensing Policy/Draft: Difference between revisions

From KDE Community Wiki
No edit summary
(Add links to “as below” to jump easily to the SPDX header.)
 
(36 intermediate revisions by 2 users not shown)
Line 1: Line 1:
This licence policy is designed to allow maximum code reuse with the community of KDE and beyond while making exceptions for the few cases which need it.
This licence policy is designed to allow maximum code reuse with the community of KDE and beyond while making exceptions for the few cases which need it.


All new source code and related data files in KDE repositories (SVN, GIT) must meet the following requirements:
Guidelines and best practices for applying this policy can be found in the [[Guidelines_and_HOWTOs/Licensing|Licensing HowTo]].
 
== Policy ==
All new source code and related data files in KDE repositories (SVN, Git) must meet the following requirements:
# All files must be in their preferred modifiable form, or alongside the file which is the preferred modifiable form.  In the 'alongside' case, there must be clear instructions for how to build using the preferred modifiable form.
# All files must be in their preferred modifiable form, or alongside the file which is the preferred modifiable form.  In the 'alongside' case, there must be clear instructions for how to build using the preferred modifiable form.
# All source files must contain a copyright header which identifies the copyright holder(s) together with an e-mail address that can be used to reach the copyright holder.
# All source files must contain a copyright header which identifies the copyright holder(s) together with an e-mail address that can be used to reach the copyright holder.
# Each source file must contain one of the licence headers listed below to state under which terms the software may be used, modified and redistributed.
# Each source file either must contain SPDX identifiers or licence headers to state under which terms the software may be used, modified and redistributed. The SPDX identifiers or licence headers [[#Templates|stated below]] must be used. Inside one repository all files shall follow the same system for licence statements.
# ''Source files'' that are part of a library with a public API which is part of the KDE Platform (kdelibs, kdepimlibs, kde-runtime and KDE Frameworks) must be licensed under one of the following terms:
## For each used SPDX identifier, the licence text must be included compatible with the SPDX specification.
#* '''LGPL''' version 2.1, or version 3 or later versions approved by the membership of KDE e.V. [preferred]
# ''Source files'' that are part of a library with a public API which is part of the KDE Platform (kdelibs, kdepimlibs, kde-runtime and KDE Frameworks) must be licensed under:
#* '''LGPL''' version 2.1 as listed in {{path|kdelibs/COPYING.LIB}} or later
#* '''[https://spdx.org/licenses/LGPL-2.1-only.html LGPL-2.1-only] OR [https://spdx.org/licenses/LGPL-3.0-only.html LGPL-3.0-only] OR [[#LicenseRef-KDE-Accepted-LGPL|LicenseRef-KDE-Accepted-LGPL]]:''' LGPL version 2.1, or version 3 or later versions approved by the membership of KDE e.V.
#* '''BSD license''' as listed below.<br/>Ensure that the BSD license '''does not contain the so called 'advertisement clause'.'''
#:They may also be licensed under one of the following terms if it helps with license compatibility:
#* '''MIT license''' as listed below.
#* '''[https://spdx.org/licenses/LGPL-2.1-or-later.html LGPL-2.1-or-later:]''' LGPL version 2.1 or later
#* '''X11 license''' as listed below.
#* '''[https://spdx.org/licenses/BSD-2-Clause.html BSD-2-Clause:]''' BSD-2-Clause license as [[#BSD-2-Clause|listed below]].'''
#* '''[https://spdx.org/licenses/BSD-3-Clause.html BSD-3-Clause:]''' BSD-3-Clause license as [[#BSD-3-Clause|listed below]]. </br> '''Note:''' It is strongly discouraged to use the BSD-3-Clause license. It makes sharing code within KDE more complicated and isn’t of much benefit. Unless you must use it (for example because of upstream compatibility), use the BSD-2-Clause instead.'''
#* '''[https://spdx.org/licenses/MIT.html MIT:]''' MIT license as listed below.
#* '''[https://spdx.org/licenses/X11.html X11:]''' X11 license as listed below.
#:'''Note:''' each bulletpoint above is a single option, it can not be licenced under just part of one bulletpoint option
#:'''Note:''' each bulletpoint above is a single option, it can not be licenced under just part of one bulletpoint option
#:'''Note:''' code may not be copied from Qt into KDE Platform as Qt is LGPL 3 only which would prevent it being used under LGPL 2.1
#:'''Note:''' code may not be copied from Qt into KDE Platform as Qt is LGPL 3 only which would prevent it being used under LGPL 2.1
#:'''Note:''' the LGPL 2.1, 3 or approved by e.V. option is preferred and should be used unless there are special needs to improve code shareability
#:'''Note:''' the LGPL 2.1, 3 or approved by e.V. option is preferred and should be used unless there are special needs to improve code shareability
# Any other source files must be licensed under one of the terms listed under 4) or one of the following terms:
# Any other source files must be licensed under one of the terms listed under 4) or:
#* '''GPL''' version 2 or version 3 or later versions approved by the membership of KDE e.V. [preferred]
#* '''[https://spdx.org/licenses/GPL-2.0-only.html GPL-2.0-only] OR [https://spdx.org/licenses/GPL-3.0-only.html GPL-3.0-only] OR [[#LicenseRef-KDE-Accepted-GPL|LicenseRef-KDE-Accepted-GPL]]:''' GPL version 2 or version 3 or later versions approved by the membership of KDE e.V.
#* '''GPL''' version 2 or later
#:They may also be licensed under one of the following terms if it helps with license compatibility:
#* '''GPL''' version 3 or later
#* '''[https://spdx.org/licenses/GPL-2.0-or-later.html GPL-2.0-or-later]:''' GPL version 2 or later
#* '''GPL''' version 3 or later versions approved by the membership of KDE e.V.
#* '''[https://spdx.org/licenses/GPL-3.0-or-later.html GPL-3.0-or-later]:''' GPL version 3 or later
#* '''[https://spdx.org/licenses/GPL-3.0-only.html GPL-3-0-only] OR [[#LicenseRef-KDE-Accepted-GPL|LicenseRef-KDE-Accepted-GPL]]:''' GPL version 3 or later versions approved by the membership of KDE e.V.
#* Code copied from Qt may be licenced under '''GPL''' version 2 or later versions or under '''GPL''' version 3 or later versions depending on the licence of the relevant Qt code
#* Code copied from Qt may be licenced under '''GPL''' version 2 or later versions or under '''GPL''' version 3 or later versions depending on the licence of the relevant Qt code
#:'''Note:''' each bulletpoint above is a single option, it can not be licenced under just part of one bulletpoint option
#:'''Note:''' each bulletpoint above is a single option, it can not be licenced under just part of one bulletpoint option
#:'''Note:''' where a KDE repository contains files which are GPL 3+ it must be clearly marked by adding the full licence in a file called COPYING.GPL3 in the top directory of the repository
#:'''Note:''' where a KDE repository contains files which are GPL 3+ and where the licence is stated with license headers, it must be clearly marked by adding the full licence in a file called COPYING.GPL3 in the top directory of the repository
#:'''Note:''' the GPL 2, 3 or approved by e.V. option is preferred and should be used unless there are special needs to improve code shareability
#:'''Note:''' Qt modules are either GPL2+ or GPL 3+, ensure the licence is compatible with your code before copying code from Qt
#:'''Note:''' Qt modules are either GPL2+ or GPL 3+, ensure the licence is compatible with your code before copying code from Qt
# ''Applications which are intended to be run on a web server'' may be licenced under the GNU AGPL 3.0 or later
# ''Applications which are intended to be run on a server'' may be licenced under the '''[https://spdx.org/licenses/AGPL-3.0-or-later.html AGPL-3.0-or-later]:''' GNU AGPL or later
#:'''Note:''' the GNU AGPL is the recommended licence for web server software in KDE
#:'''Note:''' the GNU AGPL is the recommended licence for server software in KDE
# ''Translations'' of text from the files described in section 4 must be licenced under one of the terms in sections 4.  Translations of text from other files must be licenced under one of the terms in sections 4 or 5.
# ''Translations'' of text from the files described in section 4 must be licenced under one of the terms in sections 4.  Translations of text from other files must be licenced under one of the terms in sections 4 or 5.
# ''Media files'' such as images may be licensed under the Creative Commons Attribution-ShareAlike 4.0 International licence at http://creativecommons.org/licenses/by-sa/4.0/ or compatible licence
# ''Media files'' such as images may be licensed under the '''[https://spdx.org/licenses/CC-BY-SA-4.0.html CC-BY-SA-4.0]''' or compatible licence
#:'''Note:''' CC-BY-SA 4.0 can be converted to LGPL 3.
#:'''Note:''' Image files must be committed together with their preferred modifiable form such as SVG.
# ''Icons'' in oxygen-icons and breeze must be licenced under the '''LGPL''' 3 or later versions approved by KDE e.V.  Icons elsewhere can be licenced under any of the terms in section 4 or 5 or 8.  Using CC-BY-SA 4.0 as listed in section 8 is preferred.
#:'''Note:''' CC-BY-SA 4.0 can be one-way converted to GPL 3.
# ''Icons'' should be licenced as CC-BY-SA 4.0 or can also be licenced under any of the terms in section 4 or 5 or 8.  Icons in oxygen-icons and breeze-icons themes must be licenced under the "'''[https://spdx.org/licenses/LGPL-3.0-only.html LGPL-3.0-only] OR [[#LicenseRef-KDE-Accepted-LGPL|LicenseRef-KDE-Accepted-LGPL]]'''", i.e. LGPL 3 or later versions approved by KDE e.V.
# Content on collaborative edited websites such as wikis must be licensed under the '''Creative Commons Attribution-Sharealike 4.0 International'''  or compatible licence.
# Content on collaborative edited websites such as wikis must be licensed under the '''Creative Commons Attribution-Sharealike 4.0 International'''  or compatible licence.
# ''Documentation'' must be licensed under the '''Creative Commons Attribution-Sharealike 4.0''' International or compatible licence
# ''Documentation'' must be licensed under the '''[https://spdx.org/licenses/CC-BY-SA-4.0.html CC-BY-SA-4.0]''' or compatible licence
#:'''Note:''' CC-BY-SA 4.0 can be converted to LGPL 3.
#:'''Note:''' CC-BY-SA 4.0 can be one-way converted to GPL 3.
# Documentation started before 2016 can be licensed under one of the following terms:
# Documentation started before 2017 can be licensed under one of the following terms:
#* '''FDL''' versions 1.2 as listed in {{path|kdelibs/COPYING.DOC}} or later versions with no Invariant Sections, no Front-Cover Texts, and no Back-Cover Texts.
#* '''[https://spdx.org/licenses/GFDL-1.3.html FDL]''' versions 1.2 or later versions with no Invariant Sections, no Front-Cover Texts, and no Back-Cover Texts.
#* '''FDL''' versions 1.2 as listed in {{path|kdelibs/COPYING.DOC}} or later versions approved by KDE e.V. with no Invariant Sections, no Front-Cover Texts, and no Back-Cover Texts.   
#* '''FDL''' versions 1.2 or later versions approved by KDE e.V. with no Invariant Sections, no Front-Cover Texts, and no Back-Cover Texts.   
#:Note each bulletpoint above is a single option, it can not be licenced under just part of one bulletpoint option
#:Note each bulletpoint above is a single option, it can not be licenced under just part of one bulletpoint option
#:Documentation may additionally be licensed under any of the terms in section 4 or 5.
#:Documentation may additionally be licensed under any of the terms in section 4 or 5.
# ''CMake modules'' must be licenced under the BSD licence listed below
# ''CMake code'' must be licenced under the BSD-2-Clause license as [[#BSD-2-Clause|listed below]] or the BSD-3-Clause licence as [[#BSD-3-Clause|listed below]]. </br> '''Note:''' It is strongly discouraged to use the BSD-3-Clause license. It makes sharing code within KDE more complicated and isn’t of much benefit. Unless you must use it (for example because of upstream compatibility), use the BSD-2-Clause instead.
# ''Windows installer files'' using the WiX Toolset may be licenced under the Common Public Licence 1.0
# ''Windows installer files'' using the WiX Toolset may be licenced under the '''[https://spdx.org/licenses/CPAL-1.0.html Common Public Licence 1.0]'''
# Other data included in KDE's codebase must be licenced under one of the terms in sections 4 or 5.
# Other copyrightable data included in KDE's codebase must be licensed under one of the terms in Sections 4 or 5. If a file is not copyrightable (e.g. it is an automatically generated file, a trivial list of files, or trivial test data) it shall have the '''[https://spdx.org/licenses/CC0-1.0.html CC0-1.0]''' license.
# Contributors who have signed the Fiduciary License Agreement with KDE e.V. may licence files described in section 3 under LGPL 2.1 & 3 only and may licence other source files under GPL 2 & 3 only.
# As new versions of GNU licenses are published they will be discussed by the membership of KDE e.V. and accepted via an announcement on https://ev.kde.org whether we will adopt it.  This will depend on if adopting the licence would harm the future distribution of KDE, if the licence preserves freedom for our developers & users and a vote by the membership agrees to the acceptance of the new licence version. When using the SPDX identifiers '''[[#LicenseRef-KDE-Accepted-GPL|LicenseRef-KDE-Accepted-GPL]]''' or '''[[#LicenseRef-KDE-Accepted-LGPL|LicenseRef-KDE-Accepted-LGPL]]''' to express this, the respective license text must be placed according to the REUSE specification in the repository, as stated below.
# As new versions of GNU licenses are published they will be discussed by the membership of KDE e.V. and accepted via an announcement on http://ev.kde.org whether not adopting the licence would harm the future distribution of KDE, the licence preserves freedom for our developers & users and a vote by the membership agrees to the acceptance of the new licence version.
# ''Geographic data'', in particular data based on or derived from OpenStreetMap may be licensed under the '''[https://spdx.org/licenses/ODbL-1.0.html Open Data Commons Open Database License v1.0]'''.
 
== License Statements ==
The [https://reuse.software/spec/ REUSE Specification - Version 3.0] shall be applied when stating licenses and when adding license files to a project.
 
=== SPDX Statements ===
Each plain text file that can contain comments must contain comments at the top of the file (comment header) that declare that file’s copyright and licensing information. The comment header must contain one or more copyright tags and one SPDX-License-Identifier tag.


== GPL Header ==
For copyright statements either a <code>SPDX-FileCopyrightText</code> tag followed by a colon can be used or the word <code>Copyright</code>, in which case a colon is not needed.
<pre>
Copyright <year> <name of author> <e-mail>


This program is free software; you can redistribute it and/or
The <code>SPDX-License-Identifier</code> tag must be followed by a valid SPDX License Expression describing the licensing of the file (example: <code>SPDX-License-Identifier: LGPL-2.1-or-later OR MIT</code>).
modify it under the terms of the GNU General Public License as
published by the Free Software Foundation; either version 2 of
the License, or (at your option) any later version.


This program is distributed in the hope that it will be useful,
=== License Texts  ===
but WITHOUT ANY WARRANTY; without even the implied warranty of
The repository must include a <code>LICENSES/</code> directory in the root of the repository, which contains the license text for every used license inside the repository. Each license file shall be a plain text file that is placed in this directory and the name of the license file must be the SPDX License Identifier of the license followed by ".txt" (example: <code>LICENSES/LGPL-2.1-or-later.txt</code>). The directory must not include license files for licenses that are not used inside the repository.
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
The license files shall be taken from [https://spdx.org/licenses/]. It is preferred to use the [https://git.fsfe.org/reuse/tool reuse] command line tool's download option to avoid copy-paste errors.
along with this program.  If not, see <http://www.gnu.org/licenses/>.
For <code>LicenseRef-KDE-Accepted-LGPL</code> and <code>LicenseRef-KDE-Accepted-GPL</code> licenses, see below.
</pre>


or for later versions approved by KDE e.V.
==== <span id="LicenseRef-KDE-Accepted-LGPL"></span>LicenseRef-KDE-Accepted-LGPL ====
When using the <code>LicenseRef-KDE-Accepted-LGPL</code> identifier inside a project, the following file <code>LICENSES/LicenseRef-KDE-Accepted-LGPL.txt</code> must be added to the project with the following content:


<pre>
<pre>
Copyright <year>  <name of author> <e-mail>
This library is free software; you can redistribute it and/or
 
modify it under the terms of the GNU Lesser General Public
This program is free software; you can redistribute it and/or
License as published by the Free Software Foundation; either
modify it under the terms of the GNU General Public License as
version 3 of the license or (at your option) any later version
published by the Free Software Foundation; either version 2 of
that is accepted by the membership of KDE e.V. (or its successor
the License or (at your option) version 3 or any later version
approved by the membership of KDE e.V.), which shall act as a
accepted by the membership of KDE e.V. (or its successor approved
proxy as defined in Section 6 of version 3 of the license.
by the membership of KDE e.V.), which shall act as a proxy  
defined in Section 14 of version 3 of the license.


This program is distributed in the hope that it will be useful,
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
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 <http://www.gnu.org/licenses/>.
</pre>
</pre>


== GPL 3 or later ==
==== <span id="LicenseRef-KDE-Accepted-GPL"></span>LicenseRef-KDE-Accepted-GPL ====
 
When using the <code>LicenseRef-KDE-Accepted-GPL</code> identifier inside a project, the following file <code>LICENSES/LicenseRef-KDE-Accepted-GPL.txt</code> must be added to the project with the following content:
Any repository which has this must be clearly marked with a copy of the GPL 3 in a file called COPYING.GPL3 in the top directory


<pre>
<pre>
Copyright <year>  <name of author> <e-mail>
This program is free software; you can redistribute it and/or
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License as
modify it under the terms of the GNU General Public License as
published by the Free Software Foundation; either version 3 of  
published by the Free Software Foundation; either version 3 of
the License, or (at your option) any later version.
the license or (at your option) at any later version that is
accepted by the membership of KDE e.V. (or its successor
approved by the membership of KDE e.V.), which shall act as a
proxy as defined in Section 14 of version 3 of the license.


This program is distributed in the hope that it will be useful,
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
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 <http://www.gnu.org/licenses/>.
</pre>
</pre>


or for later versions approved by KDE e.V.
=== Templates ===


==== GPL ([https://spdx.org/licenses/GPL-2.0-only.html GPL-2.0-only] OR [https://spdx.org/licenses/GPL-3.0-only.html GPL-3.0-only] OR [[#LicenseRef-KDE-Accepted-GPL|LicenseRef-KDE-Accepted-GPL]]) ====
<pre>
<pre>
Copyright <year> <name of author> <e-mail>
SPDX-License-Identifier: GPL-2.0-only OR GPL-3.0-only OR LicenseRef-KDE-Accepted-GPL
SPDX-FileCopyrightText: <year> <name of author> <e-mail>
</pre>


This program is free software; you can redistribute it and/or
==== LGPL ([https://spdx.org/licenses/LGPL-2.1-only.html LGPL-2.1-only] OR [https://spdx.org/licenses/LGPL-3.0-only.html LGPL-3.0-only] OR [[#LicenseRef-KDE-Accepted-LGPL|LicenseRef-KDE-Accepted-LGPL]]) ====
modify it under the terms of the GNU General Public License as
<pre>
published by the Free Software Foundation; either version 3 of
SPDX-License-Identifier: LGPL-2.1-only OR LGPL-3.0-only OR LicenseRef-KDE-Accepted-LGPL
the License or any later version accepted by the membership of
SPDX-FileCopyrightText: <year> <name of author> <e-mail>
KDE e.V. (or its successor approved by the membership of KDE
</pre>
e.V.), which shall act as a proxy defined in Section 14 of
version 3 of the license.


This program is distributed in the hope that it will be useful,
==== Alternative Licenses Allowed for License Compatibility ====
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
===== [https://spdx.org/licenses/GPL-2.0-or-later.html GPL-2.0-or-later] =====
along with this program.  If not, see <http://www.gnu.org/licenses/>.
<pre>
SPDX-License-Identifier: GPL-2.0-or-later
SPDX-FileCopyrightText: <year> <name of author> <e-mail>
</pre>
</pre>


== LGPL Header ==
===== [https://spdx.org/licenses/GPL-3.0-only.html GPL-3.0-only] OR [[#LicenseRef-KDE-Accepted-GPL|LicenseRef-KDE-Accepted-GPL]] =====
<pre>
<pre>
Copyright <year> <name of author> <e-mail>
SPDX-License-Identifier: GPL-3.0-only OR LicenseRef-KDE-Accepted-GPL
SPDX-FileCopyrightText: <year> <name of author> <e-mail>
</pre>


This library is free software; you can redistribute it and/or
===== [https://spdx.org/licenses/GPL-3.0-or-later.html GPL-3.0-or-later] =====
modify it under the terms of the GNU Lesser General Public
<pre>
License as published by the Free Software Foundation; either
SPDX-License-Identifier: GPL-3.0-or-later
version 2.1 of the License, or (at your option) any later version.
SPDX-FileCopyrightText: <year> <name of author> <e-mail>
</pre>


This library is distributed in the hope that it will be useful,
===== [https://spdx.org/licenses/LGPL-2.1-or-later.html LGPL-2.1-or-later] =====
but WITHOUT ANY WARRANTY; without even the implied warranty of
<pre>
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
SPDX-License-Identifier: LGPL-2.1-or-later
Lesser General Public License for more details.
SPDX-FileCopyrightText: <year> <name of author> <e-mail>
</pre>


You should have received a copy of the GNU Lesser General Public
===== [https://spdx.org/licenses/BSD-2-Clause.html BSD-2-Clause] =====
License along with this library.  If not, see <http://www.gnu.org/licenses/>.
<pre>
SPDX-License-Identifier: BSD-2-Clause
SPDX-FileCopyrightText: <year> <name of author> <e-mail>
</pre>
</pre>


or for later versions approved by KDE e.V.
'''Note:''' SPDX lists a half-dozen BSD-2-Clause variants, but you must use exclusively the one listed here.


===== [https://spdx.org/licenses/BSD-3-Clause.html BSD-3-Clause] =====
<pre>
<pre>
Copyright <year> <name of author> <e-mail>
SPDX-License-Identifier: BSD-3-Clause
SPDX-FileCopyrightText: <year> <name of author> <e-mail>
</pre>


This library is free software; you can redistribute it and/or
'''Note:''' SPDX lists a half-dozen BSD-3-Clause variants, but you must use exclusively the one listed here.  
modify it under the terms of the GNU Lesser General Public
License as published by the Free Software Foundation; either
version 2.1 of the License, or (at your option) version 3, or any
later version accepted by the membership of KDE e.V. (or its
successor approved by the membership of KDE e.V.), which shall
act as a proxy defined in Section 6 of version 3 of the license.


This library is distributed in the hope that it will be useful,
===== [https://spdx.org/licenses/X11.html X11] =====
but WITHOUT ANY WARRANTY; without even the implied warranty of
<pre>
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
SPDX-License-Identifier: X11
Lesser General Public License for more details.
SPDX-FileCopyrightText: <year> <name of author> <e-mail>
 
You should have received a copy of the GNU Lesser General Public
License along with this library.  If not, see <http://www.gnu.org/licenses/>.
</pre>
</pre>


== BSD License ==
===== [https://spdx.org/licenses/MIT.html MIT] =====
<pre>
<pre>
Copyright <year> <name of author> <e-mail>
SPDX-License-Identifier: MIT
 
SPDX-FileCopyrightText: <year> <name of author> <e-mail>
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions
are met:
 
1. Redistributions of source code must retain the above copyright
  notice, this list of conditions and the following disclaimer.
2. Redistributions in binary form must reproduce the above copyright
  notice, this list of conditions and the following disclaimer in the
  documentation and/or other materials provided with the distribution.
 
THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
</pre>
</pre>


A third requirement is sometimes included: "3. The name of the author may not be used to endorse or promote products derived from this software without specific prior written permission.
== License Headers (Deprecated) ==
Traditional license headers for stating licenses in source code files is deprecated and shall only be used to maintain consistency inside a repository.


The advertising clause requiring mention in adverts must never be included.


== X11 License ==
= Changelog =
<pre>
Copyright <year>  <name of author> <e-mail>
 
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:


The above copyright notice and this permission notice shall be included in
== January 2023 ==
all copies or substantial portions of the Software.
* Clarify usage of BSD licence variants, based on a discussion on the kde-community mailing list (https://mail.kde.org/pipermail/kde-community/2022q4/007400.html).


THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
== September 2021 ==
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* Added ODbL-1.0 for geographic data derived from OSM, based on a discussion on the kde-communit and kde-frameworks-devel mailing lists (https://mail.kde.org/pipermail/kde-community/2021q3/007064.html).
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
X CONSORTIUM BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN
AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.


Except as contained in this notice, the name of the X Consortium shall not be
== December 2020 ==
used in advertising or otherwise to promote the sale, use or other dealings
* Clarified that CMake license requirements apply to all CMake code as discussed in 'CMake source files without license' on kde-devel list.
in this Software without prior written authorization from the X Consortium.
</pre>


== MIT license ==
== September 2020 ==
<pre>
* Clarified that non copyrightable data shall shave CC0-1.0.
Copyright <year>  <name of author> <e-mail>


Permission is hereby granted, free of charge, to any person obtaining
== June 2020 ==
a copy of this software and associated documentation files (the
* Reshuffled template blobs. No longer offering templates for the deprecated header formats.
"Software"), to deal in the Software without restriction, including
without limitation the rights to use, copy, modify, merge, publish,
distribute, sublicense, and/or sell copies of the Software, and to
permit persons to whom the Software is furnished to do so, subject to
the following conditions:


The above copyright notice and this permission notice shall be included
== January 2020 ==
in all copies or substantial portions of the Software.
* update deprecated SPDX identifiers
* allow REUSE.software compatible license statements as an alternative to license headers
* define SPDX compatible license statements for later version of GPL and LGPL
* define SPDX based license statements


THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
== July 2017 ==
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
</pre>
 
= Changelog =
== February 2017 WIP ==
* Note that Qt is LGPL 3 not 2.1
* Note that Qt is LGPL 3 not 2.1
* Code copied from Qt can be GPL 3 as well as GPL 2, check comparible with your code
* Code copied from Qt can be GPL 3 as well as GPL 2, check comparible with your code
* Allow AGPL for web apps
* Allow AGPL for web apps
* Encourage AGPL for web apps
* Encourage AGPL for web apps
* Move to CC-BY-SA 4 for icons, media files and documentation (wikis), rationale: maintained, international, interchangeable w/ major wikis, docs, LGPL
* Allow icons to be CC-BY-SA 4
* Allow media files to be CC-BY-SA 4 and no longer allow CC-BY-SA 3
* Note CC-BY-SA 4 is LGPL 3 compatible
* Note CC-BY-SA 4 is LGPL 3 compatible
* Documentation to be CC-BY-SA 4
* MIT text now one of the more standard variants (modern style with sublicence)
* MIT text now one of the more standard variants (modern style with sublicence)
* Links to SPDX licences
* Dissallow Facebook's additional grant of patent rights
* require (L)GPL2+3+eV with option of other stuff to give a clear indication of which is preferred
* remove licence option of GPL2+3 only for FLA signers, nobody uses it and it's the same as GPL2+3+eV
* Note images must have SVG committed with it
* re-order license headers to make 2+3+KDEeV the main option


[[Category:Policies]]
[[Category:Policies]]

Latest revision as of 15:21, 31 December 2022

This licence policy is designed to allow maximum code reuse with the community of KDE and beyond while making exceptions for the few cases which need it.

Guidelines and best practices for applying this policy can be found in the Licensing HowTo.

Policy

All new source code and related data files in KDE repositories (SVN, Git) must meet the following requirements:

  1. All files must be in their preferred modifiable form, or alongside the file which is the preferred modifiable form. In the 'alongside' case, there must be clear instructions for how to build using the preferred modifiable form.
  2. All source files must contain a copyright header which identifies the copyright holder(s) together with an e-mail address that can be used to reach the copyright holder.
  3. Each source file either must contain SPDX identifiers or licence headers to state under which terms the software may be used, modified and redistributed. The SPDX identifiers or licence headers stated below must be used. Inside one repository all files shall follow the same system for licence statements.
    1. For each used SPDX identifier, the licence text must be included compatible with the SPDX specification.
  4. Source files that are part of a library with a public API which is part of the KDE Platform (kdelibs, kdepimlibs, kde-runtime and KDE Frameworks) must be licensed under:
    They may also be licensed under one of the following terms if it helps with license compatibility:
    • LGPL-2.1-or-later: LGPL version 2.1 or later
    • BSD-2-Clause: BSD-2-Clause license as listed below.
    • BSD-3-Clause: BSD-3-Clause license as listed below.
      Note: It is strongly discouraged to use the BSD-3-Clause license. It makes sharing code within KDE more complicated and isn’t of much benefit. Unless you must use it (for example because of upstream compatibility), use the BSD-2-Clause instead.
    • MIT: MIT license as listed below.
    • X11: X11 license as listed below.
    Note: each bulletpoint above is a single option, it can not be licenced under just part of one bulletpoint option
    Note: code may not be copied from Qt into KDE Platform as Qt is LGPL 3 only which would prevent it being used under LGPL 2.1
    Note: the LGPL 2.1, 3 or approved by e.V. option is preferred and should be used unless there are special needs to improve code shareability
  5. Any other source files must be licensed under one of the terms listed under 4) or:
    They may also be licensed under one of the following terms if it helps with license compatibility:
    • GPL-2.0-or-later: GPL version 2 or later
    • GPL-3.0-or-later: GPL version 3 or later
    • GPL-3-0-only OR LicenseRef-KDE-Accepted-GPL: GPL version 3 or later versions approved by the membership of KDE e.V.
    • Code copied from Qt may be licenced under GPL version 2 or later versions or under GPL version 3 or later versions depending on the licence of the relevant Qt code
    Note: each bulletpoint above is a single option, it can not be licenced under just part of one bulletpoint option
    Note: where a KDE repository contains files which are GPL 3+ and where the licence is stated with license headers, it must be clearly marked by adding the full licence in a file called COPYING.GPL3 in the top directory of the repository
    Note: Qt modules are either GPL2+ or GPL 3+, ensure the licence is compatible with your code before copying code from Qt
  6. Applications which are intended to be run on a server may be licenced under the AGPL-3.0-or-later: GNU AGPL or later
    Note: the GNU AGPL is the recommended licence for server software in KDE
  7. Translations of text from the files described in section 4 must be licenced under one of the terms in sections 4. Translations of text from other files must be licenced under one of the terms in sections 4 or 5.
  8. Media files such as images may be licensed under the CC-BY-SA-4.0 or compatible licence.
    Note: Image files must be committed together with their preferred modifiable form such as SVG.
    Note: CC-BY-SA 4.0 can be one-way converted to GPL 3.
  9. Icons should be licenced as CC-BY-SA 4.0 or can also be licenced under any of the terms in section 4 or 5 or 8. Icons in oxygen-icons and breeze-icons themes must be licenced under the "LGPL-3.0-only OR LicenseRef-KDE-Accepted-LGPL", i.e. LGPL 3 or later versions approved by KDE e.V.
  10. Content on collaborative edited websites such as wikis must be licensed under the Creative Commons Attribution-Sharealike 4.0 International or compatible licence.
  11. Documentation must be licensed under the CC-BY-SA-4.0 or compatible licence
    Note: CC-BY-SA 4.0 can be one-way converted to GPL 3.
  12. Documentation started before 2017 can be licensed under one of the following terms:
    • FDL versions 1.2 or later versions with no Invariant Sections, no Front-Cover Texts, and no Back-Cover Texts.
    • FDL versions 1.2 or later versions approved by KDE e.V. with no Invariant Sections, no Front-Cover Texts, and no Back-Cover Texts.
    Note each bulletpoint above is a single option, it can not be licenced under just part of one bulletpoint option
    Documentation may additionally be licensed under any of the terms in section 4 or 5.
  13. CMake code must be licenced under the BSD-2-Clause license as listed below or the BSD-3-Clause licence as listed below.
    Note: It is strongly discouraged to use the BSD-3-Clause license. It makes sharing code within KDE more complicated and isn’t of much benefit. Unless you must use it (for example because of upstream compatibility), use the BSD-2-Clause instead.
  14. Windows installer files using the WiX Toolset may be licenced under the Common Public Licence 1.0
  15. Other copyrightable data included in KDE's codebase must be licensed under one of the terms in Sections 4 or 5. If a file is not copyrightable (e.g. it is an automatically generated file, a trivial list of files, or trivial test data) it shall have the CC0-1.0 license.
  16. As new versions of GNU licenses are published they will be discussed by the membership of KDE e.V. and accepted via an announcement on https://ev.kde.org whether we will adopt it. This will depend on if adopting the licence would harm the future distribution of KDE, if the licence preserves freedom for our developers & users and a vote by the membership agrees to the acceptance of the new licence version. When using the SPDX identifiers LicenseRef-KDE-Accepted-GPL or LicenseRef-KDE-Accepted-LGPL to express this, the respective license text must be placed according to the REUSE specification in the repository, as stated below.
  17. Geographic data, in particular data based on or derived from OpenStreetMap may be licensed under the Open Data Commons Open Database License v1.0.

License Statements

The REUSE Specification - Version 3.0 shall be applied when stating licenses and when adding license files to a project.

SPDX Statements

Each plain text file that can contain comments must contain comments at the top of the file (comment header) that declare that file’s copyright and licensing information. The comment header must contain one or more copyright tags and one SPDX-License-Identifier tag.

For copyright statements either a SPDX-FileCopyrightText tag followed by a colon can be used or the word Copyright, in which case a colon is not needed.

The SPDX-License-Identifier tag must be followed by a valid SPDX License Expression describing the licensing of the file (example: SPDX-License-Identifier: LGPL-2.1-or-later OR MIT).

License Texts

The repository must include a LICENSES/ directory in the root of the repository, which contains the license text for every used license inside the repository. Each license file shall be a plain text file that is placed in this directory and the name of the license file must be the SPDX License Identifier of the license followed by ".txt" (example: LICENSES/LGPL-2.1-or-later.txt). The directory must not include license files for licenses that are not used inside the repository.

The license files shall be taken from [1]. It is preferred to use the reuse command line tool's download option to avoid copy-paste errors. For LicenseRef-KDE-Accepted-LGPL and LicenseRef-KDE-Accepted-GPL licenses, see below.

LicenseRef-KDE-Accepted-LGPL

When using the LicenseRef-KDE-Accepted-LGPL identifier inside a project, the following file LICENSES/LicenseRef-KDE-Accepted-LGPL.txt must be added to the project with the following content:

This library is free software; you can redistribute it and/or
modify it under the terms of the GNU Lesser General Public
License as published by the Free Software Foundation; either
version 3 of the license or (at your option) any later version
that is accepted by the membership of KDE e.V. (or its successor
approved by the membership of KDE e.V.), which shall act as a
proxy as defined in Section 6 of version 3 of the license.

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.

LicenseRef-KDE-Accepted-GPL

When using the LicenseRef-KDE-Accepted-GPL identifier inside a project, the following file LICENSES/LicenseRef-KDE-Accepted-GPL.txt must be added to the project with the following content:

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) at any later version that is
accepted by the membership of KDE e.V. (or its successor
approved by the membership of KDE e.V.), which shall act as a
proxy as defined in Section 14 of version 3 of the license.

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.

Templates

GPL (GPL-2.0-only OR GPL-3.0-only OR LicenseRef-KDE-Accepted-GPL)

SPDX-License-Identifier: GPL-2.0-only OR GPL-3.0-only OR LicenseRef-KDE-Accepted-GPL
SPDX-FileCopyrightText: <year> <name of author> <e-mail>

LGPL (LGPL-2.1-only OR LGPL-3.0-only OR LicenseRef-KDE-Accepted-LGPL)

SPDX-License-Identifier: LGPL-2.1-only OR LGPL-3.0-only OR LicenseRef-KDE-Accepted-LGPL
SPDX-FileCopyrightText: <year> <name of author> <e-mail>

Alternative Licenses Allowed for License Compatibility

GPL-2.0-or-later
SPDX-License-Identifier: GPL-2.0-or-later
SPDX-FileCopyrightText: <year> <name of author> <e-mail>
GPL-3.0-only OR LicenseRef-KDE-Accepted-GPL
SPDX-License-Identifier: GPL-3.0-only OR LicenseRef-KDE-Accepted-GPL
SPDX-FileCopyrightText: <year> <name of author> <e-mail>
GPL-3.0-or-later
SPDX-License-Identifier: GPL-3.0-or-later
SPDX-FileCopyrightText: <year> <name of author> <e-mail>
LGPL-2.1-or-later
SPDX-License-Identifier: LGPL-2.1-or-later
SPDX-FileCopyrightText: <year> <name of author> <e-mail>
BSD-2-Clause
SPDX-License-Identifier: BSD-2-Clause
SPDX-FileCopyrightText: <year> <name of author> <e-mail>

Note: SPDX lists a half-dozen BSD-2-Clause variants, but you must use exclusively the one listed here.

BSD-3-Clause
SPDX-License-Identifier: BSD-3-Clause
SPDX-FileCopyrightText: <year> <name of author> <e-mail>

Note: SPDX lists a half-dozen BSD-3-Clause variants, but you must use exclusively the one listed here.

X11
SPDX-License-Identifier: X11
SPDX-FileCopyrightText: <year> <name of author> <e-mail>
MIT
SPDX-License-Identifier: MIT
SPDX-FileCopyrightText: <year> <name of author> <e-mail>

License Headers (Deprecated)

Traditional license headers for stating licenses in source code files is deprecated and shall only be used to maintain consistency inside a repository.


Changelog

January 2023

September 2021

December 2020

  • Clarified that CMake license requirements apply to all CMake code as discussed in 'CMake source files without license' on kde-devel list.

September 2020

  • Clarified that non copyrightable data shall shave CC0-1.0.

June 2020

  • Reshuffled template blobs. No longer offering templates for the deprecated header formats.

January 2020

  • update deprecated SPDX identifiers
  • allow REUSE.software compatible license statements as an alternative to license headers
  • define SPDX compatible license statements for later version of GPL and LGPL
  • define SPDX based license statements

July 2017

  • Note that Qt is LGPL 3 not 2.1
  • Code copied from Qt can be GPL 3 as well as GPL 2, check comparible with your code
  • Allow AGPL for web apps
  • Encourage AGPL for web apps
  • Allow icons to be CC-BY-SA 4
  • Allow media files to be CC-BY-SA 4 and no longer allow CC-BY-SA 3
  • Note CC-BY-SA 4 is LGPL 3 compatible
  • Documentation to be CC-BY-SA 4
  • MIT text now one of the more standard variants (modern style with sublicence)
  • Links to SPDX licences
  • Dissallow Facebook's additional grant of patent rights
  • require (L)GPL2+3+eV with option of other stuff to give a clear indication of which is preferred
  • remove licence option of GPL2+3 only for FLA signers, nobody uses it and it's the same as GPL2+3+eV
  • Note images must have SVG committed with it
  • re-order license headers to make 2+3+KDEeV the main option