+38
−0
+126
−18
pkgs/by-name/ed/edgetx/targets.nix
0 → 100644
+46
−0
Loading
Previously the companion was built only for a single default target.
This is very unexpected. Upstream build system is a huge pain, so
our build will also look very hacky. For reference [1] is how upstream
builds their repo. I've tried to make the derivation not very cringeworthy,
but there's a lot of complexity piled on.
Some specific problems to keep an eye out for:
- All targets have to be enumerated by hand. I've put it into a separate
file to improve readability.
- libclang shenanigans. Upstream uses python bindings for `libclang` to
generate code at compile time. To make it find C/C++ standard library
headers we have to patch the scripts and read nix-support/{libc,libcxx}-cflags
to extract the necessary compiler flags that cc-wrapper usually handles for us.
[1]: https://github.com/EdgeTX/edgetx/blob/v2.11.0-rc3/tools/build-companion.sh