bin: meson.build: conditionnally build binaries

Neither vlc.c nor darwinvlc.m can be compiled against iOS SDK currently
so only build them on other platforms than iOS and tvOS.
This commit is contained in:
Alexandre Janniaux 2023-02-06 11:26:45 +01:00 committed by Jean-Baptiste Kempf
parent f2c8b28974
commit 748f6e6a11
1 changed files with 4 additions and 2 deletions

View File

@ -1,7 +1,7 @@
# Do we build the main VLC binary?
build_vlc = get_option('vlc')
if build_vlc
if build_vlc and (host_system != 'darwin' or have_osx)
vlc_sources = []
vlc_deps = [m_lib, dl_lib, threads_dep]
@ -9,7 +9,9 @@ if build_vlc
if host_system == 'darwin'
vlc_sources += ['darwinvlc.m']
vlc_deps += corefoundation_dep
vlc_deps += dependency('Cocoa', required: true)
if have_osx
vlc_deps += dependency('Cocoa', required: true)
endif
elif host_system == 'windows'
vlc_sources += ['winvlc.c']
else