You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
This repo is archived. You can view files and clone it, but cannot push or open issues/pull-requests.
waf_old/docs/book/examples/advbuild_subclass/wscript

28 lines
427 B
Python

#! /usr/bin/env python
"""
Context commands usually derive from different classe.
The command 'foo' uses a normal context, while bar uses
a different class. Try executing
$ waf configure foo bar tak
"""
def configure(ctx):
print(type(ctx))
def foo(ctx):
print(type(ctx))
def bar(ctx):
print(type(ctx))
from waflib.Context import Context
class one(Context):
cmd = 'foo'
class two(Context):
cmd = 'tak'
fun = 'bar'