diff options
author | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2010-01-09 06:41:55 +0000 |
---|---|---|
committer | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2010-01-09 06:41:55 +0000 |
commit | 8bec1dda934fa75cbb1402c58cb879b23305dc40 (patch) | |
tree | b4294963397117f1cf022e7a62452697df996de3 /bksys/help.py | |
download | abakus-8bec1dda934fa75cbb1402c58cb879b23305dc40.tar.gz abakus-8bec1dda934fa75cbb1402c58cb879b23305dc40.zip |
Add abakus
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/applications/abakus@1071969 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'bksys/help.py')
-rw-r--r-- | bksys/help.py | 43 |
1 files changed, 43 insertions, 0 deletions
diff --git a/bksys/help.py b/bksys/help.py new file mode 100644 index 0000000..5cb6281 --- /dev/null +++ b/bksys/help.py @@ -0,0 +1,43 @@ +## Thomas Nagy, 2005 + +""" +Detect and store the most common options +* kdecxxflags : debug=1 (-g) or debug=full (-g3, slower) + else use the user CXXFLAGS if any, - or -O2 by default +* prefix : the installation path +* extraincludes : a list of paths separated by ':' +ie: scons configure debug=full prefix=/usr/local extraincludes=/tmp/include:/usr/local +""" + +BOLD ="\033[1m" +RED ="\033[91m" +GREEN ="\033[92m" +YELLOW ="\033[1m" #"\033[93m" # unreadable on white backgrounds +CYAN ="\033[96m" +NORMAL ="\033[0m" + +def exists(env): + return true + +def generate(env): + ## Bksys requires scons 0.96 + env.EnsureSConsVersion(0, 96) + + env._help = '' + + def addHelpText(env, text): + env._help = env._help + text + + def helpText(env): + text = env._help.replace(']', NORMAL) + text = text.replace('b[', BOLD) + text = text.replace('g[', GREEN) + text = text.replace('r[', RED) + text = text.replace('y[', YELLOW) + text = text.replace('c[', CYAN) + + return text + + from SCons.Script.SConscript import SConsEnvironment + SConsEnvironment.addHelpText = addHelpText + SConsEnvironment.helpText = helpText |