meson: adjust nlohmann-json dependency

- Simplify the nlohmann-json dependency logic in meson.build
- Change wrap file name to align with other repositories.
- Use HEAD for nlohmann-json revision rather than a pinned version.

Signed-off-by: Patrick Williams <patrick@stwcx.xyz>
Change-Id: I5ba6cc684c7c2dc8889e9a4cd882d5c6840b4b92
diff --git a/meson.build b/meson.build
index f2502a1..93a2177 100644
--- a/meson.build
+++ b/meson.build
@@ -10,6 +10,8 @@
     ]
 )
 
+cpp = meson.get_compiler('cpp')
+
 conf_data = configuration_data()
 conf_data.set_quoted('LED_JSON_FILE', '/usr/share/phosphor-led-manager/led-group-config.json')
 conf_data.set_quoted('SAVED_GROUPS_FILE', '/var/lib/phosphor-led-manager/savedGroups')
@@ -24,26 +26,15 @@
 conf_data.set('MONITOR_OPERATIONAL_STATUS', get_option('monitor-operational-status').allowed())
 conf_data.set('PERSISTENT_LED_ASSERTED', get_option('persistent-led-asserted').allowed())
 
-sdbusplus_dep = dependency('sdbusplus')
-sdeventplus_dep = dependency('sdeventplus')
+nlohmann_json_dep = dependency('nlohmann_json', include_type: 'system')
 phosphor_dbus_interfaces_dep = dependency('phosphor-dbus-interfaces')
 phosphor_logging_dep = dependency('phosphor-logging')
+sdbusplus_dep = dependency('sdbusplus')
+sdeventplus_dep = dependency('sdeventplus')
 
 prog_python = find_program('python3', required: true)
 realpath_prog = find_program('realpath')
 
-cpp = meson.get_compiler('cpp')
-if cpp.has_header('nlohmann/json.hpp')
-    nlohmann_json_dep = declare_dependency()
-else
-    subproject('nlohmann', required: false)
-    nlohmann_json_dep = declare_dependency(
-        include_directories: [
-            'subprojects/nlohmann/single_include',
-            'subprojects/nlohmann/single_include/nlohmann',
-        ]
-    )
-endif
 
 if cpp.has_header('CLI/CLI.hpp')
     CLI11_dep = declare_dependency()
diff --git a/subprojects/nlohmann.wrap b/subprojects/nlohmann.wrap
deleted file mode 100644
index a77b7c9..0000000
--- a/subprojects/nlohmann.wrap
+++ /dev/null
@@ -1,3 +0,0 @@
-[wrap-git]
-revision = b3e5cb7f20dcc5c806e418df34324eca60d17d4e
-url = https://github.com/nlohmann/json.git
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