diff options
author | Simon Glass <sjg@chromium.org> | 2020-04-08 16:57:37 -0600 |
---|---|---|
committer | Bin Meng <bmeng.cn@gmail.com> | 2020-04-16 14:36:28 +0800 |
commit | 89c2798f1f2f690cdd269e38ef386ff720435816 (patch) | |
tree | 788472aaf2503f56d42dddbe5a9e0470dce5a4c3 /scripts/Makefile.lib | |
parent | 776cc2019467567b9a834f80cc5b03128efa372a (diff) | |
download | u-boot-89c2798f1f2f690cdd269e38ef386ff720435816.tar.gz u-boot-89c2798f1f2f690cdd269e38ef386ff720435816.tar.bz2 u-boot-89c2798f1f2f690cdd269e38ef386ff720435816.zip |
acpi: Add an __ACPI__ preprocessor symbol
The ASL compiler cannot handle C structures and the like so needs some
sort of header guard around these.
We already have an __ASSEMBLY__ #define but it seems best to create a new
one for ACPI since the rules may be different.
Add the check to a few files that ACPI always includes.
Signed-off-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Bin Meng <bmeng.cn@gmail.com>
Reviewed-by: Wolfgang Wallner <wolfgang.wallner@br-automation.com>
Diffstat (limited to 'scripts/Makefile.lib')
-rw-r--r-- | scripts/Makefile.lib | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/scripts/Makefile.lib b/scripts/Makefile.lib index 8decb0e451..1c8cb7488f 100644 --- a/scripts/Makefile.lib +++ b/scripts/Makefile.lib @@ -437,8 +437,8 @@ ASL_TMP = $(patsubst %.c,%.asl.tmp,$@) quiet_cmd_acpi_c_asl= ASL $< cmd_acpi_c_asl= \ - $(CPP) -x assembler-with-cpp -D__ASSEMBLY__ -P $(UBOOTINCLUDE) \ - -o $(ASL_TMP) $< && \ + $(CPP) -x assembler-with-cpp -D__ASSEMBLY__ -D__ACPI__ \ + -P $(UBOOTINCLUDE) -o $(ASL_TMP) $< && \ iasl -p $@ -tc $(ASL_TMP) $(if $(KBUILD_VERBOSE:1=), >/dev/null) && \ mv $(patsubst %.c,%.hex,$@) $@ |