Re: [HACKERS] UnixWare/CVS Tip/initdb.c needs to use threads

Поиск
Список
Период
Сортировка
От Bruce Momjian
Тема Re: [HACKERS] UnixWare/CVS Tip/initdb.c needs to use threads
Дата
Msg-id 200403220559.i2M5xPT25270@candle.pha.pa.us
обсуждение исходный текст
Ответ на Re: [HACKERS] UnixWare/CVS Tip/initdb.c needs to use threads  (Larry Rosenman <ler@lerctr.org>)
Список pgsql-patches
Larry Rosenman wrote:
-- Start of PGP signed section.
> [moved to -patches because of the patch]
>
>
> --On Friday, March 19, 2004 08:01:53 -0500 Bruce Momjian
> <pgman@candle.pha.pa.us> wrote:
>
> > Larry Rosenman wrote:
> >> > I thought that once you include libpthread in libpq, that you don't
> >> > have to mention it again then you use libpq.  Is your platform
> >> > different somehow in this regard?
> >> >
> >> > I seem to remember this problem with libcrypt and libpq.  Is this the
> >> > same problem?
> >> >
> >> > I see that initdb is just the first of many /bin programs to be
> >> > compiled, so if we have to add the thread lib, we will have to do it
> >> > for all the bin programs.  Yikes.  Why wasn't this a problem for 7.4?
> >> 7.4 had initdb as a Shell Script.
> >> the 7.4.x libpq didn't have any pthread_* references in it, that I see
> >> on my box.
> >
> > Ah, yes.  We added the thread-local storage to handle SIGPIPE.  The
> > problem is that initdb isn't the only place.  If you comment out initdb
> > from the Makefile in src/bin, does the next make fail too?  I bet it
> > does.
>
> Apparently, because of the way the wrappers work, having -lpthread on
> libpq.so does NOT add it to the NEEDED list.

Clarification.  The flags are "-pthread" or "-K pthread", not -lpthread,
which is clearly a linker flag.

--
  Bruce Momjian                        |  http://candle.pha.pa.us
  pgman@candle.pha.pa.us               |  (610) 359-1001
  +  If your life is a hard drive,     |  13 Roberts Road
  +  Christ can be your backup.        |  Newtown Square, Pennsylvania 19073

В списке pgsql-patches по дате отправления:

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: pstrndup()
Следующее
От: Manfred Spraul
Дата:
Сообщение: Re: [HACKERS] libpq thread safety