diff options
author | Liliana Marie Prikler <liliana.prikler@gmail.com> | 2023-07-30 08:46:07 +0200 |
---|---|---|
committer | Liliana Marie Prikler <liliana.prikler@gmail.com> | 2023-07-30 08:46:42 +0200 |
commit | 4eca7833ef0b16fb3cdda138e3ee1e5824c36e41 (patch) | |
tree | a87586e931bd51f2e87d07b5fbdd83bce0ccaacd /guix | |
parent | 4c204d01d57ac7da11a5772d5d4e3254d1c2408f (diff) | |
parent | 6a2b5c66bf57bd1bbc6300e1f99e16e65f2478e8 (diff) | |
download | guix-4eca7833ef0b16fb3cdda138e3ee1e5824c36e41.tar guix-4eca7833ef0b16fb3cdda138e3ee1e5824c36e41.tar.gz |
Merge branch 'master' into gnome-team
Diffstat (limited to 'guix')
-rw-r--r-- | guix/build/download-nar.scm | 33 | ||||
-rw-r--r-- | guix/profiles.scm | 17 | ||||
-rw-r--r-- | guix/scripts/system.scm | 2 | ||||
-rw-r--r-- | guix/transformations.scm | 46 |
4 files changed, 56 insertions, 42 deletions
diff --git a/guix/build/download-nar.scm b/guix/build/download-nar.scm index 1b5b5503eb..3ba121b7fb 100644 --- a/guix/build/download-nar.scm +++ b/guix/build/download-nar.scm @@ -73,29 +73,34 @@ success, #f otherwise." (catch #t (lambda () (http-fetch (string->uri url))) - (lambda args + (lambda (key . args) + (format #t "Unable to fetch from ~a, ~a: ~a~%" + (uri-host (string->uri url)) + key + args) (values #f #f))))) (if (not port) (loop rest) - (let* ((reporter (progress-reporter/file - url - size - (current-error-port) - #:abbreviation nar-uri-abbreviation)) - (port-with-progress - (progress-report-port reporter port - #:download-size size))) + (begin (if size (format #t "Downloading from ~a (~,2h MiB)...~%" url (/ size (expt 2 20.))) (format #t "Downloading from ~a...~%" url)) - (if (string-contains url "/lzip") - (restore-lzipped-nar port-with-progress - item - size) - (begin + (let* ((reporter (progress-reporter/file + url + size + (current-error-port) + #:abbreviation nar-uri-abbreviation)) + (port-with-progress + (progress-report-port reporter port + #:download-size size))) + (if (string-contains url "/lzip") + (restore-lzipped-nar port-with-progress + item + size) (restore-file port-with-progress item))) + (newline) #t)))) (() #f)))) diff --git a/guix/profiles.scm b/guix/profiles.scm index 605d43f111..4835def536 100644 --- a/guix/profiles.scm +++ b/guix/profiles.scm @@ -1815,6 +1815,21 @@ MANIFEST." #:create-all-directories? #t #:log-port (%make-void-port "w")) + ;; Clear files that are going to be regenerated. + (with-directory-excursion "/tmp/texlive/share/texmf-dist" + (for-each delete-file + (list "fonts/map/dvipdfmx/updmap/kanjix.map" + "fonts/map/dvips/updmap/builtin35.map" + "fonts/map/dvips/updmap/download35.map" + "fonts/map/dvips/updmap/ps2pk.map" + "fonts/map/dvips/updmap/psfonts.map" + "fonts/map/dvips/updmap/psfonts_pk.map" + "fonts/map/dvips/updmap/psfonts_t1.map" + "fonts/map/pdftex/updmap/pdftex.map" + "fonts/map/pdftex/updmap/pdftex_dl14.map" + "fonts/map/pdftex/updmap/pdftex_ndl14.map" + "web2c/updmap.cfg"))) + ;; XXX: This is annoying, but it's necessary because ;; texlive-libkpathsea does not provide wrapped executables. (setenv "PATH" @@ -1866,8 +1881,6 @@ MANIFEST." (let ((a (string-append #$output "/share/texmf-dist")) (b "/tmp/texlive/share/texmf-dist") (mktexlsr #$(file-append texlive-scripts "/bin/mktexlsr"))) - ;; Ignore original "updmap.cfg" from texlive-scripts input. - (delete-file "/tmp/texlive/share/texmf-dist/web2c/updmap.cfg") (copy-recursively a b) (invoke mktexlsr b) (install-file (string-append b "/ls-R") a)))))) diff --git a/guix/scripts/system.scm b/guix/scripts/system.scm index d7163dd3eb..f1154dad33 100644 --- a/guix/scripts/system.scm +++ b/guix/scripts/system.scm @@ -1035,8 +1035,6 @@ Some ACTIONS support additional ARGS.\n")) (display (G_ " --skip-checks skip file system and initrd module safety checks")) (display (G_ " - --target=TRIPLET cross-build for TRIPLET--e.g., \"armel-linux-gnu\"")) - (display (G_ " -v, --verbosity=LEVEL use the given verbosity LEVEL")) (newline) (display (G_ " diff --git a/guix/transformations.scm b/guix/transformations.scm index 92d9c89c0e..ede914456f 100644 --- a/guix/transformations.scm +++ b/guix/transformations.scm @@ -441,6 +441,9 @@ actual compiler." #~(begin (use-modules (ice-9 match)) + (define psabi #$(gcc-architecture->micro-architecture-level + micro-architecture)) + (define* (search-next command #:optional (path (string-split (getenv "PATH") @@ -469,10 +472,25 @@ actual compiler." (match (search-next (basename command)) (#f (exit 127)) (next - (apply execl next + (if (and (search-next "go") + (string=? next (search-next "go"))) + (cond + ((string-prefix? "arm" psabi) + (setenv "GOARM" (string-take-right psabi 1))) + ((string-prefix? "powerpc" psabi) + (setenv "GOPPC64" psabi)) + ((string-prefix? "x86_64" psabi) + (setenv "GOAMD" (string-take-right psabi 2))) + (else #t)) + '()) + (apply + execl next (append (cons next arguments) + (if (and (search-next "go") + (string=? next (search-next "go"))) + '() (list (string-append "-march=" - #$micro-architecture)))))))))) + #$micro-architecture))))))))))) (define program (program-file (string-append "tuning-compiler-wrapper-" micro-architecture) @@ -489,7 +507,8 @@ actual compiler." (for-each (lambda (program) (symlink #$program (string-append bin "/" program))) - '("cc" "gcc" "clang" "g++" "c++" "clang++"))))))) + '("cc" "gcc" "clang" "g++" "c++" "clang++" + "go"))))))) (define (build-system-with-tuning-compiler bs micro-architecture) "Return a variant of BS, a build system, that ensures that the compiler that @@ -564,27 +583,6 @@ micro-architectures: (bag (inherit lowered) - (arguments - (substitute-keyword-arguments (bag-arguments lowered) - ;; We add the tuning parameter after the default GO flags are set. - ((#:phases phases '%standard-phases) - #~(modify-phases #$phases - (add-after 'setup-go-environment 'set-microarchitecture - (lambda _ - (cond - ((string-prefix? "arm" #$psabi) - (setenv "GOARM" (string-take-right #$psabi 1)) - (format #t "Setting GOARM to ~s." - (getenv "GOARM"))) - ((string-prefix? "powerpc" #$psabi) - (setenv "GOPPC64" #$psabi) - (format #t "Setting GOPPC64 to ~s." - (getenv "GOPPC64"))) - ((string-prefix? "x86_64" #$psabi) - (setenv "GOAMD" (string-take-right #$psabi 2)) - (format #t "Setting GOAMD to ~s.\n" - (getenv "GOAMD"))) - (else #t)))))))) (build-inputs ;; Arrange so that the compiler wrapper comes first in $PATH. `(("tuning-compiler" ,(tuning-compiler micro-architecture)) |