[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
97/97: guix: texlive importer: Adjust to generate new source format.
From: |
guix-commits |
Subject: |
97/97: guix: texlive importer: Adjust to generate new source format. |
Date: |
Fri, 21 Jun 2024 06:41:40 -0400 (EDT) |
ngz pushed a commit to branch tex-team
in repository guix.
commit bbebfd9a98e5240d2d40745621bd8e1a82477519
Author: Nicolas Goaziou <mail@nicolasgoaziou.fr>
AuthorDate: Fri Jun 21 12:26:10 2024 +0200
guix: texlive importer: Adjust to generate new source format.
* guix/import/texlive.scm (tlpdb->package): Adjust source according to new
format.
* tests/texlive.scm (%fake-tlpdb): Add database revision.
("texlive->guix-package, no docfiles"):
("texlive->guix-package"):
("texlive->guix-package, with catalogue entry, no inputs"):
("texlive->guix-package, multiple licenses"):
("texlive->guix-package, with TeX format"): Update checks.
Change-Id: I60d5fe0f5f8db194c679dcb262f64c824cd19909
---
guix/import/texlive.scm | 27 +++++++++------
tests/texlive.scm | 88 ++++++++++++++++++++++++++++++++-----------------
2 files changed, 75 insertions(+), 40 deletions(-)
diff --git a/guix/import/texlive.scm b/guix/import/texlive.scm
index aff69f1272..24817db31d 100644
--- a/guix/import/texlive.scm
+++ b/guix/import/texlive.scm
@@ -618,16 +618,23 @@ at VERSION."
`(package
(name ,name)
(version ,(if empty-package? '%texlive-version version))
- (source ,(and (not meta-package?)
- `(texlive-origin
- name version
- (list ,@(svn-multi-reference-locations reference))
- (base32
- ,(bytevector->nix-base32-string
- (let-values (((port get-hash) (open-sha256-port)))
- (write-file source port)
- (force-output port)
- (get-hash)))))))
+ (source
+ ,(and (not meta-package?)
+ `(origin
+ (method svn-multi-fetch)
+ (uri (svn-multi-reference
+ (url (texlive-packages-repository version))
+ (revision ,(svn-multi-reference-revision reference))
+ (locations
+ (list ,@(svn-multi-reference-locations
reference)))))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32
+ ,(bytevector->nix-base32-string
+ (let-values (((port get-hash) (open-sha256-port)))
+ (write-file source port)
+ (force-output port)
+ (get-hash))))))))
,@(if (assoc-ref data 'docfiles)
'((outputs '("out" "doc")))
'())
diff --git a/tests/texlive.scm b/tests/texlive.scm
index 39f7a8f856..0e21c2e9b0 100644
--- a/tests/texlive.scm
+++ b/tests/texlive.scm
@@ -32,7 +32,8 @@
(test-begin "texlive")
(define %fake-tlpdb
- '(("12many"
+ '((database-revision . 12345)
+ ("12many"
. ((name
. "12many")
(catalogue
@@ -375,10 +376,15 @@ completely compatible with Plain TeX.")
(('package
('name "texlive-example")
('version _)
- ('source ('texlive-origin
- 'name 'version
- ('list "tex/latex/example/")
- ('base32 (? string? hash))))
+ ('source ('origin
+ ('method 'svn-multi-fetch)
+ ('uri ('svn-multi-reference
+ ('url ('texlive-packages-repository 'version))
+ ('revision 12345)
+ ('locations ('list "tex/latex/example/"))))
+ ('file-name ('git-file-name 'name 'version))
+ ('sha256
+ ('base32 (? string? hash)))))
('build-system 'texlive-build-system)
('home-page (? string?))
('synopsis (? string?))
@@ -409,15 +415,21 @@ completely compatible with Plain TeX.")
(('package
('name "texlive-texsis")
('version _)
- ('source ('texlive-origin
- 'name 'version
- ('list "bibtex/bst/texsis/"
- "doc/man/man1/texsis.1"
- "doc/man/man1/texsis.man1.pdf"
- "doc/otherformats/texsis/base/"
- "tex/texsis/base/"
- "tex/texsis/config/")
- ('base32 (? string? hash))))
+ ('source ('origin
+ ('method 'svn-multi-fetch)
+ ('uri ('svn-multi-reference
+ ('url ('texlive-packages-repository 'version))
+ ('revision 12345)
+ ('locations
+ ('list "bibtex/bst/texsis/"
+ "doc/man/man1/texsis.1"
+ "doc/man/man1/texsis.man1.pdf"
+ "doc/otherformats/texsis/base/"
+ "tex/texsis/base/"
+ "tex/texsis/config/"))))
+ ('file-name ('git-file-name 'name 'version))
+ ('sha256
+ ('base32 (? string? hash)))))
('outputs ''("out" "doc"))
('build-system 'texlive-build-system)
('propagated-inputs
@@ -489,12 +501,17 @@ completely compatible with Plain TeX.")
(('package
('name "texlive-12many")
('version _)
- ('source ('texlive-origin
- 'name 'version
- ('list "doc/latex/12many/"
- "source/latex/12many/"
- "tex/latex/12many/")
- ('base32 (? string? hash))))
+ ('source ('origin
+ ('method 'svn-multi-fetch)
+ ('uri ('svn-multi-reference
+ ('url ('texlive-packages-repository 'version))
+ ('revision 12345)
+ ('locations ('list "doc/latex/12many/"
+ "source/latex/12many/"
+ "tex/latex/12many/"))))
+ ('file-name ('git-file-name 'name 'version))
+ ('sha256
+ ('base32 (? string? hash)))))
('outputs ''("out" "doc"))
('build-system 'texlive-build-system)
('home-page "https://ctan.org/pkg/one2many")
@@ -526,11 +543,17 @@ completely compatible with Plain TeX.")
(('package
('name "texlive-chs-physics-report")
('version _)
- ('source ('texlive-origin
- 'name 'version
- ('list "doc/latex/chs-physics-report/"
- "tex/latex/chs-physics-report/")
- ('base32 (? string? hash))))
+ ('source ('origin
+ ('method 'svn-multi-fetch)
+ ('uri ('svn-multi-reference
+ ('url ('texlive-packages-repository 'version))
+ ('revision 12345)
+ ('locations
+ ('list "doc/latex/chs-physics-report/"
+ "tex/latex/chs-physics-report/"))))
+ ('file-name ('git-file-name 'name 'version))
+ ('sha256
+ ('base32 (? string? hash)))))
('outputs ''("out" "doc"))
('build-system 'texlive-build-system)
('home-page (? string?))
@@ -598,11 +621,16 @@ completely compatible with Plain TeX.")
(('package
('name "texlive-lollipop")
('version _)
- ('source ('texlive-origin
- 'name 'version
- ('list "doc/otherformats/lollipop/"
- "tex/lollipop/")
- ('base32 (? string? hash))))
+ ('source ('origin
+ ('method 'svn-multi-fetch)
+ ('uri ('svn-multi-reference
+ ('url ('texlive-packages-repository 'version))
+ ('revision 12345)
+ ('locations ('list
"doc/otherformats/lollipop/"
+ "tex/lollipop/"))))
+ ('file-name ('git-file-name 'name 'version))
+ ('sha256
+ ('base32 (? string? hash)))))
('outputs ''("out" "doc"))
('build-system 'texlive-build-system)
('arguments ('list '#:create-formats ('gexp ('list
"lollipop"))))
- 64/97: gnu: Add texlive-xml2pmx-bin., (continued)
- 64/97: gnu: Add texlive-xml2pmx-bin., guix-commits, 2024/06/21
- 72/97: gnu: texlive-xindy: Build binary separately., guix-commits, 2024/06/21
- 73/97: guix: import texlive: Propagate binaries when necessary., guix-commits, 2024/06/21
- 82/97: guix: import texlive: Rename some functions., guix-commits, 2024/06/21
- 81/97: guix: import texlive: Remove need for having "svn" binary in PATH., guix-commits, 2024/06/21
- 80/97: gnu: texlive-hyphen-complete: Fix locations., guix-commits, 2024/06/21
- 86/97: guix: import texlive: Factorize package inputs listing., guix-commits, 2024/06/21
- 85/97: guix: import texlive: Move a comment., guix-commits, 2024/06/21
- 87/97: guix: import texlive: Handle versions., guix-commits, 2024/06/21
- 93/97: gnu: Factorize URLs relative to TeX Live., guix-commits, 2024/06/21
- 97/97: guix: texlive importer: Adjust to generate new source format.,
guix-commits <=
- 96/97: gnu: texlive-scripts: Add missing file name for checkout., guix-commits, 2024/06/21
- 62/97: gnu: Add texlive-xpdfopen-bin., guix-commits, 2024/06/21
- 76/97: gnu: texlive-xits: Fix typo in description., guix-commits, 2024/06/21
- 88/97: guix: import texlive: Implement auto-updates., guix-commits, 2024/06/21
- 84/97: guix: import texlive: Remove `files-differ?' function., guix-commits, 2024/06/21
- 95/97: gnu: Remove artefacts from previous TeX Live packaging., guix-commits, 2024/06/21
- 94/97: gnu: Refactor TeX Live packages to refer to SVN directly., guix-commits, 2024/06/21