dwm-speedie/meson.build
2024-01-18 18:59:11 +01:00

82 lines
2.2 KiB
Meson

project(
'dwm',
'c',
version : '"6.4"',
default_options : ['warning_level=3']
)
cc = meson.get_compiler('c')
project_source_files = [
'drw.c',
'dwm.c',
'util.c',
]
project_status_source_files = [
'status.c',
]
project_dependencies = [
dependency('xft'),
dependency('pango'),
dependency('pangoxft'),
dependency('x11'),
dependency('xcb'),
dependency('xcb-res'),
dependency('x11-xcb'),
dependency('xrender'),
cc.find_library('m', required : false),
]
project_status_dependencies = [
dependency('x11'),
]
build_args = [
'-DVERSION=' + meson.project_version(),
]
build_status_args = [
'-DVERSION=' + meson.project_version(),
]
if get_option('xinerama')
project_dependencies += [ dependency('xinerama') ]
build_args += [ '-DXINERAMA' ]
endif
project_target = executable(
meson.project_name(),
project_source_files, install : true,
dependencies: project_dependencies,
c_args : build_args,
)
project_status_target = executable(
'dwm_status',
project_status_source_files, install : true,
dependencies : project_status_dependencies,
c_args : build_status_args,
)
install_data(sources : 'modules/module_bat', install_dir : 'bin')
install_data(sources : 'modules/module_config', install_dir : 'bin')
install_data(sources : 'modules/module_date', install_dir : 'bin')
install_data(sources : 'modules/module_dfmpeg', install_dir : 'bin')
install_data(sources : 'modules/module_email', install_dir : 'bin')
install_data(sources : 'modules/module_music', install_dir : 'bin')
install_data(sources : 'modules/module_net', install_dir : 'bin')
install_data(sources : 'modules/module_news', install_dir : 'bin')
install_data(sources : 'modules/module_ram', install_dir : 'bin')
install_data(sources : 'modules/module_temp', install_dir : 'bin')
install_data(sources : 'modules/module_time', install_dir : 'bin')
install_data(sources : 'modules/module_toggle', install_dir : 'bin')
install_data(sources : 'modules/module_vol', install_dir : 'bin')
install_data(sources : 'modules/module_weather', install_dir : 'bin')
install_data(sources : 'dwm_init', install_dir : 'bin')
install_data(sources : 'dwm.desktop', install_dir : 'share/xsessions')
test('dwm', project_target)
test('dwm_status', project_status_target)