aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorGravatar wm4 <wm4@nowhere>2017-08-22 11:40:39 +0200
committerGravatar wm4 <wm4@nowhere>2017-08-22 11:40:39 +0200
commit5361c0b5d897ec7c969d2a75bb2dde345d62a59c (patch)
tree6841fd38d47d79461352df0cdb29a08cfd430815
parent09c501a40eed7cb05c73fc30ea814d1d256ac0eb (diff)
build: pick a main-fn source file only if cplayer is built
libmpv does not need this.
-rw-r--r--wscript_build.py11
1 files changed, 6 insertions, 5 deletions
diff --git a/wscript_build.py b/wscript_build.py
index e0eaec4b66..d96ff40133 100644
--- a/wscript_build.py
+++ b/wscript_build.py
@@ -119,11 +119,12 @@ def build(ctx):
ctx(features = "ebml_header", target = "ebml_types.h")
ctx(features = "ebml_definitions", target = "ebml_defs.c")
- main_fn_c = ctx.pick_first_matching_dep([
- ( "osdep/main-fn-cocoa.c", "cocoa" ),
- ( "osdep/main-fn-unix.c", "posix" ),
- ( "osdep/main-fn-win.c", "win32-desktop" ),
- ])
+ if ctx.dependency_satisfied('cplayer'):
+ main_fn_c = ctx.pick_first_matching_dep([
+ ( "osdep/main-fn-cocoa.c", "cocoa" ),
+ ( "osdep/main-fn-unix.c", "posix" ),
+ ( "osdep/main-fn-win.c", "win32-desktop" ),
+ ])
getch2_c = ctx.pick_first_matching_dep([
( "osdep/terminal-unix.c", "posix" ),