gnu: install-buildroot-u-boot: Add post-image-script.

* gnu/bootloader/u-boot.scm (install-buildroot-u-boot): Modify.
(buildroot->guix-package): Use it.
This commit is contained in:
Danny Milosavljevic 2019-09-03 03:10:13 +02:00
parent 5bdd10bdfc
commit b9e9ada82b
No known key found for this signature in database
GPG key ID: E71A35542C30BAA5
2 changed files with 9 additions and 2 deletions

View file

@ -91,10 +91,13 @@ (define install-puma-rk3399-u-boot
(write-file-on-device u-boot (stat:size (stat u-boot))
device (* 512 512)))))
(define install-buildroot-u-boot
(define (install-buildroot-u-boot post-image-script post-script-args)
#~(lambda (bootloader device mount-point)
;; FIXME: Take genimage and a custom config from buildroot in order to install bootloader.
#$genimage
#$buildroot-boards
#$post-image-script
#$post-script-args
#f))

View file

@ -140,4 +140,8 @@ (define (buildroot->guix-package name)
,(if (eq? (assoc-ref buildroot-configuration "BR2_aarch64") 'y)
"aarch64-linux-gnu"
"arm-linux-gnueabihf")))
(installer install-buildroot-u-boot))))))))
(installer (install-buildroot-u-boot
,(assoc-ref buildroot-configuration
"BR2_ROOTFS_POST_IMAGE_SCRIPT")
,(assoc-ref buildroot-configuration
"BR2_ROOTFS_POST_SCRIPT_ARGS"))))))))))