1phosphor_logging_includes = include_directories('include') 2 3phosphor_logging_gen = [] 4 5subdir('include/phosphor-logging') 6 7threads_dep = dependency('threads') 8 9phosphor_logging_deps = [ 10 libsystemd_dep, 11 pdi_dep, 12 sdbusplus_dep, 13 threads_dep 14] 15 16phosphor_logging_lib = library( 17 'phosphor_logging', 18 'elog.cpp', 19 'lg2_logger.cpp', 20 'sdjournal.cpp', 21 phosphor_logging_gen, 22 implicit_include_directories: false, 23 include_directories: phosphor_logging_includes, 24 dependencies: [ 25 phosphor_logging_deps, 26 conf_h_dep, 27 ], 28 version: meson.project_version(), 29 install: true, 30) 31 32phosphor_logging_reqs = [] 33foreach dep : phosphor_logging_deps 34 if dep.type_name() == 'pkgconfig' 35 phosphor_logging_reqs += dep 36 endif 37endforeach 38 39import('pkgconfig').generate( 40 phosphor_logging_lib, 41 name: 'phosphor-logging', 42 version: meson.project_version(), 43 requires: phosphor_logging_reqs, 44 description: 'Phosphor logging utilities', 45) 46 47phosphor_logging_dep = declare_dependency( 48 include_directories: phosphor_logging_includes, 49 link_with: phosphor_logging_lib, 50 sources: phosphor_logging_gen, 51 dependencies: phosphor_logging_deps, 52) 53 54