Permalink
Browse files

Succesfully building an egg.

darcs-hash:20051126050443-71b0c-9a047302670de4ed068950f34c6f75f515a07f82.gz
  • Loading branch information...
1 parent 3ca4a37 commit 25cb23b8ebcf6adf07a3720ea5107fea13e8a345 @pupeno committed Nov 26, 2005
Showing with 12 additions and 12 deletions.
  1. +12 −12 chicken.py
View
@@ -140,26 +140,26 @@ def buildPath(item):
# Return the generated content.
return content
- def ChickenEgg(target = None, source = None, env = None):
- """ Build an egg. """
+ def EmitEggContents(target = None, source = None, env = None):
+ """ Return the files that should go into an egg. """
+ print "EmitEggContents"
def getLeafSources(sources):
""" Get all the sources that are leafs, not branches. """
- eggContents = list()
+ contents = list()
for source in sources:
if len(source.sources) == 0:
- eggContents.append(source)
- eggContents += source.get_found_includes(env, chickenScanner, source.path)
+ contents.append(source)
+ contents += source.get_found_includes(env, chickenScanner, source.path)
else:
- eggContents += getLeafSources(source.sources)
- return eggContents
+ contents += getLeafSources(source.sources)
+ return contents
- eggContents = set(getLeafSources(source))
- for egg in eggContents:
- print str(egg)
- return 0
+ contents = list(set(getLeafSources(source)))
+ return target, contents
- env["BUILDERS"]["ChickenEgg"] = SCons.Builder.Builder(action = ChickenEgg,
+ env["BUILDERS"]["ChickenEgg"] = SCons.Builder.Builder(action = "$TARCOM",
+ emitter = EmitEggContents,
suffix = '.egg')
def CheckChickenProgram(context):

0 comments on commit 25cb23b

Please sign in to comment.