util/autoport: correct build errors of produced files

Change-Id: I8d1a6af6f1d70268f17692bee130c08502082c97
Signed-off-by: Angel Pons <th3fanbus@gmail.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/37730
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Nico Huber <nico.h@gmx.de>
diff --git a/util/autoport/main.go b/util/autoport/main.go
index 03523a2..dbd8913 100644
--- a/util/autoport/main.go
+++ b/util/autoport/main.go
@@ -77,6 +77,7 @@
 }
 
 var SouthBridge SouthBridger
+var BootBlockFiles map[string]string = map[string]string{}
 var ROMStageFiles map[string]string = map[string]string{}
 var RAMStageFiles map[string]string = map[string]string{}
 var SMMFiles map[string]string = map[string]string{}
@@ -154,6 +155,10 @@
 	return result
 }
 
+func AddBootBlockFile(Name string, Condition string) {
+	BootBlockFiles[Name] = Condition
+}
+
 func AddROMStageFile(Name string, Condition string) {
 	ROMStageFiles[Name] = Condition
 }
@@ -190,8 +195,7 @@
 		if condition == "" {
 			fmt.Fprintf(mf, "%s-y += %s\n", category, file)
 		} else {
-			fmt.Fprintf(mf, "%s-$(%s) += %s\n", category,
-				condition, file)
+			fmt.Fprintf(mf, "%s-$(%s) += %s\n", category, condition, file)
 		}
 	}
 }
@@ -757,9 +761,10 @@
 		AddRAMStageFile("gma-mainboard.ads", "CONFIG_MAINBOARD_USE_LIBGFXINIT")
 	}
 
-	if len(ROMStageFiles) > 0 || len(RAMStageFiles) > 0 || len(SMMFiles) > 0 {
+	if len(BootBlockFiles) > 0 || len(ROMStageFiles) > 0 || len(RAMStageFiles) > 0 || len(SMMFiles) > 0 {
 		mf := Create(ctx, "Makefile.inc")
 		defer mf.Close()
+		writeMF(mf, BootBlockFiles, "bootblock")
 		writeMF(mf, ROMStageFiles, "romstage")
 		writeMF(mf, RAMStageFiles, "ramstage")
 		writeMF(mf, SMMFiles, "smm")
@@ -854,17 +859,18 @@
 
 	dsdt.WriteString(
 		`
+
 #include <arch/acpi.h>
+
 DefinitionBlock(
 	"dsdt.aml",
 	"DSDT",
-	0x02,		// DSDT revision: ACPI 2.0 and up
+	0x02,		/* DSDT revision: ACPI 2.0 and up */
 	OEM_ID,
 	ACPI_TABLE_CREATOR,
-	0x20141018	// OEM revision
+	0x20141018	/* OEM revision */
 )
 {
-	/* Some generic macros */
 	#include "acpi/platform.asl"
 `)