From a6da2a66080a53d5885446ea9d788470c7b259d2 Mon Sep 17 00:00:00 2001 From: wm4 Date: Mon, 10 Feb 2014 21:30:55 +0100 Subject: Add a client API example --- wscript_build.py | 11 +++++++++++ 1 file changed, 11 insertions(+) (limited to 'wscript_build.py') diff --git a/wscript_build.py b/wscript_build.py index 83d1444a9c..c5d61b27c5 100644 --- a/wscript_build.py +++ b/wscript_build.py @@ -452,6 +452,17 @@ def build(ctx): for f in headers: ctx.install_as(ctx.env.INCDIR + '/libmpv/' + f, 'libmpv/' + f) + if ctx.dependency_satisfied('client-api-examples'): + # This assumes all examples are single-file (as examples should be) + for f in ["simple"]: + ctx( + target = f, + source = "DOCS/client_api_examples/" + f + ".c", + includes = [ctx.bldnode.abspath(), ctx.srcnode.abspath()], + use = "mpv", + features = "c cprogram", + ) + if ctx.env.DEST_OS == 'win32': wrapctx = ctx( target = "mpv", -- cgit v1.2.3