public inbox for devel@edk2.groups.io
 help / color / mirror / Atom feed
* [PATCH] BaseTools: Add included files to deps_target file.
@ 2020-09-23 10:52 Bob Feng
  2020-09-24  8:40 ` Yuwei Chen
  0 siblings, 1 reply; 2+ messages in thread
From: Bob Feng @ 2020-09-23 10:52 UTC (permalink / raw)
  To: devel; +Cc: Mingyue Liang, Liming Gao, Yuwei Chen

From: Mingyue Liang <mingyuex.liang@intel.com>

REF: https://bugzilla.tianocore.org/show_bug.cgi?id=2882

After changing the name of the include source file,
when doing incremental build, the previous source file
is not covered in the. DEPs file, and a build error occurs.

The root cause is that the build tools filter out some dependency
files, which are listed in inf source section, from the deps_target file. 
Add those files back to deps_target file to resolve the above problem.

Signed-off-by: Mingyue Liang <mingyuex.liang@intel.com>
Cc: Bob Feng <bob.c.feng@intel.com>
Cc: Liming Gao <gaoliming@byosoft.com.cn>
Cc: Yuwei Chen <yuwei.chen@intel.com>
---
 BaseTools/Source/Python/AutoGen/IncludesAutoGen.py | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/BaseTools/Source/Python/AutoGen/IncludesAutoGen.py b/BaseTools/Source/Python/AutoGen/IncludesAutoGen.py
index 720d93395a..c3e6333217 100644
--- a/BaseTools/Source/Python/AutoGen/IncludesAutoGen.py
+++ b/BaseTools/Source/Python/AutoGen/IncludesAutoGen.py
@@ -103,7 +103,7 @@ ${END}
                     if os.path.normpath(dependency_file +".deps") == abspath:
                         continue
                     filename = os.path.basename(dependency_file).strip()
-                    if filename not in self.SourceFileList and filename not in targetname:
+                    if filename not in targetname:
                         includes.add(dependency_file.strip())
 
                 for item in lines[1:]:
@@ -116,8 +116,6 @@ ${END}
                     if os.path.normpath(dependency_file +".deps") == abspath:
                         continue
                     filename = os.path.basename(dependency_file).strip()
-                    if filename in self.SourceFileList:
-                        continue
                     if filename in targetname:
                         continue
                     includes.add(dependency_file.strip())
-- 
2.28.0.windows.1


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] BaseTools: Add included files to deps_target file.
  2020-09-23 10:52 [PATCH] BaseTools: Add included files to deps_target file Bob Feng
@ 2020-09-24  8:40 ` Yuwei Chen
  0 siblings, 0 replies; 2+ messages in thread
From: Yuwei Chen @ 2020-09-24  8:40 UTC (permalink / raw)
  To: Feng, Bob C, devel@edk2.groups.io; +Cc: Liang, MingyueX, Liming Gao

Reviewed-by: Yuwei Chen<yuwei.chen@intel.com>

> -----Original Message-----
> From: Feng, Bob C <bob.c.feng@intel.com>
> Sent: Wednesday, September 23, 2020 6:52 PM
> To: devel@edk2.groups.io
> Cc: Liang, MingyueX <mingyuex.liang@intel.com>; Liming Gao
> <gaoliming@byosoft.com.cn>; Chen, Christine <yuwei.chen@intel.com>
> Subject: [PATCH] BaseTools: Add included files to deps_target file.
> 
> From: Mingyue Liang <mingyuex.liang@intel.com>
> 
> REF: https://bugzilla.tianocore.org/show_bug.cgi?id=2882
> 
> After changing the name of the include source file, when doing incremental
> build, the previous source file is not covered in the. DEPs file, and a build
> error occurs.
> 
> The root cause is that the build tools filter out some dependency files, which
> are listed in inf source section, from the deps_target file.
> Add those files back to deps_target file to resolve the above problem.
> 
> Signed-off-by: Mingyue Liang <mingyuex.liang@intel.com>
> Cc: Bob Feng <bob.c.feng@intel.com>
> Cc: Liming Gao <gaoliming@byosoft.com.cn>
> Cc: Yuwei Chen <yuwei.chen@intel.com>
> ---
>  BaseTools/Source/Python/AutoGen/IncludesAutoGen.py | 4 +---
>  1 file changed, 1 insertion(+), 3 deletions(-)
> 
> diff --git a/BaseTools/Source/Python/AutoGen/IncludesAutoGen.py
> b/BaseTools/Source/Python/AutoGen/IncludesAutoGen.py
> index 720d93395a..c3e6333217 100644
> --- a/BaseTools/Source/Python/AutoGen/IncludesAutoGen.py
> +++ b/BaseTools/Source/Python/AutoGen/IncludesAutoGen.py
> @@ -103,7 +103,7 @@ ${END}
>                      if os.path.normpath(dependency_file +".deps") == abspath:
>                          continue
>                      filename = os.path.basename(dependency_file).strip()
> -                    if filename not in self.SourceFileList and filename not in
> targetname:
> +                    if filename not in targetname:
>                          includes.add(dependency_file.strip())
> 
>                  for item in lines[1:]:
> @@ -116,8 +116,6 @@ ${END}
>                      if os.path.normpath(dependency_file +".deps") == abspath:
>                          continue
>                      filename = os.path.basename(dependency_file).strip()
> -                    if filename in self.SourceFileList:
> -                        continue
>                      if filename in targetname:
>                          continue
>                      includes.add(dependency_file.strip())
> --
> 2.28.0.windows.1


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2020-09-24  8:41 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2020-09-23 10:52 [PATCH] BaseTools: Add included files to deps_target file Bob Feng
2020-09-24  8:40 ` Yuwei Chen

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox