Gabe Black has uploaded this change for review. ( https://gem5-review.googlesource.com/c/public/gem5/+/49386 )

Change subject: scons: Declare PySource Source files in the PySource __init__.
......................................................................

scons: Declare PySource Source files in the PySource __init__.

There's no reason to wait until the end to loop over all PySource files
and declare their Source-s then.

Change-Id: I94de1b2123bb94324a647bbc005a923012080cab
---
M src/SConscript
1 file changed, 2 insertions(+), 4 deletions(-)



diff --git a/src/SConscript b/src/SConscript
index 4d03f14..a3dd639 100644
--- a/src/SConscript
+++ b/src/SConscript
@@ -171,6 +171,8 @@

         marshal_env.Command(self.cpp, [ py_marshal, self.tnode ],
                         MakeAction(embedPyFile, Transform("EMBED PY")))
+        if main['USE_PYTHON']:
+            Source(self.cpp, tags=self.tags, add_tags='python')

 class SimObject(PySource):
     '''Add a SimObject python file as a python source object and add
@@ -962,10 +964,6 @@
                        Transform("VER TAGS")))
 env.AlwaysBuild(tags)

-if main['USE_PYTHON']:
-    for source in PySource.all:
-        Source(source.cpp, tags=source.tags, add_tags='python')
-
 ########################################################################
 #
 # Define binaries.  Each different build type (debug, opt, etc.) gets

--
To view, visit https://gem5-review.googlesource.com/c/public/gem5/+/49386
To unsubscribe, or for help writing mail filters, visit https://gem5-review.googlesource.com/settings

Gerrit-Project: public/gem5
Gerrit-Branch: develop
Gerrit-Change-Id: I94de1b2123bb94324a647bbc005a923012080cab
Gerrit-Change-Number: 49386
Gerrit-PatchSet: 1
Gerrit-Owner: Gabe Black <[email protected]>
Gerrit-MessageType: newchange
_______________________________________________
gem5-dev mailing list -- [email protected]
To unsubscribe send an email to [email protected]
%(web_page_url)slistinfo%(cgiext)s/%(_internal_name)s

Reply via email to