Package: seabios Version: 1.11.1-1 Severity: wishlist Tags: patch Dear Maintainer,
It would be nice if seabios could build (and install) coreboot-targeted binaries. I achieved that with the patch I am attaching (against debian/rules). Best regards, Vivia Nikolaidou -- System Information: Debian Release: buster/sid APT prefers unstable-debug APT policy: (500, 'unstable-debug'), (500, 'unstable'), (1, 'experimental') Architecture: amd64 (x86_64) Foreign Architectures: i386 Kernel: Linux 4.18.0-2-amd64 (SMP w/4 CPU cores) Locale: LANG=en_GB.UTF-8, LC_CTYPE=el_GR.UTF-8 (charmap=UTF-8), LANGUAGE= (charmap=UTF-8) Shell: /bin/sh linked to /bin/dash Init: systemd (via /run/systemd/system) LSM: AppArmor: enabled -- no debconf information
*** seabios-1.11.1/debian/rules Tue Apr 10 07:59:17 2018 --- seabios-1.11.1-coreboot/debian/rules Sat Nov 10 13:01:05 2018 *************** *** 12,18 **** VGABIOSES = cirrus stdvga virtio vmware qxl isavga VGABIOS_TARGETS = $(addprefix build/vgabios-, $(addsuffix .bin, $(VGABIOSES))) ! BIOS_TARGETS = build/bios.bin build/bios-256k.bin ${VGABIOS_TARGETS} BUILD_TARGETS = $(BIOS_TARGETS) build/optionrom-stamp build build-arch build-indep: $(BUILD_TARGETS) --- 12,18 ---- VGABIOSES = cirrus stdvga virtio vmware qxl isavga VGABIOS_TARGETS = $(addprefix build/vgabios-, $(addsuffix .bin, $(VGABIOSES))) ! BIOS_TARGETS = build/bios.bin build/bios-256k.bin build/bios-coreboot.bin ${VGABIOS_TARGETS} BUILD_TARGETS = $(BIOS_TARGETS) build/optionrom-stamp build build-arch build-indep: $(BUILD_TARGETS) *************** *** 37,47 **** --- 37,68 ---- rm -f $@; ln $$d/$1.bin $@ endef + # common rule to build any bios. + # $1: config options to put into .config without CONFIG_ prefix + # $@: where to put output; build dir will be $(basename $@) + define build-bios-coreboot + +set -e; d=$(basename $@); \ + if [ ! -e $$d/.config.old ]; then \ + rm -rf $$d; mkdir -p $$d; \ + for x in $1; do \ + case $$x in \ + (*=n) echo "# CONFIG_$${x%=*} is not set";; \ + (*) echo CONFIG_$$x;; \ + esac; \ + done > $$d/.config; \ + $(MAKE) -j1 KCONFIG_CONFIG=$(CURDIR)/$$d/.config OUT=$$d/ olddefconfig; \ + fi; \ + $(MAKE) KCONFIG_CONFIG=$(CURDIR)/$$d/.config OUT=$$d/ EXTRAVERSION="-${DEB_VERSION_RELEASE}"; \ + rm -f $@; ln $$d/bios.bin.elf $@ + endef + build/bios.bin: # A stripped-down version of bios, to fit in 128Kb, for qemu <= 1.7 $(call build-bios,bios,QEMU=y ROM_SIZE=128 PVSCSI=n BOOTSPLASH=n USB_OHCI=n USB_XHCI=n USB_UAS=n XEN=n SDCARD=n TCGBIOS=n MPT_SCSI=n PVSCSI=n NVME=n USE_SMM=n VGAHOOKS=n) build/bios-256k.bin: $(call build-bios,bios,QEMU=y ROM_SIZE=256) + build/bios-coreboot.bin: + $(call build-bios-coreboot,COREBOOT=y DEBUG_SERIAL=y VGA_COREBOOT=y BUILD_BGAVIOS=y) # upstream ships .hex files in tarball, result of iasl compilation # ensure it is actually built during build