| 1 |
## SPDX-License-Identifier: GPL-2.0-only |
| 2 |
|
| 3 |
# Polkit Files |
| 4 |
polkit_dir = join_paths(get_option('datadir'), 'polkit-1', 'actions') |
| 5 |
polkit_sources = [ |
| 6 |
'org.coreboot.nvramtool.policy', |
| 7 |
'org.coreboot.reboot.policy', |
| 8 |
] |
| 9 |
|
| 10 |
install_data(polkit_sources, |
| 11 |
install_dir: polkit_dir) |
| 12 |
|
| 13 |
# Desktop Entry |
| 14 |
desktop_dir = join_paths(get_option('datadir'), 'applications') |
| 15 |
desktop_sources = [ |
| 16 |
'coreboot-configurator.desktop', |
| 17 |
] |
| 18 |
|
| 19 |
install_data(desktop_sources, |
| 20 |
install_dir: desktop_dir) |
| 21 |
|
| 22 |
# Icon |
| 23 |
inkscape = find_program('inkscape') |
| 24 |
icon_dir = join_paths(get_option('datadir'),'icons', 'hicolor') |
| 25 |
foreach size: get_option('sizes') |
| 26 |
target_temp_name = '@0@'.format(size) |
| 27 |
dpi=size.to_int() * 2 |
| 28 |
png = configure_file( |
| 29 |
input: 'coreboot_configurator.svg', |
| 30 |
output: target_temp_name + '.png', |
| 31 |
command: [ |
| 32 |
inkscape, |
| 33 |
'--export-height=@0@'.format(size), |
| 34 |
'--export-width=@0@'.format(size), |
| 35 |
'--export-png=@OUTPUT@', |
| 36 |
'@INPUT@', |
| 37 |
] |
| 38 |
) |
| 39 |
|
| 40 |
install_data(png, |
| 41 |
rename: meson.project_name() + '.png', |
| 42 |
install_dir: join_paths(icon_dir, '@0@x@1@'.format(size, size), 'apps')) |
| 43 |
endforeach |