Skip to content

Conversation

@songmeo
Copy link
Contributor

@songmeo songmeo commented Jul 21, 2025

closes #245

@songmeo songmeo force-pushed the 245-switch-to-cavl2 branch from 65af23f to 8625b28 Compare July 21, 2025 19:12
@songmeo songmeo force-pushed the 245-switch-to-cavl2 branch from aa59dda to 098a550 Compare July 22, 2025 11:46
@songmeo songmeo force-pushed the 245-switch-to-cavl2 branch from 4e2a001 to ac4f382 Compare July 22, 2025 21:38
@songmeo songmeo force-pushed the 245-switch-to-cavl2 branch from 0a28819 to 41ec76d Compare July 23, 2025 17:27
@songmeo songmeo force-pushed the 245-switch-to-cavl2 branch from 95b8d92 to 26f8f86 Compare July 24, 2025 22:23
@songmeo songmeo force-pushed the 245-switch-to-cavl2 branch 3 times, most recently from 9e82af1 to ecfd769 Compare July 30, 2025 12:10
@songmeo songmeo force-pushed the 245-switch-to-cavl2 branch from ecfd769 to 482c9b0 Compare July 30, 2025 12:16
@songmeo songmeo marked this pull request as ready for review August 7, 2025 14:07
@songmeo songmeo requested a review from pavel-kirienko August 7, 2025 14:08
Copy link
Member

@pavel-kirienko pavel-kirienko left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What #245 was trying to say is that cavl2 should no longer be vendored as part of libcanard itself, but rather it has to be provided by the user. One practical implication is that we need to remove it from the libcanard directory, and place it instead somewhere under lib/cavl2/cavl2.h (should it be a git submodule? probably not), which will then be added as a system include directory. Using a blanket -system for the entire libcanard directory is harmful because it will squelch bona fide warnings from the compiler concerning libcanard's own header.

Direct compiler invocations in the CI script will need to be updated accordingly.

@pavel-kirienko
Copy link
Member

Also, see if you can use CAVL2_TO_OWNER instead of the mutable container macros

@songmeo songmeo requested a review from pavel-kirienko August 8, 2025 19:56
Copy link
Member

@pavel-kirienko pavel-kirienko left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This Sonar report is legit, we could address it in this changeset as well since it's minor:

Image

The other one requires a // NOSONAR comment.

@songmeo songmeo force-pushed the 245-switch-to-cavl2 branch 2 times, most recently from 1234c96 to 801b2d8 Compare August 10, 2025 18:28
@songmeo songmeo force-pushed the 245-switch-to-cavl2 branch from 801b2d8 to e7154c7 Compare August 10, 2025 18:31
@songmeo songmeo requested a review from pavel-kirienko August 10, 2025 18:41
pavel-kirienko
pavel-kirienko previously approved these changes Aug 10, 2025
Copy link
Member

@pavel-kirienko pavel-kirienko left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please address the remaining minor issues and then merge.

include_directories(${library_dir})
include_directories(SYSTEM catch)
include_directories(SYSTEM ${CMAKE_SOURCE_DIR}/../lib/cavl2)
include_directories(${CMAKE_SOURCE_DIR}/../libcanard)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Redundant; we already have include_directories(${library_dir}) on line 71

@pavel-kirienko pavel-kirienko enabled auto-merge (squash) August 10, 2025 19:55
@sonarqubecloud
Copy link

@pavel-kirienko pavel-kirienko merged commit 0fd1d3a into master Aug 10, 2025
17 checks passed
@pavel-kirienko pavel-kirienko deleted the 245-switch-to-cavl2 branch August 10, 2025 20:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Switch to cavl2 as an external dependency and remove vendored cavl

3 participants