summaryrefslogtreecommitdiff
path: root/src/drivers/intel/gma/Makefile.inc
diff options
context:
space:
mode:
Diffstat (limited to 'src/drivers/intel/gma/Makefile.inc')
-rw-r--r--src/drivers/intel/gma/Makefile.inc23
1 files changed, 23 insertions, 0 deletions
diff --git a/src/drivers/intel/gma/Makefile.inc b/src/drivers/intel/gma/Makefile.inc
index 88b91f6a20..a4e007c373 100644
--- a/src/drivers/intel/gma/Makefile.inc
+++ b/src/drivers/intel/gma/Makefile.inc
@@ -20,3 +20,26 @@ ifeq ($(CONFIG_VGA_ROM_RUN),y)
ramstage-$(CONFIG_INTEL_INT15) += int15.c
endif
ramstage-$(CONFIG_INTEL_GMA_ACPI) += acpi.c
+
+
+ifeq ($(CONFIG_MAINBOARD_USE_LIBGFXINIT),y)
+
+$(call add-special-class,gfxinit)
+gfxinit-handler = $(eval ramstage-srcs += $(1)$(2))
+
+$(call add-special-class,gfxinit-gen)
+gfxinit-gen-handler = \
+ $(eval additional-dirs += $(dir $(2))) \
+ $(eval ramstage-srcs += $(2)) \
+ $(eval ramstage-ads-deps += $(2)) \
+ $(eval ramstage-adb-deps += $(2)) \
+ $(eval $(2): $(obj)/config.h)
+
+CONFIG_GFX_GMA_DEFAULT_MMIO := 0 # dummy, will be overwritten at runtime
+
+subdirs-y += ../../../../3rdparty/libgfxinit
+
+ramstage-y += gma.ads
+ramstage-y += gma.adb
+
+endif # CONFIG_MAINBOARD_USE_LIBGFXINIT