gnu: u-boot-tools: Fix indentation.

* gnu/packages/bootloaders.scm (u-boot-tools): Fix indentation.
This commit is contained in:
Maxim Cournoyer 2022-12-01 11:28:56 -05:00
parent 650636baca
commit 8d1d209ffe
No known key found for this signature in database
GPG key ID: 1260E46482E63562

View file

@ -592,12 +592,12 @@ (define-public u-boot-tools
(add-after 'unpack 'patch (add-after 'unpack 'patch
(lambda* (#:key inputs #:allow-other-keys) (lambda* (#:key inputs #:allow-other-keys)
(substitute* "Makefile" (substitute* "Makefile"
(("/bin/pwd") (which "pwd")) (("/bin/pwd") (which "pwd"))
(("/bin/false") (which "false"))) (("/bin/false") (which "false")))
(substitute* "tools/dtoc/fdt_util.py" (substitute* "tools/dtoc/fdt_util.py"
(("'cc'") "'gcc'")) (("'cc'") "'gcc'"))
(substitute* "tools/patman/test_util.py" (substitute* "tools/patman/test_util.py"
;; python3-coverage is simply called coverage in guix. ;; python3-coverage is simply called coverage in guix.
(("python3-coverage") "coverage") (("python3-coverage") "coverage")
;; Don't require 100% coverage since it's brittle and can ;; Don't require 100% coverage since it's brittle and can
@ -605,40 +605,40 @@ (define-public u-boot-tools
(("raise ValueError\\('Test coverage failure'\\)") (("raise ValueError\\('Test coverage failure'\\)")
"print('Continuing anyway since Guix does not care :O')")) "print('Continuing anyway since Guix does not care :O')"))
(substitute* "test/run" (substitute* "test/run"
;; Make it easier to find test failures. ;; Make it easier to find test failures.
(("#!/bin/bash") "#!/bin/bash -x") (("#!/bin/bash") "#!/bin/bash -x")
;; This test would require git. ;; This test would require git.
(("\\./tools/patman/patman") (which "true")) (("\\./tools/patman/patman") (which "true"))
;; FIXME: test fails, needs further investiation ;; FIXME: test fails, needs further investiation
(("run_test \"binman\"") "# run_test \"binman\"") (("run_test \"binman\"") "# run_test \"binman\"")
;; FIXME: test_spl fails, needs further investiation ;; FIXME: test_spl fails, needs further investiation
(("test_ofplatdata or test_handoff or test_spl") (("test_ofplatdata or test_handoff or test_spl")
"test_ofplatdata or test_handoff") "test_ofplatdata or test_handoff")
;; FIXME: code coverage not working ;; FIXME: code coverage not working
(("run_test \"binman code coverage\"") (("run_test \"binman code coverage\"")
"# run_test \"binman code coverage\"") "# run_test \"binman code coverage\"")
;; This test would require internet access. ;; This test would require internet access.
(("\\./tools/buildman/buildman") (which "true"))) (("\\./tools/buildman/buildman") (which "true")))
(substitute* "test/py/tests/test_sandbox_exit.py" (substitute* "test/py/tests/test_sandbox_exit.py"
(("def test_ctrl_c") (("def test_ctrl_c")
"@pytest.mark.skip(reason='Guix has problems with SIGINT') "@pytest.mark.skip(reason='Guix has problems with SIGINT')
def test_ctrl_c")) def test_ctrl_c"))
;; Test against the tools being installed rather than tools built ;; Test against the tools being installed rather than tools built
;; for "sandbox" target. ;; for "sandbox" target.
(substitute* "test/image/test-imagetools.sh" (substitute* "test/image/test-imagetools.sh"
(("BASEDIR=sandbox") "BASEDIR=.")) (("BASEDIR=sandbox") "BASEDIR=."))
(for-each (lambda (file) (for-each (lambda (file)
(substitute* file (substitute* file
;; Disable features that require OpenSSL due ;; Disable features that require OpenSSL due
;; to GPL/Openssl license incompatibilities. ;; to GPL/Openssl license incompatibilities.
;; See https://bugs.gnu.org/34717 for ;; See https://bugs.gnu.org/34717 for
;; details. ;; details.
(("CONFIG_FIT_SIGNATURE=y") (("CONFIG_FIT_SIGNATURE=y")
"CONFIG_FIT_SIGNATURE=n\nCONFIG_UT_LIB_ASN1=n\nCONFIG_TOOLS_LIBCRYPTO=n") "CONFIG_FIT_SIGNATURE=n\nCONFIG_UT_LIB_ASN1=n\nCONFIG_TOOLS_LIBCRYPTO=n")
;; This test requires a sound system, which is un-used ;; This test requires a sound system, which is un-used
;; in u-boot-tools. ;; in u-boot-tools.
(("CONFIG_SOUND=y") "CONFIG_SOUND=n"))) (("CONFIG_SOUND=y") "CONFIG_SOUND=n")))
(find-files "configs" "sandbox_.*defconfig$|tools-only_defconfig")) (find-files "configs" "sandbox_.*defconfig$|tools-only_defconfig"))
#t)) #t))
(replace 'configure (replace 'configure
(lambda* (#:key make-flags #:allow-other-keys) (lambda* (#:key make-flags #:allow-other-keys)
@ -666,22 +666,22 @@ (define-public u-boot-tools
"tools/env/fw_printenv" "tools/env/fw_printenv"
"tools/sunxi-spl-image-builder")) "tools/sunxi-spl-image-builder"))
#t))) #t)))
(delete 'check) (delete 'check)
(add-after 'install 'check (add-after 'install 'check
(lambda* (#:key make-flags test-target #:allow-other-keys) (lambda* (#:key make-flags test-target #:allow-other-keys)
(invoke "test/image/test-imagetools.sh"))) (invoke "test/image/test-imagetools.sh")))
;; Only run full test suite on x86_64 systems, as many tests ;; Only run full test suite on x86_64 systems, as many tests
;; assume x86_64. ;; assume x86_64.
,@(if (string-match "^x86_64-linux" ,@(if (string-match "^x86_64-linux"
(or (%current-target-system) (or (%current-target-system)
(%current-system))) (%current-system)))
'((add-after 'check 'check-x86 '((add-after 'check 'check-x86
(lambda* (#:key make-flags test-target #:allow-other-keys) (lambda* (#:key make-flags test-target #:allow-other-keys)
(apply invoke "make" "mrproper" make-flags) (apply invoke "make" "mrproper" make-flags)
(setenv "SDL_VIDEODRIVER" "dummy") (setenv "SDL_VIDEODRIVER" "dummy")
(setenv "PAGER" "cat") (setenv "PAGER" "cat")
(apply invoke "make" test-target make-flags)))) (apply invoke "make" test-target make-flags))))
'())))) '()))))
(description "U-Boot is a bootloader used mostly for ARM boards. It (description "U-Boot is a bootloader used mostly for ARM boards. It
also initializes the boards (RAM etc). This package provides its also initializes the boards (RAM etc). This package provides its
board-independent tools."))) board-independent tools.")))