mirror of https://gitlab.com/ita1024/waf.git
40 lines
773 B
Plaintext
40 lines
773 B
Plaintext
|
#! /usr/bin/env python
|
||
|
# encoding: utf-8
|
||
|
# Thomas Nagy, 2006-2011 (ita)
|
||
|
|
||
|
# the following two variables are used by the target "waf dist"
|
||
|
APPNAME='cc_test'
|
||
|
|
||
|
srcdir = '.'
|
||
|
blddir = 'build'
|
||
|
|
||
|
def set_options(opt):
|
||
|
#opt.tool_options('compiler_cc')
|
||
|
pass
|
||
|
|
||
|
def configure(conf):
|
||
|
#conf.check_tool('compiler_cc')
|
||
|
conf.check_tool('gcc')
|
||
|
conf.check_tool('netcache_client')
|
||
|
|
||
|
def build(bld):
|
||
|
|
||
|
# 1. A simple program
|
||
|
bld.new_task_gen(
|
||
|
features = 'cc cprogram',
|
||
|
source = 'main.c',
|
||
|
target = 'test_c_app',
|
||
|
uselib_local = 'my_static_lib',
|
||
|
includes = '. /usr/include')
|
||
|
|
||
|
# 2. A simple static lib
|
||
|
bld.new_task_gen(
|
||
|
features = 'cc cstaticlib',
|
||
|
source = 'test_staticlib.c',
|
||
|
target='my_static_lib')
|
||
|
|
||
|
# if we had subfolder we would do the following
|
||
|
#bld.add_subdirs('src')
|
||
|
|
||
|
|