forked from mirrors/nixpkgs
Merge pull request #238456 from apfelkuchen6/texlive-licenses
texlive: add licensing information
This commit is contained in:
commit
adae46b073
|
@ -98,6 +98,11 @@ in mkLicense lset) ({
|
||||||
fullName = "Artistic License 1.0";
|
fullName = "Artistic License 1.0";
|
||||||
};
|
};
|
||||||
|
|
||||||
|
artistic1-cl8 = {
|
||||||
|
spdxId = "Artistic-1.0-cl8";
|
||||||
|
fullName = "Artistic License 1.0 w/clause 8";
|
||||||
|
};
|
||||||
|
|
||||||
artistic2 = {
|
artistic2 = {
|
||||||
spdxId = "Artistic-2.0";
|
spdxId = "Artistic-2.0";
|
||||||
fullName = "Artistic License 2.0";
|
fullName = "Artistic License 2.0";
|
||||||
|
@ -295,11 +300,26 @@ in mkLicense lset) ({
|
||||||
free = false;
|
free = false;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
cc-by-sa-10 = {
|
||||||
|
spdxId = "CC-BY-SA-1.0";
|
||||||
|
fullName = "Creative Commons Attribution Share Alike 1.0";
|
||||||
|
};
|
||||||
|
|
||||||
|
cc-by-sa-20 = {
|
||||||
|
spdxId = "CC-BY-SA-2.0";
|
||||||
|
fullName = "Creative Commons Attribution Share Alike 2.0";
|
||||||
|
};
|
||||||
|
|
||||||
cc-by-sa-25 = {
|
cc-by-sa-25 = {
|
||||||
spdxId = "CC-BY-SA-2.5";
|
spdxId = "CC-BY-SA-2.5";
|
||||||
fullName = "Creative Commons Attribution Share Alike 2.5";
|
fullName = "Creative Commons Attribution Share Alike 2.5";
|
||||||
};
|
};
|
||||||
|
|
||||||
|
cc-by-10 = {
|
||||||
|
spdxId = "CC-BY-1.0";
|
||||||
|
fullName = "Creative Commons Attribution 1.0";
|
||||||
|
};
|
||||||
|
|
||||||
cc-by-30 = {
|
cc-by-30 = {
|
||||||
spdxId = "CC-BY-3.0";
|
spdxId = "CC-BY-3.0";
|
||||||
fullName = "Creative Commons Attribution 3.0";
|
fullName = "Creative Commons Attribution 3.0";
|
||||||
|
@ -486,6 +506,16 @@ in mkLicense lset) ({
|
||||||
url = "http://www.schristiancollins.com/generaluser.php"; # license included in sources
|
url = "http://www.schristiancollins.com/generaluser.php"; # license included in sources
|
||||||
};
|
};
|
||||||
|
|
||||||
|
gfl = {
|
||||||
|
fullName = "GUST Font License";
|
||||||
|
url = "http://www.gust.org.pl/fonts/licenses/GUST-FONT-LICENSE.txt";
|
||||||
|
};
|
||||||
|
|
||||||
|
gfsl = {
|
||||||
|
fullName = "GUST Font Source License";
|
||||||
|
url = "http://www.gust.org.pl/fonts/licenses/GUST-FONT-SOURCE-LICENSE.txt";
|
||||||
|
};
|
||||||
|
|
||||||
gpl1Only = {
|
gpl1Only = {
|
||||||
spdxId = "GPL-1.0-only";
|
spdxId = "GPL-1.0-only";
|
||||||
fullName = "GNU General Public License v1.0 only";
|
fullName = "GNU General Public License v1.0 only";
|
||||||
|
@ -626,6 +656,11 @@ in mkLicense lset) ({
|
||||||
free = false;
|
free = false;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
knuth = {
|
||||||
|
fullName = "Knuth CTAN License";
|
||||||
|
spdxId = "Knuth-CTAN";
|
||||||
|
};
|
||||||
|
|
||||||
lal12 = {
|
lal12 = {
|
||||||
spdxId = "LAL-1.2";
|
spdxId = "LAL-1.2";
|
||||||
fullName = "Licence Art Libre 1.2";
|
fullName = "Licence Art Libre 1.2";
|
||||||
|
@ -702,11 +737,21 @@ in mkLicense lset) ({
|
||||||
url = "https://opensource.franz.com/preamble.html";
|
url = "https://opensource.franz.com/preamble.html";
|
||||||
};
|
};
|
||||||
|
|
||||||
|
lppl1 = {
|
||||||
|
spdxId = "LPPL-1.0";
|
||||||
|
fullName = "LaTeX Project Public License v1.0";
|
||||||
|
};
|
||||||
|
|
||||||
lppl12 = {
|
lppl12 = {
|
||||||
spdxId = "LPPL-1.2";
|
spdxId = "LPPL-1.2";
|
||||||
fullName = "LaTeX Project Public License v1.2";
|
fullName = "LaTeX Project Public License v1.2";
|
||||||
};
|
};
|
||||||
|
|
||||||
|
lppl13a = {
|
||||||
|
spdxId = "LPPL-1.3a";
|
||||||
|
fullName = "LaTeX Project Public License v1.3a";
|
||||||
|
};
|
||||||
|
|
||||||
lppl13c = {
|
lppl13c = {
|
||||||
spdxId = "LPPL-1.3c";
|
spdxId = "LPPL-1.3c";
|
||||||
fullName = "LaTeX Project Public License v1.3c";
|
fullName = "LaTeX Project Public License v1.3c";
|
||||||
|
|
|
@ -17,6 +17,12 @@ let
|
||||||
pkgList = rec {
|
pkgList = rec {
|
||||||
combined = combinePkgs (lib.attrValues pkgSet);
|
combined = combinePkgs (lib.attrValues pkgSet);
|
||||||
all = lib.filter pkgFilter combined;
|
all = lib.filter pkgFilter combined;
|
||||||
|
licenses = let
|
||||||
|
concatLicenses = lib.foldl (acc: el: if builtins.elem el acc then acc else acc ++ [ el ]);
|
||||||
|
in lib.foldl
|
||||||
|
(acc: pkg:
|
||||||
|
concatLicenses acc (lib.toList (pkg.meta.license or [])))
|
||||||
|
[] all;
|
||||||
splitBin = builtins.partition (p: p.tlType == "bin") all;
|
splitBin = builtins.partition (p: p.tlType == "bin") all;
|
||||||
bin = splitBin.right
|
bin = splitBin.right
|
||||||
++ lib.optional
|
++ lib.optional
|
||||||
|
@ -84,6 +90,7 @@ let
|
||||||
in (buildEnv {
|
in (buildEnv {
|
||||||
|
|
||||||
inherit name;
|
inherit name;
|
||||||
|
meta.license = pkgList.licenses;
|
||||||
|
|
||||||
ignoreCollisions = false;
|
ignoreCollisions = false;
|
||||||
|
|
||||||
|
|
|
@ -44,6 +44,11 @@ let
|
||||||
deps = (orig.xdvi.deps or []) ++ [ "metafont" ];
|
deps = (orig.xdvi.deps or []) ++ [ "metafont" ];
|
||||||
};
|
};
|
||||||
|
|
||||||
|
arabi-add = orig.arabi-add // {
|
||||||
|
# tlpdb lists license as "unknown", but the README says lppl13: http://mirrors.ctan.org/language/arabic/arabi-add/README
|
||||||
|
license = [ "lppl13c" ];
|
||||||
|
};
|
||||||
|
|
||||||
# remove dependency-heavy packages from the basic collections
|
# remove dependency-heavy packages from the basic collections
|
||||||
collection-basic = orig.collection-basic // {
|
collection-basic = orig.collection-basic // {
|
||||||
deps = lib.filter (n: n != "metafont" && n != "xdvi") orig.collection-basic.deps;
|
deps = lib.filter (n: n != "metafont" && n != "xdvi") orig.collection-basic.deps;
|
||||||
|
@ -179,6 +184,9 @@ let
|
||||||
in runCommand "texlive-${tlName}"
|
in runCommand "texlive-${tlName}"
|
||||||
( {
|
( {
|
||||||
src = fetchurl { inherit urls sha512; };
|
src = fetchurl { inherit urls sha512; };
|
||||||
|
meta = {
|
||||||
|
license = map (x: lib.licenses.${x}) (args.license or []);
|
||||||
|
};
|
||||||
inherit stripPrefix tlType;
|
inherit stripPrefix tlType;
|
||||||
# metadata for texlive.combine
|
# metadata for texlive.combine
|
||||||
passthru = {
|
passthru = {
|
||||||
|
|
|
@ -36,6 +36,33 @@ $a}
|
||||||
/^catalogue-version/s/[\#,:\(\)]//g
|
/^catalogue-version/s/[\#,:\(\)]//g
|
||||||
s/^catalogue-version_(.*)/ version = "\1";/p
|
s/^catalogue-version_(.*)/ version = "\1";/p
|
||||||
|
|
||||||
|
/^catalogue-license/{
|
||||||
|
# wrap licenses in quotes
|
||||||
|
s/ ([^ ]+)/ "\1"/g
|
||||||
|
# adjust naming as in nixpkgs, the full texts of the licenses are available at https://www.ctan.org/license/${licenseName}
|
||||||
|
s/"(cc-by(-sa)?-[1-4])"/"\10"/g
|
||||||
|
s/"apache2"/"asl20"/g
|
||||||
|
s/"artistic"/"artistic1-cl8"/g
|
||||||
|
s/"bsd"/"bsd3"/g # license text does not match exactly, but is pretty close
|
||||||
|
s/"bsd4"/"bsdOriginal"/g
|
||||||
|
s/"collection"/"free"/g # used for collections of individual packages with distinct licenses. As TeXlive only contains free software, we can use "free" as a catchall
|
||||||
|
s/"fdl"/"fdl13Only"/g
|
||||||
|
s/"gpl1?"/"gpl1Only"/g
|
||||||
|
s/"gpl2\+"/"gpl2Plus"/g
|
||||||
|
s/"gpl3\+"/"gpl3Plus"/g
|
||||||
|
s/"lgpl"/"lgpl2"/g
|
||||||
|
s/"lgpl2\.1"/"lgpl21"/g
|
||||||
|
s/"lppl"/"lppl13c"/g # not used consistently, sometimes "lppl" refers to an older version of the license
|
||||||
|
s/"lppl1\.2"/"lppl12"/g
|
||||||
|
s/"lppl1\.3"/"lppl13c"/g # If a work refers to LPPL 1.3 as its license, this is interpreted as the latest version of the 1.3 license (https://www.latex-project.org/lppl/)
|
||||||
|
s/"lppl1\.3a"/"lppl13a"/g
|
||||||
|
s/"lppl1\.3c"/"lppl13c"/g
|
||||||
|
s/"other-free"/"free"/g
|
||||||
|
s/"pd"/"publicDomain"/g
|
||||||
|
|
||||||
|
s/^catalogue-license (.*)/ license = [ \1 ];/p
|
||||||
|
}
|
||||||
|
|
||||||
# extract deps
|
# extract deps
|
||||||
/^depend ([^.]+|texlive\.infra)$/{
|
/^depend ([^.]+|texlive\.infra)$/{
|
||||||
# open a list
|
# open a list
|
||||||
|
|
File diff suppressed because it is too large
Load diff
Loading…
Reference in a new issue