blob: 4cd9ba3932a35ab4be84b6940ece6acda786583d [file] [log] [blame]
Deepak Kodihalli3c275e12019-09-21 06:39:39 -05001headers = [
2 'base.h',
3 'pldm_types.h',
4 'platform.h',
5 'bios.h',
John Wang02700402019-10-06 16:34:29 +08006 'bios_table.h',
Deepak Kodihalli3c275e12019-09-21 06:39:39 -05007 'states.h',
Jinu Joy Thomas8e92c6c2019-08-06 12:22:34 +05308 'fru.h',
John Wangd8702f62019-10-31 10:06:35 +08009 'utils.h'
Deepak Kodihalli3c275e12019-09-21 06:39:39 -050010]
11
12sources = [
13 'base.c',
14 'platform.c',
Jinu Joy Thomas8e92c6c2019-08-06 12:22:34 +053015 'bios.c',
John Wang02700402019-10-06 16:34:29 +080016 'bios_table.c',
Jinu Joy Thomas8e92c6c2019-08-06 12:22:34 +053017 'fru.c',
John Wangd8702f62019-10-31 10:06:35 +080018 'utils.c'
Deepak Kodihalli3c275e12019-09-21 06:39:39 -050019]
20
21libpldm_headers = ['.', '..']
22
23if get_option('oem-ibm').enabled()
24 headers += [
25 '../oem/ibm/libpldm/file_io.h'
26 ]
27 sources += [
28 '../oem/ibm/libpldm/file_io.c'
29 ]
30 libpldm_headers += ['../oem/ibm']
31endif
32
33install_headers(
34 headers,
35 subdir: 'libpldm')
36
37libpldm = library(
Deepak Kodihalli535efa02019-10-08 11:52:42 -050038 'pldm',
Deepak Kodihalli3c275e12019-09-21 06:39:39 -050039 sources,
40 implicit_include_directories: false,
41 include_directories: include_directories(libpldm_headers),
42 version: meson.project_version(),
43 install: true)
44
45libpldm = declare_dependency(
46 include_directories: include_directories(libpldm_headers),
47 link_with: libpldm)
48
49import('pkgconfig').generate(
50 name: 'libpldm',
51 description: 'PLDM protocol encode/decode C lib',
52 version: meson.project_version(),
53 libraries: libpldm)