Catch2 hotfix #177
No reviewers
Labels
No Label
OPS TODO
api change
breaking api change
bug
documentation
duplicate
feature
help wanted
invalid
question
wontfix
No Milestone
No Assignees
2 Participants
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: eive/eive-obsw#177
Loading…
Reference in New Issue
Block a user
No description provided.
Delete Branch "mueller/suppress-catch2-warning"
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?
The cleanest solution would be to specify in the build generation whether unittests or the primary OBSW is built. This is because the one generated Makefile now works for both unittest compilation and cross-compilation, but I don't think CMake was designed for this.
the
project
call will load the toolchain file, which messes up the regular search paths for CMake modules. Even when one configures the toolchain file to also search in the host path, CMake will rightfully not accept the Catch2 installation, probably because of the architecture missmatch. It probably assumes that the goal is the cross-compilation of the unittest.Clean solution would be to only call
find_package
if unittests are built. For this, the cleanest soluton is the one suggested up top: Specify-DBUILD_UNITTESTS=ON
during build generation and use that flag.suppress Catch2 warningto WIP: suppress Catch2 warningWIP: suppress Catch2 warningto Catch2 hotfix