libmicrohttpd
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [libmicrohttpd] MHD_start_daemon returns NULL


From: Roel Janssen
Subject: Re: [libmicrohttpd] MHD_start_daemon returns NULL
Date: Fri, 23 Dec 2022 23:12:52 +0100
User-agent: Evolution 3.46.2 (3.46.2-1.fc37)

Hi Evgeny,

Thank you very much for your quick and helpful reply!
Actually, I don't have the .config file because I'm working on a .. restricted 
device..

Also, I've cross-compiled the library for use on that target device, so I don't 
know how one would
be able to check this at configure-time.  The --enable-itc=pipe parameter is 
exactly what I needed,
so perhaps we could document this better?  This mailing list thread is already 
helpful I believe.
It could also be my lack of knowledge on this matter that I had overlooked this 
option.

Thank you!

Kind regards,
Roel Janssen


On Fri, 2022-12-23 at 11:05 +0300, Evgeny Grin wrote:
> Hi Roel,
> 
> Looks like your Linux kernel was compiled without eventfd support. Can 
> you check your '.config' for 'CONFIG_EVENTFD'?
> 
> The easiest way to build working MHD in such case is use 
> '--enable-itc=pipe' configure parameter. It will prevent usage of 
> eventfd functions even if eventfd support is detected in headers and libc.
> 
> Thanks for your nice report, I'll add more checks in configure to check 
> for the real eventfd availability.
> 
> -- 
> Evgeny
> 
> 
> On 22.12.2022 20:38, Roel Janssen wrote:
> > Dear list,
> > 
> > I'm trying to create an HTTP server for an ARMv7 device.
> > But MHD_start_daemon returns NULL, and I don't know how to go from there.
> > 
> > The device uses kernel:
> > # uname -a
> > Linux buildroot 4.0.0-ADI-1.3.0 #1 PREEMPT Thu Sep 15 16:03:17 UTC 2022 
> > armv7l GNU/Linux
> > 
> > And libc:
> > # /lib/libc-2.18.so
> > GNU C Library (GNU libc) stable release version 2.18, by Roland McGrath et 
> > al.
> > Copyright (C) 2013 Free Software Foundation, Inc.
> > This is free software; see the source for copying conditions.
> > There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A
> > PARTICULAR PURPOSE.
> > Compiled by GNU CC version 4.8.3.
> > Compiled on a Linux 4.0.0 system on 2018-04-28.
> > Available extensions:
> >          crypt add-on version 2.1 by Michael Glad and others
> >          GNU Libidn by Simon Josefsson
> >          Native POSIX Threads Library by Ulrich Drepper et al
> >          BIND-8.2.3-T5B
> > libc ABIs: UNIQUE
> > For bug reporting instructions, please see:
> > <http://www.gnu.org/software/libc/bugs.html>.
> > 
> > 
> > I cross-compiled libmicrohttpd-0.9.75 with --enable-messages, and call 
> > MHD_start_daemon as
> > following:
> > daemon = MHD_start_daemon (MHD_USE_INTERNAL_POLLING_THREAD | 
> > MHD_USE_ERROR_LOG,
> >                             PORT, NULL, NULL, &respond, NULL, 
> > MHD_OPTION_END);
> > 
> > Unfortunately, MHD_start_daemon returns NULL. Here's the output snippet of 
> > strace:
> > 
> > write(1, "Starting HTTP server.\n", 22) = 22
> > brk(NULL)                               = 0x5a000
> > brk(0x7b000)                            = 0x7b000
> > eventfd2(0, EFD_CLOEXEC|EFD_NONBLOCK)   = -1 ENOSYS (Function not 
> > implemented)
> > write(2, "Failed to create inter-thread co"..., 78) = 78
> > 
> > What's going on?  And what can I do?
> > 
> > Kind regards,
> > Roel Janssen
> > 
> > 




reply via email to

[Prev in Thread] Current Thread [Next in Thread]