diff options
author | Feng, Bob C <bob.c.feng@intel.com> | 2019-04-13 16:02:02 +0800 |
---|---|---|
committer | Feng, Bob C <bob.c.feng@intel.com> | 2019-08-09 23:15:51 +0800 |
commit | db01c8e3d87305a406286e972f19b00c5c6960ab (patch) | |
tree | 68b75b18c650656b3e5c7204be1e8b7e6f666d63 /BaseTools/Source/Python/Common/TargetTxtClassObject.py | |
parent | 4b1b7c1913092d73d689d8086dcfa579c0217dc8 (diff) | |
download | edk2-db01c8e3d87305a406286e972f19b00c5c6960ab.tar.gz edk2-db01c8e3d87305a406286e972f19b00c5c6960ab.tar.bz2 edk2-db01c8e3d87305a406286e972f19b00c5c6960ab.zip |
BaseTools: Singleton the object to handle build conf file
BZ: https://bugzilla.tianocore.org/show_bug.cgi?id=1875
The build config files are target.txt, build rule, tooldef
During a build, the config is not changed, so the object to
handle them need to be singleton.
Cc: Liming Gao <liming.gao@intel.com>
Signed-off-by: Bob Feng <bob.c.feng@intel.com>
Acked-by: Laszlo Ersek <lersek@redhat.com>
Tested-by: Laszlo Ersek <lersek@redhat.com>
Acked-by: Liming Gao <liming.gao@intel.com>
Diffstat (limited to 'BaseTools/Source/Python/Common/TargetTxtClassObject.py')
-rw-r--r-- | BaseTools/Source/Python/Common/TargetTxtClassObject.py | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/BaseTools/Source/Python/Common/TargetTxtClassObject.py b/BaseTools/Source/Python/Common/TargetTxtClassObject.py index 9d7673b41b..79a5acc010 100644 --- a/BaseTools/Source/Python/Common/TargetTxtClassObject.py +++ b/BaseTools/Source/Python/Common/TargetTxtClassObject.py @@ -146,6 +146,8 @@ def TargetTxtDict(ConfDir): Target.LoadTargetTxtFile(os.path.normpath(os.path.join(ConfDir, gDefaultTargetTxtFile)))
return Target
+TargetTxt = TargetTxtDict(os.path.join(os.getenv("WORKSPACE"),"Conf"))
+
##
#
# This acts like the main() function for the script, unless it is 'import'ed into another
|