Dung Cao | faf6a6a | 2020-12-28 04:44:45 +0000 | [diff] [blame] | 1 | project('ssifbridge', 'cpp', |
| 2 | default_options: [ |
| 3 | 'buildtype=debugoptimized', |
| 4 | 'warning_level=3', |
| 5 | 'werror=true', |
| 6 | 'cpp_std=c++17' |
| 7 | ], |
| 8 | version: '1.0', |
Thang Q. Nguyen | 20c6f95 | 2020-12-09 03:28:44 +0000 | [diff] [blame] | 9 | ) |
| 10 | |
Dung Cao | faf6a6a | 2020-12-28 04:44:45 +0000 | [diff] [blame] | 11 | add_project_arguments('-Wno-psabi', language: 'cpp') |
Thang Q. Nguyen | 20c6f95 | 2020-12-09 03:28:44 +0000 | [diff] [blame] | 12 | |
| 13 | deps = [dependency('libsystemd', version : '>=221'), |
| 14 | dependency('systemd'), |
Dung Cao | faf6a6a | 2020-12-28 04:44:45 +0000 | [diff] [blame] | 15 | dependency('phosphor-logging'), |
| 16 | dependency('sdbusplus'), |
| 17 | dependency('threads') |
Thang Q. Nguyen | 20c6f95 | 2020-12-09 03:28:44 +0000 | [diff] [blame] | 18 | |
Dung Cao | faf6a6a | 2020-12-28 04:44:45 +0000 | [diff] [blame] | 19 | ] |
| 20 | |
Dung Cao | f624941 | 2021-01-14 03:41:56 +0000 | [diff] [blame^] | 21 | # Configure and install systemd unit files |
| 22 | systemd = dependency('systemd') |
| 23 | systemd_system_unit_dir = systemd.get_pkgconfig_variable( |
| 24 | 'systemdsystemunitdir', |
| 25 | define_variable: ['prefix', get_option('prefix')]) |
| 26 | |
| 27 | configure_file( |
| 28 | copy: true, |
| 29 | input: 'ssifbridge.service', |
| 30 | install: true, |
| 31 | install_dir: systemd_system_unit_dir, |
| 32 | output: 'ssifbridge.service' |
| 33 | ) |
| 34 | |
Dung Cao | faf6a6a | 2020-12-28 04:44:45 +0000 | [diff] [blame] | 35 | executable('ssifbridged','ssifbridged.cpp', |
Thang Q. Nguyen | 20c6f95 | 2020-12-09 03:28:44 +0000 | [diff] [blame] | 36 | dependencies: deps, |
| 37 | install: true) |