Skip to content

Commit d97e5b2

Browse files
committed
nlohmannjson is now fetched dynamically.
1 parent 86024bf commit d97e5b2

4 files changed

Lines changed: 22 additions & 15 deletions

File tree

.gitmodules

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,3 @@
2525
[submodule "dep/lunasvg"]
2626
path = dep/lunasvg
2727
url = https://github.com/sammycage/lunasvg.git
28-
[submodule "dep/nlohmann_json"]
29-
path = dep/nlohmann_json
30-
url = https://github.com/nlohmann/json

dep/build.py

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -273,3 +273,24 @@
273273
],
274274
),
275275
)
276+
277+
package(
278+
name="nlohmannjson_lib",
279+
package="nlohmann_json",
280+
fallback=cxxlibrary(
281+
name="nlohmannjson_fallback_lib",
282+
srcs=[],
283+
hdrs={
284+
h: f"dep/nlohmann_json/single_include/{h}"
285+
for h in ["nlohmann/json_fwd.hpp", "nlohmann/json.hpp"]
286+
},
287+
deps=[
288+
git_repository(
289+
name="nlohmannjson_repo",
290+
url="https://github.com/nlohmann/json",
291+
branch="v3.12.0",
292+
path="dep/nlohmann_json",
293+
)
294+
],
295+
),
296+
)

dep/nlohmann_json

Lines changed: 0 additions & 1 deletion
This file was deleted.

src/gui2/build.py

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -44,16 +44,6 @@ def sources_from(path, except_for=[]):
4444
package(name="magic_lib", package="libmagic")
4545
package(name="mbedtls_lib", package="mbedtls")
4646

47-
package(
48-
name="nlohmannjson_lib",
49-
package="nlohmann_json",
50-
fallback=cxxlibrary(
51-
name="nlohmannjson_fallback_lib",
52-
srcs=[],
53-
hdrs=headers_from("dep/nlohmann_json/single_include"),
54-
),
55-
)
56-
5747
if config.osx:
5848
clibrary(
5949
name="libnfd",
@@ -226,7 +216,7 @@ def sources_from(path, except_for=[]):
226216
".+libwolv",
227217
"+fmt_lib",
228218
"dep+cli11_lib",
229-
".+nlohmannjson_lib",
219+
"dep+nlohmannjson_lib",
230220
],
231221
)
232222

0 commit comments

Comments
 (0)