[Lldb-commits] [lldb] r313437 - Check availability of accept4 in C++ instad of C code.
Author: eugene Date: Fri Sep 15 19:58:49 2017 New Revision: 313437 URL: http://llvm.org/viewvc/llvm-project?rev=313437&view=rev Log: Check availability of accept4 in C++ instad of C code. Modified: lldb/trunk/cmake/modules/LLDBGenerateConfig.cmake Modified: lldb/trunk/cmake/modules/LLDBGenerateConfig.cmake URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/cmake/modules/LLDBGenerateConfig.cmake?rev=313437&r1=313436&r2=313437&view=diff == --- lldb/trunk/cmake/modules/LLDBGenerateConfig.cmake (original) +++ lldb/trunk/cmake/modules/LLDBGenerateConfig.cmake Fri Sep 15 19:58:49 2017 @@ -9,7 +9,7 @@ set(CMAKE_REQUIRED_DEFINITIONS -D_GNU_SO check_symbol_exists(ppoll poll.h HAVE_PPOLL) set(CMAKE_REQUIRED_DEFINITIONS) check_symbol_exists(sigaction signal.h HAVE_SIGACTION) -check_symbol_exists(accept4 "sys/socket.h" HAVE_ACCEPT4) +check_cxx_symbol_exists(accept4 "sys/socket.h" HAVE_ACCEPT4) check_include_file(termios.h HAVE_TERMIOS_H) check_include_files("sys/types.h;sys/event.h" HAVE_SYS_EVENT_H) ___ lldb-commits mailing list lldb-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
Re: [Lldb-commits] [lldb] r313437 - Check availability of accept4 in C++ instad of C code.
What difference does this make? On Fri, Sep 15, 2017 at 8:00 PM Eugene Zemtsov via lldb-commits < lldb-commits@lists.llvm.org> wrote: > Author: eugene > Date: Fri Sep 15 19:58:49 2017 > New Revision: 313437 > > URL: http://llvm.org/viewvc/llvm-project?rev=313437&view=rev > Log: > Check availability of accept4 in C++ instad of C code. > > Modified: > lldb/trunk/cmake/modules/LLDBGenerateConfig.cmake > > Modified: lldb/trunk/cmake/modules/LLDBGenerateConfig.cmake > URL: > http://llvm.org/viewvc/llvm-project/lldb/trunk/cmake/modules/LLDBGenerateConfig.cmake?rev=313437&r1=313436&r2=313437&view=diff > > == > --- lldb/trunk/cmake/modules/LLDBGenerateConfig.cmake (original) > +++ lldb/trunk/cmake/modules/LLDBGenerateConfig.cmake Fri Sep 15 19:58:49 > 2017 > @@ -9,7 +9,7 @@ set(CMAKE_REQUIRED_DEFINITIONS -D_GNU_SO > check_symbol_exists(ppoll poll.h HAVE_PPOLL) > set(CMAKE_REQUIRED_DEFINITIONS) > check_symbol_exists(sigaction signal.h HAVE_SIGACTION) > -check_symbol_exists(accept4 "sys/socket.h" HAVE_ACCEPT4) > +check_cxx_symbol_exists(accept4 "sys/socket.h" HAVE_ACCEPT4) > > check_include_file(termios.h HAVE_TERMIOS_H) > check_include_files("sys/types.h;sys/event.h" HAVE_SYS_EVENT_H) > > > ___ > lldb-commits mailing list > lldb-commits@lists.llvm.org > http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits > -- -- Stephane Sezer ___ lldb-commits mailing list lldb-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
Re: [Lldb-commits] [lldb] r313437 - Check availability of accept4 in C++ instad of C code.
In GNU C Library, accept4 is guarded by __USE_GNU macro. Whether this macro is defined or not can depend on the compiler and its arguments for C and C++. LLDB uses accept4 in C++ code thus it makes sense to test availability of this function in C++ mode. On Mon, Sep 18, 2017 at 9:58 AM, Stephane Sezer wrote: > What difference does this make? > > On Fri, Sep 15, 2017 at 8:00 PM Eugene Zemtsov via lldb-commits < > lldb-commits@lists.llvm.org> wrote: > >> Author: eugene >> Date: Fri Sep 15 19:58:49 2017 >> New Revision: 313437 >> >> URL: http://llvm.org/viewvc/llvm-project?rev=313437&view=rev >> Log: >> Check availability of accept4 in C++ instad of C code. >> >> Modified: >> lldb/trunk/cmake/modules/LLDBGenerateConfig.cmake >> >> Modified: lldb/trunk/cmake/modules/LLDBGenerateConfig.cmake >> URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/cmake/ >> modules/LLDBGenerateConfig.cmake?rev=313437&r1=313436&r2=313437&view=diff >> >> == >> --- lldb/trunk/cmake/modules/LLDBGenerateConfig.cmake (original) >> +++ lldb/trunk/cmake/modules/LLDBGenerateConfig.cmake Fri Sep 15 >> 19:58:49 2017 >> @@ -9,7 +9,7 @@ set(CMAKE_REQUIRED_DEFINITIONS -D_GNU_SO >> check_symbol_exists(ppoll poll.h HAVE_PPOLL) >> set(CMAKE_REQUIRED_DEFINITIONS) >> check_symbol_exists(sigaction signal.h HAVE_SIGACTION) >> -check_symbol_exists(accept4 "sys/socket.h" HAVE_ACCEPT4) >> +check_cxx_symbol_exists(accept4 "sys/socket.h" HAVE_ACCEPT4) >> >> check_include_file(termios.h HAVE_TERMIOS_H) >> check_include_files("sys/types.h;sys/event.h" HAVE_SYS_EVENT_H) >> >> >> ___ >> lldb-commits mailing list >> lldb-commits@lists.llvm.org >> http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits >> > -- > -- > Stephane Sezer > -- Thanks, Eugene Zemtsov. ___ lldb-commits mailing list lldb-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits