From: Richard Fitzgerald Date: Mon, 21 Jun 2021 15:24:33 +0000 (+0100) Subject: ACPI: tables: Add custom DSDT file as makefile prerequisite X-Git-Url: http://git.maquefel.me/?a=commitdiff_plain;h=d1059c1b1146870c52f3dac12cb7b6cbf39ed27f;p=linux.git ACPI: tables: Add custom DSDT file as makefile prerequisite A custom DSDT file is mostly used during development or debugging, and in that case it is quite likely to want to rebuild the kernel after changing ONLY the content of the DSDT. This patch adds the custom DSDT as a prerequisite to tables.o to ensure a rebuild if the DSDT file is updated. Make will merge the prerequisites from multiple rules for the same target. Signed-off-by: Richard Fitzgerald Signed-off-by: Rafael J. Wysocki --- diff --git a/drivers/acpi/Makefile b/drivers/acpi/Makefile index 700b41adf2db6..9aa82d5272720 100644 --- a/drivers/acpi/Makefile +++ b/drivers/acpi/Makefile @@ -8,6 +8,11 @@ ccflags-$(CONFIG_ACPI_DEBUG) += -DACPI_DEBUG_OUTPUT # # ACPI Boot-Time Table Parsing # +ifeq ($(CONFIG_ACPI_CUSTOM_DSDT),y) +tables.o: $(src)/../../include/$(subst $\",,$(CONFIG_ACPI_CUSTOM_DSDT_FILE)) ; + +endif + obj-$(CONFIG_ACPI) += tables.o obj-$(CONFIG_X86) += blacklist.o