Skip to content

Commit

Permalink
meson: allow disabling building test executables
Browse files Browse the repository at this point in the history
They should not be built when cross-compiling and we don't have an exe_wrapper.
They can't be run directly. They may be used on another machine, so it should be
possible to force it.

Disabled on Windows for now as we can't run them because they rely on alarm().
  • Loading branch information
robUx4 authored and fkuehne committed Oct 27, 2024
1 parent f44cb4e commit 0e4be11
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 3 deletions.
10 changes: 7 additions & 3 deletions meson.build
Original file line number Diff line number Diff line change
Expand Up @@ -1064,9 +1064,13 @@ subdir('bin')
# VLC plugins
subdir('modules')

# Integration and non-regression tests, some unittest are there too but the
# modules/, src/ and lib/ folders should be favoured for those.
subdir('test')
if (get_option('tests')
.disable_auto_if(host_system in ['windows'])
.allowed())
# Integration and non-regression tests, some unittest are there too but the
# modules/, src/ and lib/ folders should be favoured for those.
subdir('test')
endif

if get_option('rust').allowed()
warning('''
Expand Down
5 changes: 5 additions & 0 deletions meson_options.txt
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,11 @@ option('vlc',
value : true,
description : 'Build the VLC executable program.')

option('tests',
type : 'feature',
value : 'auto',
description : 'Build the VLC test executables.')

option('nls',
type : 'feature',
value : 'auto',
Expand Down

0 comments on commit 0e4be11

Please sign in to comment.