Add option to disable examples build

Compiling the examples is useful for testing and development, but less
useful for actual users of wlroots.
This commit adds the option --enable-examples to set weather to include
the examples at compilation or not. The default value is True, so the
current behaviour remains unchanged.
This commit is contained in:
florian.weigelt 2018-05-05 09:50:10 +02:00
parent 34be87a3f6
commit d68a27fd79
2 changed files with 4 additions and 1 deletions

View file

@ -205,7 +205,9 @@ if get_option('enable-rootston')
subdir('rootston') subdir('rootston')
endif endif
if get_option('enable-examples')
subdir('examples') subdir('examples')
endif
pkgconfig = import('pkgconfig') pkgconfig = import('pkgconfig')
pkgconfig.generate( pkgconfig.generate(

View file

@ -5,3 +5,4 @@ option('enable-xcb_errors', type: 'combo', choices: ['auto', 'true', 'false'], v
option('enable-xwayland', type: 'boolean', value: true, description: 'Enable support X11 applications') option('enable-xwayland', type: 'boolean', value: true, description: 'Enable support X11 applications')
option('enable-x11_backend', type: 'boolean', value: true, description: 'Enable X11 backend') option('enable-x11_backend', type: 'boolean', value: true, description: 'Enable X11 backend')
option('enable-rootston', type: 'boolean', value: true, description: 'Build the rootston example compositor') option('enable-rootston', type: 'boolean', value: true, description: 'Build the rootston example compositor')
option('enable-examples', type: 'boolean', value: true, description: 'Build example applications')