mirror of https://github.com/acidanthera/audk.git
BaseTools: Create ".cache" folder when initialize Build object
BZ: https://bugzilla.tianocore.org/show_bug.cgi?id=1986 Create "Conf/.cache" folder as early as possible so that the later code do need to check if it exits and then create it. Signed-off-by: Bob Feng <bob.c.feng@intel.com> Cc: Michael D Kinney <michael.d.kinney@intel.com> Cc: Liming Gao <liming.gao@intel.com> Reviewed-by: Michael D Kinney <michael.d.kinney@intel.com> Reviewed-by: Liming Gao <liming.gao@intel.com>
This commit is contained in:
parent
8ff68cd5e4
commit
5f89bcc460
|
@ -246,13 +246,8 @@ def ProcessDuplicatedInf(Path, BaseName, Workspace):
|
|||
else:
|
||||
Filename = BaseName + Path.BaseName
|
||||
|
||||
#
|
||||
# If -N is specified on command line, cache is disabled
|
||||
# The directory has to be created
|
||||
#
|
||||
DbDir = os.path.split(GlobalData.gDatabasePath)[0]
|
||||
if not os.path.exists(DbDir):
|
||||
os.makedirs(DbDir)
|
||||
|
||||
#
|
||||
# A temporary INF is copied to database path which must have write permission
|
||||
# The temporary will be removed at the end of build
|
||||
|
|
|
@ -773,7 +773,8 @@ class Build():
|
|||
ConfDirectoryPath = mws.join(self.WorkspaceDir, 'Conf')
|
||||
GlobalData.gConfDirectory = ConfDirectoryPath
|
||||
GlobalData.gDatabasePath = os.path.normpath(os.path.join(ConfDirectoryPath, GlobalData.gDatabasePath))
|
||||
|
||||
if not os.path.exists(os.path.join(GlobalData.gConfDirectory, '.cache')):
|
||||
os.makedirs(os.path.join(GlobalData.gConfDirectory, '.cache'))
|
||||
self.Db = WorkspaceDatabase()
|
||||
self.BuildDatabase = self.Db.BuildObject
|
||||
self.Platform = None
|
||||
|
|
Loading…
Reference in New Issue