#! /usr/bin/env python # encoding: utf-8 # Thomas Nagy, 2006-2010 (ita) VERSION='0.0.1' APPNAME='cc_test' top = '.' out = 'build' def set_options(opt): opt.tool_options('compiler_cc') def configure(conf): conf.check_tool('compiler_cc') # the following task and feature may be used to force a symlink of the .so file # at the root of the build directory # ------------- # import Task from TaskGen import feature, after t = Task.simple_task_type('link', 'ln -sf ${SRC} ${SRC[0].__class__.bld.bldnode.abspath()}', color='PINK', ext_in='.bin') t.quiet = True @feature('linkme') @after('apply_link') def link_me(self): tsk = self.create_task('link', self.link_task.outputs[0]) # ------------- # def build(bld): bld( features = 'cc cshlib linkme', source = 'main.c', target = 'foo' )