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

Deprecated <sys/sysctl.h> on Linux; harmless #279

Closed
gperciva opened this issue Oct 8, 2020 · 0 comments
Closed

Deprecated <sys/sysctl.h> on Linux; harmless #279

gperciva opened this issue Oct 8, 2020 · 0 comments

Comments

@gperciva
Copy link
Member

gperciva commented Oct 8, 2020

Linux and glibc marked <sys/sysctrl.h> as deprecated, so we've been treated to warnings like:

/usr/include/aarch64-linux-gnu/sys/sysctl.h:21:2: warning: #warning "The <sys/sysctl.h> header is deprecated and will be removed." [-Wcpp]
   21 | #warning "The <sys/sysctl.h> header is deprecated and will be removed."
      |  ^~~~~~~

This is completely harmless for scrypt, as memlimit.c checks multiple methods of getting the available memory, and uses the lowest one. If autoconf's AC_CHECK_HEADER could take an extra parameter saying "only mark this header as avilable if it compiles without any warnings", I'd gladly enable that, but unfortunately there's no such option [1].

Incidently, the sysctl() function was removed in glibc 2.32 (2020-08-06). The binary symbol is still present, but will always return ENOSYS [2].

[1] https://www.gnu.org/software/autoconf/manual/autoconf-2.61/html_node/Generic-Headers.html
[2] https://sourceware.org/pipermail/libc-announce/2020/000029.html

I'm going to close this issue immediately; it's just here in case somebody wonders about these warnings and searches the github issues.

@gperciva gperciva closed this as completed Oct 8, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

1 participant