Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update sonic-swss-common for compilation on Bookworm #825

Merged
merged 5 commits into from
Nov 7, 2023

Conversation

saiarcot895
Copy link
Contributor

This PR includes the following two changes:

  • Use json.hpp form the nlohmann-json-dev package instead of having a local copy. This is because this version as-is now has compilation errors on Bookworm, and this file is coming from an external source.
  • Fix compilation errors with GCC 12, related to reference-vs-copy errors in for-loops and casting issues.

@@ -400,14 +400,14 @@ EventSubscriber::prune_track()
map<time_t, vector<runtime_id_t> > lst;

/* Sort entries by last touched time */
for(const auto e: m_track) {
for(const auto &e: m_track) {
Copy link
Contributor

Choose a reason for hiding this comment

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

const

@zbud-msft Could you help review events related code?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@zbud-msft Reminder for this

Copy link
Contributor

Choose a reason for hiding this comment

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

LGTM

This header file comes from an external package, and a very old version of the
header file has been checked into this repo. This will cause problems for the
upcoming Bookworm upgrade.

Change references to the header file to use the Debian package
nlohmann-json-dev, and remove json.hpp from this repo.

Signed-off-by: Saikrishna Arcot <[email protected]>
Signed-off-by: Saikrishna Arcot <[email protected]>
Signed-off-by: Saikrishna Arcot <[email protected]>
@prsunny prsunny merged commit 0cbceed into sonic-net:master Nov 7, 2023
13 of 14 checks passed
@saiarcot895 saiarcot895 deleted the bookworm-changes branch November 15, 2023 22:12
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.

4 participants