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

Ocp wo json #2503

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open

Ocp wo json #2503

wants to merge 3 commits into from

Conversation

ikegami-t
Copy link
Contributor

No description provided.

@igaw
Copy link
Collaborator

igaw commented Sep 18, 2024

I was wondering if we should move the json code into a separate files and only include them when the json library is available, like we have with nvme-print-stdout.c and nvme-print-json.c.

@ikegami-t
Copy link
Contributor Author

Okay will try to do it. Thank you.

At first only hwcomp print code moved.

Signed-off-by: Tokunori Ikegami <[email protected]>
@@ -6,5 +6,9 @@ sources += [
'plugins/ocp/ocp-fw-activation-history.c',
'plugins/ocp/ocp-telemetry-decode.c',
'plugins/ocp/ocp-hardware-component-log.c',
'plugins/ocp/ocp-print.c',
'plugins/ocp/ocp-print-stdout.c',
'plugins/ocp/ocp-print-json.c',
Copy link
Collaborator

Choose a reason for hiding this comment

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

The json file should only be added when the json library is available. And then you could update the plugins/meson.build file to always build the ocp plugin.

The rest looks good!

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Update the meson.build files by the additional commit. Thank you.
Note: Still some exisitng ocp commands files needed to split json code.

Still ocp-nvme.c and some other ocp commands files depended on json.

Signed-off-by: Tokunori Ikegami <[email protected]>
Moved into print stdout and json files.

Signed-off-by: Tokunori Ikegami <[email protected]>
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.

2 participants