Re: Failed install - libgen.so doesn't exist

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
Cc: flyvholm(at)fys(dot)ku(dot)dk, pgsql-ports(at)postgresql(dot)org
Subject: Re: Failed install - libgen.so doesn't exist
Date: 2006-02-01 16:29:11
Message-ID: 1208.1138811351@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers pgsql-ports

Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us> writes:
> Tom Lane wrote:
>> I'm just wondering how many of those AC_CHECK_LIB calls are needed only
>> on platforms that no one uses anymore ...

> I didn't want to mention that, but one big problem we have is that we
> have no way to know what platforms are still using which configure and
> pgport functions. It is very possible that 25% of what we have isn't
> needed anymore, but we have no way of knowing which part.

Agreed, but pgport functions that aren't actually selected for use don't
pose any hazards. AC_CHECK_LIB is an ongoing hazard for exactly the
reason the OP presents, namely that it will suck in any random library
it can find that happens to match by name. It's especially bad that
almost all of the tests are coded like
AC_CHECK_LIB(gen, main)
which means they don't even try to determine whether the library
is actually the one intended.

Now that we have the buildfarm I think that experimentation with this
sort of thing is a lot less risky than it used to be. I think we should
be working towards a project policy that AC_CHECK_LIB calls shalt not
use "main", but must name some symbol exported by the expected library.
If we can't find out what symbols the library is expected to provide,
it's time to dike it out.

regards, tom lane

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Bruce Momjian 2006-02-01 16:31:04 Re: Failed install - libgen.so doesn't exist
Previous Message Tom Lane 2006-02-01 16:14:44 Re: Cleaning up the INET/CIDR mess

Browse pgsql-ports by date

  From Date Subject
Next Message Bruce Momjian 2006-02-01 16:31:04 Re: Failed install - libgen.so doesn't exist
Previous Message Bruce Momjian 2006-02-01 16:13:09 Re: Failed install - libgen.so doesn't exist