Permalink
Browse files

Some cleanups in the wscript.

  • Loading branch information...
1 parent a045267 commit cc6d3d0e78ad5b04e1e9089137aeed21def73949 alexrp committed Jan 7, 2012
Showing with 10 additions and 9 deletions.
  1. +10 −9 wscript
View
19 wscript
@@ -16,6 +16,8 @@ def options(opt):
def configure(conf):
conf.recurse('libffi-d')
+ conf.env.VIM = conf.options.vim
+
def add_option(option):
conf.env.append_value('DFLAGS', option)
@@ -32,37 +34,36 @@ def configure(conf):
else:
add_option('-m32')
- conf.env.LIB_FFI = ['ffi']
- conf.env.LIB_DL = ['dl']
-
- conf.check_dlibrary()
-
- conf.env.VIM = conf.options.vim
-
if conf.options.mode == 'debug':
add_option('-debug')
else:
add_option('-release')
add_option('-O')
add_option('-inline')
+ conf.env.LIB_FFI = ['ffi']
+ conf.env.LIB_DL = ['dl']
+
+ conf.check_dlibrary()
+
def build(bld):
bld.recurse('libffi-d')
def search_paths(path):
return [os.path.join(path, '*.d'), os.path.join(path, '**', '*.d')]
includes = ['src', 'libffi-d']
+ src = os.path.join('src', 'mci')
def stlib(path, target, dflags = [], install = '${PREFIX}/lib'):
- bld.stlib(source = bld.path.ant_glob(search_paths(os.path.join('src', 'mci', path))),
+ bld.stlib(source = bld.path.ant_glob(search_paths(os.path.join(src, path))),
target = target,
includes = includes,
install_path = install,
dflags = dflags)
def program(path, target, deps, dflags = [], install = '${PREFIX}/bin'):
- bld.program(source = bld.path.ant_glob(search_paths(os.path.join('src', 'mci', path))),
+ bld.program(source = bld.path.ant_glob(search_paths(os.path.join(src, path))),
target = target,
use = deps,
includes = includes,

0 comments on commit cc6d3d0

Please sign in to comment.