[edk2] [PATCH] BaseTools/build_rule: pass contents of DTC_FLAGS device tree compiler

Ard Biesheuvel posted 1 patch 6 years, 9 months ago
Failed in applying to current master (apply log)
BaseTools/Conf/build_rule.template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
[edk2] [PATCH] BaseTools/build_rule: pass contents of DTC_FLAGS device tree compiler
Posted by Ard Biesheuvel 6 years, 9 months ago
To allow device tree compilation to be customized at the platform or
module level, pass the contents of the DTC_FLAGS variable on the
dtc command line.

Contributed-under: TianoCore Contribution Agreement 1.1
Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org>
---
 BaseTools/Conf/build_rule.template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/BaseTools/Conf/build_rule.template b/BaseTools/Conf/build_rule.template
index 3e6aa8ff0f34..a5e471eb3c10 100755
--- a/BaseTools/Conf/build_rule.template
+++ b/BaseTools/Conf/build_rule.template
@@ -250,7 +250,7 @@
 
     <Command.GCC>
         "$(PP)" $(DTCPP_FLAGS) $(INC) ${src} > ${d_path}(+)${s_base}.i
-        "$(DTC)" -I dts -O dtb -o ${dst} ${d_path}(+)${s_base}.i
+        "$(DTC)" $(DTC_FLAGS) -I dts -O dtb -o ${dst} ${d_path}(+)${s_base}.i
 
 [Visual-Form-Representation-File]
     <InputFile>
-- 
2.11.0

_______________________________________________
edk2-devel mailing list
edk2-devel@lists.01.org
https://lists.01.org/mailman/listinfo/edk2-devel
Re: [edk2] [PATCH] BaseTools/build_rule: pass contents of DTC_FLAGS device tree compiler
Posted by Gao, Liming 6 years, 9 months ago
Ard:
  Do you consider to add DTC_FLAGS in tools_def.template file? Its value can be empty. So, user bases on tools_def.txt to know which option can be set. 

>-----Original Message-----
>From: Ard Biesheuvel [mailto:ard.biesheuvel@linaro.org]
>Sent: Thursday, February 01, 2018 5:49 AM
>To: edk2-devel@lists.01.org
>Cc: Gao, Liming <liming.gao@intel.com>; Zhu, Yonghong
><yonghong.zhu@intel.com>; lersek@redhat.com; Ard Biesheuvel
><ard.biesheuvel@linaro.org>
>Subject: [PATCH] BaseTools/build_rule: pass contents of DTC_FLAGS device
>tree compiler
>
>To allow device tree compilation to be customized at the platform or
>module level, pass the contents of the DTC_FLAGS variable on the
>dtc command line.
>
>Contributed-under: TianoCore Contribution Agreement 1.1
>Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org>
>---
> BaseTools/Conf/build_rule.template | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
>diff --git a/BaseTools/Conf/build_rule.template
>b/BaseTools/Conf/build_rule.template
>index 3e6aa8ff0f34..a5e471eb3c10 100755
>--- a/BaseTools/Conf/build_rule.template
>+++ b/BaseTools/Conf/build_rule.template
>@@ -250,7 +250,7 @@
>
>     <Command.GCC>
>         "$(PP)" $(DTCPP_FLAGS) $(INC) ${src} > ${d_path}(+)${s_base}.i
>-        "$(DTC)" -I dts -O dtb -o ${dst} ${d_path}(+)${s_base}.i
>+        "$(DTC)" $(DTC_FLAGS) -I dts -O dtb -o ${dst} ${d_path}(+)${s_base}.i
>
> [Visual-Form-Representation-File]
>     <InputFile>
>--
>2.11.0

_______________________________________________
edk2-devel mailing list
edk2-devel@lists.01.org
https://lists.01.org/mailman/listinfo/edk2-devel
Re: [edk2] [PATCH] BaseTools/build_rule: pass contents of DTC_FLAGS device tree compiler
Posted by Ard Biesheuvel 6 years, 9 months ago
On 1 February 2018 at 01:32, Gao, Liming <liming.gao@intel.com> wrote:
> Ard:
>   Do you consider to add DTC_FLAGS in tools_def.template file? Its value can be empty. So, user bases on tools_def.txt to know which option can be set.
>

You are right, I forgot about the second part

>>-----Original Message-----
>>From: Ard Biesheuvel [mailto:ard.biesheuvel@linaro.org]
>>Sent: Thursday, February 01, 2018 5:49 AM
>>To: edk2-devel@lists.01.org
>>Cc: Gao, Liming <liming.gao@intel.com>; Zhu, Yonghong
>><yonghong.zhu@intel.com>; lersek@redhat.com; Ard Biesheuvel
>><ard.biesheuvel@linaro.org>
>>Subject: [PATCH] BaseTools/build_rule: pass contents of DTC_FLAGS device
>>tree compiler
>>
>>To allow device tree compilation to be customized at the platform or
>>module level, pass the contents of the DTC_FLAGS variable on the
>>dtc command line.
>>
>>Contributed-under: TianoCore Contribution Agreement 1.1
>>Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org>
>>---
>> BaseTools/Conf/build_rule.template | 2 +-
>> 1 file changed, 1 insertion(+), 1 deletion(-)
>>
>>diff --git a/BaseTools/Conf/build_rule.template
>>b/BaseTools/Conf/build_rule.template
>>index 3e6aa8ff0f34..a5e471eb3c10 100755
>>--- a/BaseTools/Conf/build_rule.template
>>+++ b/BaseTools/Conf/build_rule.template
>>@@ -250,7 +250,7 @@
>>
>>     <Command.GCC>
>>         "$(PP)" $(DTCPP_FLAGS) $(INC) ${src} > ${d_path}(+)${s_base}.i
>>-        "$(DTC)" -I dts -O dtb -o ${dst} ${d_path}(+)${s_base}.i
>>+        "$(DTC)" $(DTC_FLAGS) -I dts -O dtb -o ${dst} ${d_path}(+)${s_base}.i
>>
>> [Visual-Form-Representation-File]
>>     <InputFile>
>>--
>>2.11.0
>
_______________________________________________
edk2-devel mailing list
edk2-devel@lists.01.org
https://lists.01.org/mailman/listinfo/edk2-devel