Add meson build support

Tested:
1. Project builds with each meson option turned on or off.
2. Unit tests build and pass.
3. On platform FW built with updated recipe
   (I23fabdf57b8d6ac35c3aea0ece667be118de4b61):
    a. SMBIOS blob store library is properly picked up by IPMI blob
       store manager and handles OEM IPMI commands.
    b. smbiosmdrv2app is running and populates objects on D-Bus.
    c. cpuinfoapp is running and populates objects on D-Bus.

Change-Id: Ie65b281900cc07e7d0145445bcc65bbab1979214
Signed-off-by: Jonathan Doman <jonathan.doman@intel.com>
diff --git a/src/meson.build b/src/meson.build
new file mode 100644
index 0000000..4a54d28
--- /dev/null
+++ b/src/meson.build
@@ -0,0 +1,60 @@
+cpp_args_smbios = boost_args
+if get_option('dimm-dbus').allowed()
+  cpp_args_smbios += ['-DDIMM_DBUS']
+endif
+
+if get_option('dimm-only-locator').allowed()
+  cpp_args_smbios += ['-DDIMM_ONLY_LOCATOR']
+endif
+
+executable(
+  'smbiosmdrv2app',
+  'mdrv2.cpp',
+  'mdrv2_main.cpp',
+  'cpu.cpp',
+  'dimm.cpp',
+  'system.cpp',
+  'pcieslot.cpp',
+  cpp_args: cpp_args_smbios,
+  dependencies: [
+    boost_dep,
+    sdbusplus_dep,
+    phosphor_logging_dep,
+    phosphor_dbus_interfaces_dep,
+  ],
+  implicit_include_directories: false,
+  include_directories: root_inc,
+  install: true,
+)
+
+if get_option('cpuinfo').allowed()
+  cpp = meson.get_compiler('cpp')
+  # i2c-tools provides no pkgconfig so we need to find it manually
+  i2c_dep = cpp.find_library('i2c')
+
+  peci_dep = dependency('libpeci')
+
+  executable(
+    'cpuinfoapp',
+    'cpuinfo_main.cpp',
+    'speed_select.cpp',
+    'sst_mailbox.cpp',
+    'cpuinfo_utils.cpp',
+    cpp_args: boost_args,
+    dependencies: [
+      boost_dep,
+      sdbusplus_dep,
+      phosphor_logging_dep,
+      phosphor_dbus_interfaces_dep,
+      i2c_dep,
+      peci_dep,
+    ],
+    implicit_include_directories: false,
+    include_directories: root_inc,
+    install: true,
+  )
+endif
+
+if get_option('smbios-ipmi-blob').allowed()
+  subdir('smbios-ipmi-blobs')
+endif