Add an example

This commit is contained in:
Gustavo J. A. M. Carneiro committed 2007-05-31 17:58:02 +01:00
1 parent ccd7c49e6a
commit a0cd17dbdb
5 files changed
+119 -17

No files matched your search

+14 -2
View File
@@ -2,6 +2,7 @@
## (C) 2007 Gustavo J. A. M. Carneiro
import Params
from Params import fatal
VERSION='0.1'
@@ -10,12 +11,23 @@ srcdir = '.'
blddir = 'build'
def set_options(opt):
opt.sub_options('tests')
opt.tool_options('python')
opt.tool_options('compiler_cxx')
def configure(conf):
conf.sub_config('tests')
conf.check_tool('misc')
if not conf.check_tool('compiler_cxx'):
fatal("Error: no C compiler was found in PATH.")
if not (conf.check_tool('python')
and conf.check_python_version((2,4,2))
and conf.check_python_headers()):
fatal("Error: missing Python development environment.\n"
"(Hint: if you do not have a debugging Python library installed"
" try using the configure option '--debug-level release')")
def build(bld):
if Params.g_commands['check']:
bld.add_subdirs('tests')
bld.add_subdirs('examples')