aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDavid Robillard <d@drobilla.net>2020-11-11 20:09:22 +0100
committerDavid Robillard <d@drobilla.net>2020-11-11 20:09:22 +0100
commit793e35394173b7df6e43eb18c780213c734e56f3 (patch)
treee3efb8ed15a365abb690539b46cb0619ffa9a911
parentbacd25745314cfcb71dfe061d4a91052eba5f7f4 (diff)
downloadserd-793e35394173b7df6e43eb18c780213c734e56f3.tar.gz
serd-793e35394173b7df6e43eb18c780213c734e56f3.tar.bz2
serd-793e35394173b7df6e43eb18c780213c734e56f3.zip
Set up environment for using serdi as a subproject
-rw-r--r--wscript9
1 files changed, 9 insertions, 0 deletions
diff --git a/wscript b/wscript
index e7aed89b..9eae8add 100644
--- a/wscript
+++ b/wscript
@@ -132,8 +132,17 @@ def configure(conf):
defines = ['_POSIX_C_SOURCE=200809L'],
mandatory = False)
+ # Set up environment for building/using as a subproject
autowaf.set_lib_env(conf, 'serd', SERD_VERSION,
include_path=str(conf.path.find_node('include')))
+
+ if conf.env.BUILD_TESTS:
+ serdi_node = conf.path.get_bld().make_node('serdi_static')
+ else:
+ serdi_node = conf.path.get_bld().make_node('serdi')
+
+ conf.env.SERDI = [os.path.abspath(str(serdi_node))]
+
conf.write_config_header('serd_config.h', remove=False)
autowaf.display_summary(