aboutsummaryrefslogtreecommitdiffstats
path: root/wscript
diff options
context:
space:
mode:
Diffstat (limited to 'wscript')
-rw-r--r--wscript9
1 files changed, 9 insertions, 0 deletions
diff --git a/wscript b/wscript
index 1653b56..7479315 100644
--- a/wscript
+++ b/wscript
@@ -23,6 +23,7 @@ out = 'build'
def options(opt):
opt.load('compiler_c')
+ opt.load('compiler_cxx')
opt.load('lv2')
autowaf.set_options(opt)
opt.add_option('--test', action='store_true', dest='build_tests',
@@ -31,6 +32,8 @@ def options(opt):
help='Build documentation for web hosting')
opt.add_option('--no-plugins', action='store_true', dest='no_plugins',
help='Do not build example plugins')
+ opt.add_option('--no-cxx', action='store_true', dest='no_cxx',
+ help='Do not build C++ plugins')
opt.add_option('--copy-headers', action='store_true', dest='copy_headers',
help='Copy headers instead of linking to bundle')
opt.recurse('lv2/lv2plug.in/ns/lv2core')
@@ -43,11 +46,17 @@ def configure(conf):
Options.options.build_tests = False
Options.options.no_plugins = True
+ if not Options.options.no_plugins and not Options.options.no_cxx:
+ conf.load('compiler_cxx')
+ conf.env.BUILD_CXX = True
+
if Options.options.online_docs:
Options.options.docs = True
autowaf.configure(conf)
autowaf.set_c99_mode(conf)
+ if conf.env.BUILD_CXX:
+ conf.env.append_value('CXXFLAGS', ['-std=c++0x'])
if Options.options.ultra_strict:
conf.env.append_value('CFLAGS', ['-Wconversion'])