From: Andre Noll Date: Tue, 20 Aug 2019 07:10:53 +0000 (+0200) Subject: Avoid warning about sys/sysctl.h on glibc-2.30. X-Git-Tag: v0.5.9~1 X-Git-Url: http://git.tuebingen.mpg.de/?a=commitdiff_plain;h=f012a742a9b342c51e3c6bef22eaab0f39cb9e46;hp=f012a742a9b342c51e3c6bef22eaab0f39cb9e46;p=paraslash.git Avoid warning about sys/sysctl.h on glibc-2.30. From glibc-2.30 NEWS: The Linux-specific header and the sysctl function have been deprecated and will be removed from a future version of glibc. Compilation against the glibc-2.30 headers results in the following warning: In file included from ipc.c:10: /usr/include/sys/sysctl.h:21:2: warning: #warning "The header is deprecated and will be removed." [-Wcpp] On NetBSD and FreeBSD, however, we still need to include the header to get the declaration of sysctlbyname(3). This patch changes ipc.c to include sys/sysctl.h only if __FreeBSD__ or __NetBSD__ is defined. Also remove the pointless check for __APPLE__. ---