Open VorpalBlade opened 1 year ago
Yes!
See https://github.com/cross-rs/cross/wiki/Configuration#build
[build]
pre-build = [
"dpkg --add-architecture $CROSS_DEB_ARCH",
"apt-get update && apt-get install --assume-yes libssl-dev:$CROSS_DEB_ARCH"
]
hmm, I'll actually reopen this, it could maybe be useful to have cfg()
and wildcards
so
[target."*linux*"]
and target."cfg(feature = "feat").<target>"
[target."*linux*"]
andtarget."cfg(feature = "feat").<target>"
Having this feature would be really nice.
Checklist
Describe your request
I need to install OpenSSL when cross compiling to other Linux architectures (e.g. ARM, Aarch64, i686). However the documented command in https://github.com/cross-rs/cross/wiki/Recipes#openssl would as far as I understand lead to code duplication.
I can't find anywhere to specify a glob pattern, e.g.:
(and that specific syntax does not work). Do I really need to duplicate this for every single architecture I want to compile to? Or is there a way to stick to the DRY principle (Don't Repeat Yourself)?
Describe why this would be a good inclusion for
cross
If this is not supported, it seems like an obvious feature to avoid repetition (and risk of these lines getting out of sync). All matching sections should be applied (e.g. apply both a
*windows*
and a*x86_64-pc-windows*
section when building for 64-bit windows)Adding a custom docker image for each architecture, maintaining that, and dealing with CI for it is way outside of my personal project scope as well as outside my expertise. Especially since I plan to use a ready-made GitHub CI action to do this (once I confirm everything works locally).