Beispiel #1
0
    def resolve(self, makefile, variables, fd, setting):
        plist = [
            data.Pattern(p) for p in self._arguments[0].resolvesplit(
                makefile, variables, setting)
        ]

        fd.write(' '.join([
            w for w in self._arguments[1].resolvesplit(makefile, variables,
                                                       setting)
            if not util.any((p.match(w) for p in plist))
        ]))
Beispiel #2
0
    def spin():
        """
        Spin the 'event loop', and never return.
        """

        while True:
            clist = list(ParallelContext._allcontexts)
            for c in clist:
                c.run()

            dowait = util.any((len(c.running) for c in ParallelContext._allcontexts))
            if dowait:
                # Wait on local jobs first for perf
                for job, cb in ParallelContext._waitany(ParallelContext._condition):
                    cb(job.exitcode)
            else:
                assert any(len(c.pending) for c in ParallelContext._allcontexts)