[PATCH] linux: add check for sysctl sycall presence
Samuel Martin
s.martin49 at gmail.com
Mon Nov 24 22:20:24 UTC 2014
Hello,
On Mon, Nov 24, 2014 at 2:07 PM, Maxim Dounin <mdounin at mdounin.ru> wrote:
> Hello!
>
> On Sun, Nov 23, 2014 at 06:07:00PM +0100, Samuel Martin wrote:
>
>> # HG changeset patch
>> # User "Samuel Martin" <s.martin49 at gmail.com>
>> # Date 1416759425 -3600
>> # Sun Nov 23 17:17:05 2014 +0100
>> # Node ID 3a010d195a5a4249da5552c5de7643f898c9e507
>> # Parent 1be88123e98c8b0e78602eeb3a8c3eb3444c15f3
>> linux: add check for sysctl sycall presence
>>
>> And also disable call to the sysctl function when the sysctl syscall
>> is disabled in the kernel configuration.
>>
Actually sysctl syscall is deprecated and some new architectures
choose to not support deprecated stuff. So, it may be the first
architecture not supporting this syscall, but not the last one...
The tricky thing is that you cannot know if the target provided this
syscall or not before trying to link some code using the sysctl
function.
>> This fixes:
>> http://autobuild.buildroot.org/results/730/730105fc0a89b381b3b29192d07f28ef1f13cbb3/build-end.log
>
> Just avoid --with-rtsig-module on such hosts instead.
You mean not setting it on the configure command line or conditionally
setting NGX_EVENT_RTSIG wrt the sysctl check result?
It is not really convenient to have a build failing during the
compile/link step, whereas the check can be done during the
configuration, and just automatically disable the unsupported feature
(silently or with some warning) or loudly bail out.
>
> --
> Maxim Dounin
> http://nginx.org/
>
> _______________________________________________
> nginx-devel mailing list
> nginx-devel at nginx.org
> http://mailman.nginx.org/mailman/listinfo/nginx-devel
Regards,
--
Samuel
More information about the nginx-devel
mailing list