mirror of https://github.com/mpv-player/mpv
build: allow to disable building the cplayer
This commit is contained in:
parent
212374149f
commit
2e241c0a47
4
wscript
4
wscript
|
@ -728,6 +728,10 @@ scripting_features = [
|
||||||
|
|
||||||
standalone_features = [
|
standalone_features = [
|
||||||
{
|
{
|
||||||
|
'name': '--cplayer',
|
||||||
|
'desc': 'mpv CLI player',
|
||||||
|
'func': check_true
|
||||||
|
}, {
|
||||||
'name': 'win32-executable',
|
'name': 'win32-executable',
|
||||||
'desc': 'w32 executable',
|
'desc': 'w32 executable',
|
||||||
'deps_any': [ 'os-win32', 'os-cygwin'],
|
'deps_any': [ 'os-win32', 'os-cygwin'],
|
||||||
|
|
|
@ -434,16 +434,18 @@ def build(ctx):
|
||||||
install_name = '/mpv.app/Contents/Resources/' + res_basename
|
install_name = '/mpv.app/Contents/Resources/' + res_basename
|
||||||
ctx.install_as(ctx.env.BINDIR + install_name, resource)
|
ctx.install_as(ctx.env.BINDIR + install_name, resource)
|
||||||
|
|
||||||
ctx(
|
|
||||||
target = "mpv",
|
if ctx.dependency_satisfied('cplayer'):
|
||||||
source = ctx.filtered_sources(sources) + ["player/main_fn.c"],
|
ctx(
|
||||||
use = ctx.dependencies_use(),
|
target = "mpv",
|
||||||
includes = [ctx.bldnode.abspath(), ctx.srcnode.abspath()] + \
|
source = ctx.filtered_sources(sources) + ["player/main_fn.c"],
|
||||||
ctx.dependencies_includes(),
|
use = ctx.dependencies_use(),
|
||||||
features = "c cprogram",
|
includes = [ctx.bldnode.abspath(), ctx.srcnode.abspath()] + \
|
||||||
install_path = ctx.env.BINDIR,
|
ctx.dependencies_includes(),
|
||||||
**cprog_kwargs
|
features = "c cprogram",
|
||||||
)
|
install_path = ctx.env.BINDIR,
|
||||||
|
**cprog_kwargs
|
||||||
|
)
|
||||||
|
|
||||||
build_shared = ctx.dependency_satisfied('libmpv-shared')
|
build_shared = ctx.dependency_satisfied('libmpv-shared')
|
||||||
build_static = ctx.dependency_satisfied('libmpv-static')
|
build_static = ctx.dependency_satisfied('libmpv-static')
|
||||||
|
|
Loading…
Reference in New Issue