meson: adjust nlohmann-json dependency

Simplify the nlohmann-json dependency in meson and align with the
usage from other repositories for consistency.

Change-Id: I6dcbd19a055b83fc8a5955cb6fe0bbdc9876ef42
Signed-off-by: Patrick Williams <patrick@stwcx.xyz>
diff --git a/meson.build b/meson.build
index ca7cb1b..1f5a75c 100644
--- a/meson.build
+++ b/meson.build
@@ -28,19 +28,13 @@
   'ipmid/api.h',
   'ipmid_get_sd_bus_connection')
 
-json_dep = dependency('nlohmann_json', required: false)
-meson.get_compiler('cpp').has_header_symbol(
-  'nlohmann/json.hpp',
-  'nlohmann::json',
-  dependencies: json_dep)
-
 stdplus = dependency('stdplus')
 subdir('bifurcation')
 
 sys_pre = declare_dependency(
   include_directories: root_inc,
   dependencies: [
-    json_dep,
+    dependency('nlohmann_json', include_type: 'system'),
     dependency('phosphor-dbus-interfaces'),
     dependency('phosphor-logging'),
     dependency('sdbusplus'),
diff --git a/subprojects/nlohmann_json.wrap b/subprojects/nlohmann_json.wrap
new file mode 100644
index 0000000..3745380
--- /dev/null
+++ b/subprojects/nlohmann_json.wrap
@@ -0,0 +1,6 @@
+[wrap-git]
+revision = HEAD
+url = https://github.com/nlohmann/json.git
+
+[provide]
+nlohmann_json = nlohmann_json_dep