[ovs-dev] [PATCH] use AX_PTHREAD to detect pthreads

Kevin Lo kevlo at FreeBSD.org
Tue Apr 21 01:42:16 UTC 2015


On Fri, Apr 17, 2015 at 08:02:28AM -0700, Gurucharan Shetty wrote:
> 
> >
> > I know some of you are concerned about it will break build on Windows.
> > The diff below fixes pthread linking on FreeBSD.
> > Tested on Linux, NetBSD, and FreeBSD.
> You can also check whether it builds successfully on Windows by adding
> your proposed commit to your fork of OVS in Github and then logging
> into appveyor.com via your github account. You can then start a new
> build there
> 
> If you prefer that I take care of Windows, let me know.

Hi Guru,

Thanks for letting me know that I could use Appveyor ci service to build
Windows-target binary wheels.  I didn't know that since I haven't had
any Windows boxes for years.  The good news is we've already had a
soultion to fix pthread linking issue. :-)

> > If it looks good, I'll update the commit message, thanks.
> >
> > diff --git a/acinclude.m4 b/acinclude.m4
> > index b09f2f2..c5214dc 100644
> > --- a/acinclude.m4
> > +++ b/acinclude.m4
> > @@ -710,6 +710,7 @@ dnl    glibc: HAVE_GLIBC_PTHREAD_SETNAME_NP
> >  dnl    NetBSD: HAVE_NETBSD_PTHREAD_SETNAME_NP
> >  dnl    FreeBSD: HAVE_PTHREAD_SET_NAME_NP
> >  AC_DEFUN([OVS_CHECK_PTHREAD_SET_NAME],
> > +  [AC_CHECK_LIB(pthread, pthread_create)]
> >    [AC_CHECK_FUNCS([pthread_set_name_np])
> >     if test $ac_cv_func_pthread_set_name_np != yes; then
> >       AC_CACHE_CHECK(
> > diff --git a/configure.ac b/configure.ac
> > index d1b48ca..9d1dbf3 100644
> > --- a/configure.ac
> > +++ b/configure.ac
> > @@ -81,7 +81,6 @@ AC_SUBST([LT_AGE])
> >  AC_SEARCH_LIBS([pow], [m])
> >  AC_SEARCH_LIBS([clock_gettime], [rt])
> >  AC_SEARCH_LIBS([timer_create], [rt])
> > -AC_SEARCH_LIBS([pthread_sigmask], [pthread])
> >  AC_FUNC_STRERROR_R
> >
> >  OVS_CHECK_ESX
> 



More information about the dev mailing list