[Scons-users] Found dependency cycle

Dave Vitek dvitek at grammatech.com
Wed Mar 22 14:12:29 EDT 2017


This sounds like the problem I described in my email last week: "2.5.0 
scanner fidelity regression since 2.3.4."

We have been able to resolve the issue here by disabling the promiscuous 
scanner selection logic for builders that do not have scanners:

Index: Node/__init__.py
===================================================================
--- __init__.py (revision 134700)
+++ __init__.py (working copy)
@@ -952,9 +952,10 @@
      def _get_scanner(self, env, initial_scanner, root_node_scanner, kw):
          if not initial_scanner:
              # handle implicit scanner case
-            scanner = self.get_env_scanner(env, kw)
-            if scanner:
-                scanner = scanner.select(self)
+            scanner = None
+            #scanner = self.get_env_scanner(env, kw)
+            #if scanner:
+            #    scanner = scanner.select(self)
          else:
              # handle explicit scanner case
              scanner = initial_scanner.select(self)

Use at your own risk.  This may have negative consequences if you were 
relying on the promiscuous scanner selection behavior.

On 3/20/2017 10:39 AM, Непомнящий Евгений wrote:
> Hello
>
> I have file source.cpp, which #include generated file source.gen.h. 
> source.gen.h generate by other tool on the basis of source.cpp
>
> source.cpp
> ----
>
> #include "source.gen.h"
>
> int main() { return 0; }
>
>
> SConstruct
> ----
>
> e = Environment()
> e.Command("source.gen.h", "source.cpp", Copy('$TARGET', '$SOURCE')) # 
> "generator"
> e.Program("source.cpp")
>
>
>
> This code works fine in Scons 2.1, but Scons 2.5.1 produce error:
> scons: *** Found dependency cycle(s):
>   source.gen.h -> source.gen.h
>
> File "C:\Python27\Lib\site-packages\scons-2.5.1\SCons\Taskmaster.py", 
> line 1043, in cleanup
>
> How do I get around this error?
>
> Thank you
> _______________________________________________
> Scons-users mailing list
> Scons-users at scons.org
> https://pairlist4.pair.net/mailman/listinfo/scons-users



More information about the Scons-users mailing list