William A. Kennington III | 1bbe3d1 | 2021-05-13 23:45:09 -0700 | [diff] [blame] | 1 | src_includes = include_directories('.') |
| 2 | |
William A. Kennington III | e7c5aaa | 2022-10-06 13:17:15 -0700 | [diff] [blame] | 3 | stdplus_dep = dependency('stdplus') |
William A. Kennington III | a68ab4b | 2021-10-07 19:16:16 -0700 | [diff] [blame] | 4 | |
William A. Kennington III | 1bbe3d1 | 2021-05-13 23:45:09 -0700 | [diff] [blame] | 5 | executable( |
| 6 | 'ncsi-netlink', |
| 7 | 'argument.cpp', |
| 8 | 'ncsi_netlink_main.cpp', |
| 9 | 'ncsi_util.cpp', |
| 10 | implicit_include_directories: false, |
| 11 | include_directories: src_includes, |
| 12 | dependencies: [ |
| 13 | dependency('libnl-3.0'), |
| 14 | dependency('libnl-genl-3.0'), |
Jagpal Singh Gill | d423beb | 2023-04-18 11:28:03 -0700 | [diff] [blame] | 15 | dependency('phosphor-logging'), |
William A. Kennington III | e7c5aaa | 2022-10-06 13:17:15 -0700 | [diff] [blame] | 16 | stdplus_dep, |
William A. Kennington III | 1bbe3d1 | 2021-05-13 23:45:09 -0700 | [diff] [blame] | 17 | ], |
| 18 | install: true, |
| 19 | install_dir: get_option('bindir')) |
| 20 | |
William A. Kennington III | 0b111d4 | 2022-10-04 18:06:11 -0700 | [diff] [blame] | 21 | main_deps = [] |
| 22 | main_srcs = [] |
William A. Kennington III | 1bbe3d1 | 2021-05-13 23:45:09 -0700 | [diff] [blame] | 23 | if get_option('sync-mac') |
William A. Kennington III | 0b111d4 | 2022-10-04 18:06:11 -0700 | [diff] [blame] | 24 | main_srcs += [ |
| 25 | 'inventory_mac.cpp', |
| 26 | ] |
William A. Kennington III | 0b111d4 | 2022-10-04 18:06:11 -0700 | [diff] [blame] | 27 | main_deps += [ |
Patrick Williams | 1f0052f | 2023-12-07 17:08:49 -0600 | [diff] [blame] | 28 | dependency('nlohmann_json', include_type: 'system') |
William A. Kennington III | 0b111d4 | 2022-10-04 18:06:11 -0700 | [diff] [blame] | 29 | ] |
William A. Kennington III | 1bbe3d1 | 2021-05-13 23:45:09 -0700 | [diff] [blame] | 30 | endif |
| 31 | |
| 32 | networkd_deps = [ |
William A. Kennington III | 1bbe3d1 | 2021-05-13 23:45:09 -0700 | [diff] [blame] | 33 | phosphor_dbus_interfaces_dep, |
William A. Kennington III | e7c5aaa | 2022-10-06 13:17:15 -0700 | [diff] [blame] | 34 | dependency('phosphor-logging'), |
William A. Kennington III | 37cf66c | 2021-05-17 14:56:54 -0700 | [diff] [blame] | 35 | networkd_dbus_dep, |
William A. Kennington III | 1bbe3d1 | 2021-05-13 23:45:09 -0700 | [diff] [blame] | 36 | sdbusplus_dep, |
William A. Kennington III | e7c5aaa | 2022-10-06 13:17:15 -0700 | [diff] [blame] | 37 | stdplus_dep, |
William A. Kennington III | 1bbe3d1 | 2021-05-13 23:45:09 -0700 | [diff] [blame] | 38 | ] |
| 39 | |
| 40 | conf_header = configure_file( |
| 41 | output: 'config.h', |
| 42 | configuration: conf_data) |
| 43 | |
William A. Kennington III | 1bbe3d1 | 2021-05-13 23:45:09 -0700 | [diff] [blame] | 44 | networkd_lib = static_library( |
| 45 | 'networkd', |
William A. Kennington III | 37cf66c | 2021-05-17 14:56:54 -0700 | [diff] [blame] | 46 | conf_header, |
William A. Kennington III | 1bbe3d1 | 2021-05-13 23:45:09 -0700 | [diff] [blame] | 47 | 'ethernet_interface.cpp', |
| 48 | 'neighbor.cpp', |
| 49 | 'ipaddress.cpp', |
| 50 | 'netlink.cpp', |
William A. Kennington III | 1bbe3d1 | 2021-05-13 23:45:09 -0700 | [diff] [blame] | 51 | 'network_manager.cpp', |
William A. Kennington III | a7344c3 | 2022-10-31 14:12:27 -0700 | [diff] [blame] | 52 | 'rtnetlink.cpp', |
William A. Kennington III | 1bbe3d1 | 2021-05-13 23:45:09 -0700 | [diff] [blame] | 53 | 'system_configuration.cpp', |
William A. Kennington III | 2e09d27 | 2022-10-14 17:15:00 -0700 | [diff] [blame] | 54 | 'system_queries.cpp', |
William A. Kennington III | bb0eacc | 2022-10-21 15:22:06 -0700 | [diff] [blame] | 55 | 'types.cpp', |
William A. Kennington III | 1bbe3d1 | 2021-05-13 23:45:09 -0700 | [diff] [blame] | 56 | 'util.cpp', |
William A. Kennington III | 1bbe3d1 | 2021-05-13 23:45:09 -0700 | [diff] [blame] | 57 | 'config_parser.cpp', |
| 58 | 'dhcp_configuration.cpp', |
William A. Kennington III | 1bbe3d1 | 2021-05-13 23:45:09 -0700 | [diff] [blame] | 59 | 'dns_updater.cpp', |
William A. Kennington III | 1bbe3d1 | 2021-05-13 23:45:09 -0700 | [diff] [blame] | 60 | implicit_include_directories: false, |
William A. Kennington III | 37cf66c | 2021-05-17 14:56:54 -0700 | [diff] [blame] | 61 | include_directories: src_includes, |
William A. Kennington III | 1bbe3d1 | 2021-05-13 23:45:09 -0700 | [diff] [blame] | 62 | dependencies: networkd_deps) |
| 63 | |
| 64 | networkd_dep = declare_dependency( |
William A. Kennington III | 37cf66c | 2021-05-17 14:56:54 -0700 | [diff] [blame] | 65 | sources: conf_header, |
William A. Kennington III | 1bbe3d1 | 2021-05-13 23:45:09 -0700 | [diff] [blame] | 66 | dependencies: networkd_deps, |
William A. Kennington III | 37cf66c | 2021-05-17 14:56:54 -0700 | [diff] [blame] | 67 | include_directories: src_includes, |
William A. Kennington III | 1bbe3d1 | 2021-05-13 23:45:09 -0700 | [diff] [blame] | 68 | link_with: networkd_lib) |
| 69 | |
| 70 | executable( |
| 71 | 'phosphor-network-manager', |
| 72 | 'network_manager_main.cpp', |
William A. Kennington III | de70ccf | 2022-11-20 17:18:01 -0800 | [diff] [blame] | 73 | 'rtnetlink_server.cpp', |
William A. Kennington III | 0b111d4 | 2022-10-04 18:06:11 -0700 | [diff] [blame] | 74 | main_srcs, |
William A. Kennington III | 1bbe3d1 | 2021-05-13 23:45:09 -0700 | [diff] [blame] | 75 | implicit_include_directories: false, |
William A. Kennington III | de70ccf | 2022-11-20 17:18:01 -0800 | [diff] [blame] | 76 | dependencies: main_deps + [ |
| 77 | networkd_dep, |
| 78 | dependency('sdeventplus'), |
| 79 | ], |
William A. Kennington III | 1bbe3d1 | 2021-05-13 23:45:09 -0700 | [diff] [blame] | 80 | install: true, |
| 81 | install_dir: get_option('bindir')) |
Asmitha Karunanithi | be2bdec | 2021-05-13 02:54:29 -0500 | [diff] [blame] | 82 | |
| 83 | if (get_option('hyp-nw-config') == true) |
| 84 | subdir('ibm') |
| 85 | endif |