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

Mark sysfs as Linux-only #365

Merged
merged 2 commits into from
Mar 13, 2021

Conversation

rfratto
Copy link
Contributor

@rfratto rfratto commented Feb 26, 2021

The sysfs package is imported by node_exporter. class_thermal uses ENODATA, which doesn't exist on FreeBSD, so the build fails.

Since sysfs is a Linux concept, this PR marks most of the functions within the package as Linux-only. Closes #359.

Signed-off-by: Robert Fratto <robertfratto@gmail.com>
@SuperQ
Copy link
Member

SuperQ commented Feb 26, 2021

Maybe we should mark everything under /sysfs as Linux-only?

Signed-off-by: Robert Fratto <robertfratto@gmail.com>
@rfratto rfratto changed the title Exclude freebsd from class_thermal Mark sysfs as Linux-only Feb 26, 2021
@rfratto
Copy link
Contributor Author

rfratto commented Feb 26, 2021

Maybe we should mark everything under /sysfs as Linux-only?

Yep, agreed. Changed the PR to do this. Thanks!

Copy link
Member

@discordianfish discordianfish left a comment

Choose a reason for hiding this comment

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

LGTM

@rfratto
Copy link
Contributor Author

rfratto commented Mar 13, 2021

Do we need a second pair of eyes to get this merged?

Copy link
Member

@SuperQ SuperQ left a comment

Choose a reason for hiding this comment

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

LGTM

@SuperQ
Copy link
Member

SuperQ commented Mar 13, 2021

Sorry, fell out of my TODO list.

@SuperQ SuperQ merged commit b565fef into prometheus:master Mar 13, 2021
remijouannet pushed a commit to remijouannet/procfs that referenced this pull request Oct 20, 2022
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.

FreeBSD build error: undefined: syscall.ENODATA
3 participants