anki/pylib/orjson.bzl
Damien Elmes f9e939aaff Make orjson optional again
While 32 bit platform support is probably not going to come back,
this allows Anki to run on other architectures orjson doesn't support.
2021-01-07 09:44:40 +10:00

10 lines
253 B
Python

load("@py_deps//:requirements.bzl", "requirement")
def orjson_if_available():
"Include orjson if it's listed in requirements.txt."
target = requirement("orjson")
if "not_found" in target:
return []
else:
return [target]