blob: b429dd8b8e8b2c543e707705cfcc6ce7ffbbb256 [file] [log] [blame]
Zane Shelleyba5dc162020-11-09 21:47:55 -06001# OpenBMC openpower-libhei project, see README.md for details.
Ben Tyner941aaeb2019-04-26 17:38:10 -05002project('openpower-libhei', 'cpp',
Paul Greenwooddc47e0a2019-11-01 16:22:57 -05003 version: '0.1', meson_version: '>=0.50.0',
Ben Tyner941aaeb2019-04-26 17:38:10 -05004 default_options: [
5 'warning_level=3',
6 'werror=true',
Zane Shelley83a8d552020-05-07 15:08:52 -05007 'cpp_std=c++14',
Ben Tyner0fa81f72019-09-05 14:30:02 -05008 'cpp_args=-Wno-unused-parameter'
9 ])
Ben Tyner941aaeb2019-04-26 17:38:10 -050010
Zane Shelleyba5dc162020-11-09 21:47:55 -060011#-------------------------------------------------------------------------------
12# libhei library
13#-------------------------------------------------------------------------------
14
Ben Tyner032bf9e2020-05-06 21:27:54 -050015incdir = include_directories('src')
Ben Tyner941aaeb2019-04-26 17:38:10 -050016
Zane Shelleydd69c962020-05-05 22:19:11 -050017libhei_src = [
18 'src/chip_data/hei_chip_data.cpp',
19 'src/isolator/hei_isolator.cpp',
20 'src/isolator/hei_isolation_chip.cpp',
21 'src/isolator/hei_isolation_node.cpp',
22 'src/register/hei_hardware_register.cpp',
23 'src/util/hei_bit_string.cpp',
24]
Ben Tyner7c796052020-02-03 19:00:37 -060025
26libhei_dep = declare_dependency(include_directories : incdir,
27 sources : libhei_src)
28
Ben Tyner032bf9e2020-05-06 21:27:54 -050029# build static library libhei.a (note that the libray name is hei, the
30# resulting filename will be libhei.a)
31libhei_static = static_library('hei',
32 dependencies: libhei_dep,
33 install: true)
34
Zane Shelley3a02e242020-05-08 16:25:36 -050035install_headers(
36 'src/hei_chip.hpp',
37 'src/hei_isolation_data.hpp',
38 'src/hei_main.hpp',
39 'src/hei_signature.hpp',
40 'src/hei_types.hpp',
41 'src/hei_user_interface.hpp',
42 subdir : 'libhei'
43)
Ben Tyner032bf9e2020-05-06 21:27:54 -050044
45pkg_mod = import('pkgconfig')
46
47pkg_mod.generate(libraries : libhei_static,
48 version : '0.1',
49 name : 'libhei',
50 subdirs: 'libhei',
51 filebase : 'hei',
52 description : 'Openpower Hardware Error Isolator')
53
Zane Shelleyba5dc162020-11-09 21:47:55 -060054#-------------------------------------------------------------------------------
55# Chip Data Files
56#-------------------------------------------------------------------------------
57
58subdir('xml')
59
60#-------------------------------------------------------------------------------
61# Test
62#-------------------------------------------------------------------------------
63
Zane Shelleyad103b92019-07-31 15:57:54 -050064build_tests = get_option('tests')
Ben Tyner941aaeb2019-04-26 17:38:10 -050065
Zane Shelleyad103b92019-07-31 15:57:54 -050066if not build_tests.disabled()
Zane Shelleyad103b92019-07-31 15:57:54 -050067 subdir('test')
Ben Tyner941aaeb2019-04-26 17:38:10 -050068endif
Zane Shelleyba5dc162020-11-09 21:47:55 -060069