tools/libacpi: cleanup Makefile, don't check for iasl binary
authorAnthony PERARD <anthony.perard@citrix.com>
Mon, 6 Dec 2021 17:01:58 +0000 (17:01 +0000)
committerAndrew Cooper <andrew.cooper3@citrix.com>
Thu, 16 Dec 2021 20:27:12 +0000 (20:27 +0000)
iasl is been check for presence by ./configure, so this Makefile
doesn't have to do it. Also start to use $(IASL) that ./configure
generate.

iasl hasn't been download by our build system for a while and the
dependency on iasl is in the main xen.git README.

Make use of $< in one rule instead of spelling the %.asl file again.

Signed-off-by: Anthony PERARD <anthony.perard@citrix.com>
Acked-by: Andrew Cooper <andrew.cooper3@citrix.com>
tools/libacpi/Makefile
tools/libacpi/README

index 2448687dbbcc29abc4db3fa428be2833dcc0d413..60860eaa0053589a322628af323f4841d5a6ab39 100644 (file)
@@ -38,11 +38,10 @@ MKDSDT_CFLAGS-$(CONFIG_X86) = -DCONFIG_X86
 # complete $(ACPI_BUILD_DIR) as path, even if it has '.' symbols.
 TMP_SUFFIX     = tmp
 
-vpath iasl $(PATH)
 all: $(C_SRC) $(H_SRC)
 
-$(H_SRC): $(ACPI_BUILD_DIR)/%.h: %.asl iasl
-       iasl -vs -p $(ACPI_BUILD_DIR)/$*.$(TMP_SUFFIX) -tc $<
+$(H_SRC): $(ACPI_BUILD_DIR)/%.h: %.asl
+       $(IASL) -vs -p $(ACPI_BUILD_DIR)/$*.$(TMP_SUFFIX) -tc $<
        sed -e 's/AmlCode/$*/g' -e 's/_aml_code//g' $(ACPI_BUILD_DIR)/$*.hex >$@
        rm -f $(addprefix $(ACPI_BUILD_DIR)/, $*.aml $*.hex)
  
@@ -74,21 +73,13 @@ $(ACPI_BUILD_DIR)/dsdt_anycpu_arm.asl: $(MK_DSDT)
        $(MK_DSDT) --debug=$(debug) >> $@.$(TMP_SUFFIX)
        mv -f $@.$(TMP_SUFFIX) $@
 
-$(C_SRC): $(ACPI_BUILD_DIR)/%.c: iasl $(ACPI_BUILD_DIR)/%.asl
-       iasl -vs -p $(ACPI_BUILD_DIR)/$*.$(TMP_SUFFIX) -tc $(ACPI_BUILD_DIR)/$*.asl
+$(C_SRC): $(ACPI_BUILD_DIR)/%.c: $(ACPI_BUILD_DIR)/%.asl
+       $(IASL) -vs -p $(ACPI_BUILD_DIR)/$*.$(TMP_SUFFIX) -tc $<
        sed -e 's/AmlCode/$*/g' -e 's/_aml_code//g' $(ACPI_BUILD_DIR)/$*.hex > $@.$(TMP_SUFFIX)
        echo "int $*_len=sizeof($*);" >> $@.$(TMP_SUFFIX)
        mv -f $@.$(TMP_SUFFIX) $@
        rm -f $(addprefix $(ACPI_BUILD_DIR)/, $*.aml $*.hex)
 
-iasl:
-       @echo
-       @echo "ACPI ASL compiler (iasl) is needed"
-       @echo "Download and install Intel ACPI CA from"
-       @echo "http://acpica.org/downloads/"
-       @echo 
-       @exit 1
-
 clean:
        rm -f $(C_SRC) $(H_SRC) $(MK_DSDT) $(C_SRC:=.$(TMP_SUFFIX))
        rm -f $(patsubst %.c,%.hex,$(C_SRC)) $(patsubst %.c,%.aml,$(C_SRC)) $(patsubst %.c,%.asl,$(C_SRC))
index 2b9d6e188cd0a81269420639c9d2f5865ab63fd3..4ab5ed2de7712c5924d92c6bd3083bce22caf047 100644 (file)
@@ -24,9 +24,3 @@ In case that the acpi_dsdt.asl need to be updated, please
 Follow the instruction:
 
 # make acpi_dsdt.c
-
-Note:
-DSDT compiler "iasl" is needed. By default, it will be downloaded 
-using wget in Makefile. if it failed, please download manually from 
-http://developer.intel.com/technology/iapc/acpi/downloads.htm. 
-then compile and install iasl