Meson build system cannot be used for cross builds #661
Labels
No labels
3rdparty
Android
API
Author does not respond
bsd
bug
build system/CI
ci-virtual-device
CMake
Contributions Welcome
Core
dependencies
device-specific
documentation
don't_merge
duplicate
enhancement
Example
Haiku
hidraw
hotplug
info required
invalid
libusb
macOS
Misc
Not an issue
question
Release
Test
Test GUI
Windows
wontfix
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
gh-libusb/hidapi#661
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Hi,
This is to report that CMake-based subprojects, like the one hidapi's Meson build system uses, do not work for cross builds: https://github.com/mesonbuild/meson/issues/12761
We found this issue when attempting to cross compile https://github.com/blackmagic-debug/blackmagic from arm64 AppleClang to arm64-none-eabi-gcc (see towards the end).
Is this something that may be fixed by modifying https://github.com/libusb/hidapi/blob/master/meson.build + https://github.com/libusb/hidapi/blob/master/subprojects/hidapi_build_cmake/CMakeLists.txt or is this a general limitation of https://mesonbuild.com/CMake-module.html ?
Neither, Meson currently just doesn't pass the correct variables in the toolchain file (it passes the build machine's and not the host's). The only way we know to fix it is turn the meson.build into a complete port.
So we're back to the question "who is going to support it?".
Multiple supported build systems is not something any sain maintainer would sign up just for convenience.
The community is free to have its own implementation of Meson build system for HIDAPI.
Similar way to how https://github.com/trezor/cython-hidapi exists.
Closing as a limitation of Meson's CMake-module.html.