forked from baidu/broc
-
Notifications
You must be signed in to change notification settings - Fork 0
/
BROC
30 lines (22 loc) · 1.16 KB
/
BROC
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
#edit-mode: -*- python -*-
#coding:utf-8
import os
COMPILER_PATH('/usr/bin')
#add this to deal with dependency conflict
CONFIGS("brocbuild/configure@master@branch")
#add this to get dependency conflict
CONFIGS("brocbuild/test@master@branch")
#planish dependency
CONFIGS("brocbuild/log@master@branch")
#add a dependency
CONFIGS("brocbuild/function@master@branch")
CONFIGS("brocbuild/data@master@branch")
#show the debug mode and the release mode
CXXFLAGS("-Werror -O0", "-Wall -O2")
#get a "hello world" application
APPLICATION("app", Sources("example/foo/app.cpp"))
UT_APPLICATION("ut", Sources("example/foo/ut.cpp"), UTArgs("-c conf -h help"))
#get a staticlibrary
STATIC_LIBRARY("lib", Sources("example/foo/lib.cpp"))
#use dependency module ub, get an application
APPLICATION("dep", Sources("example/foo/dep.cpp", Include("%s/protobuf/include" % os.environ['HOME'], '$OUT_ROOT/brocbuild/configure')), Libs("$OUT_ROOT/brocbuild/function/output/lib/libfunction.a", "$OUT_ROOT/brocbuild/configure/output/lib/libconfigure.a", "$OUT_ROOT/brocbuild/log/output/lib/liblog.a", "$OUT_ROOT/brocbuild/data/output/lib/libdata.a", "%s/protobuf/lib/libprotobuf.a" % os.environ['HOME']))