Re: [v9.1] sepgsql - userspace access vector cache - Mailing list pgsql-hackers

From Robert Haas
Subject Re: [v9.1] sepgsql - userspace access vector cache
Date
Msg-id CA+TgmoY=5L494EFowS2QQ313HP8mwKZV4Hy-P2A2b2CDdxnJ8g@mail.gmail.com
Whole thread Raw
In response to Re: [v9.1] sepgsql - userspace access vector cache  (Kohei Kaigai <Kohei.Kaigai@EMEA.NEC.COM>)
Responses Re: [v9.1] sepgsql - userspace access vector cache
List pgsql-hackers
On Thu, Aug 18, 2011 at 1:17 PM, Kohei Kaigai <Kohei.Kaigai@emea.nec.com> wrote:
>> That's lame.  I think we need to patch contrib/sepgsql so that it
>> fails to build in that case, rather than building and then not
>> working.
>>
> It might be the following fix, but I have no idea to generate an error when $(with_selinux) != "yes" on makefile.

Actually, as I look at this more, I think this build system is
completely mis-designed.  Given that you want to build sepgsql,
selinux is not an optional feature.  So the stuff in
contrib/sepgsql/Makefile that is intended to link against libselinux
only if --with-selinux was specified at configure time is nonsense.
We should just ALWAYS try to link against libselinux, and if it's not
there, then at least it'll fail right away at compile time instead of
appearing to compile OK but producing an so that then fails to load at
runtime.

The only actual legitimate purpose of --with-selinux is to allow
contrib/Makefile to decide whether, when someone tries to build "all
the contrib modules", we should try to build sepgsql too.

--
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company


pgsql-hackers by date:

Previous
From: Kohei Kaigai
Date:
Subject: Re: [v9.1] sepgsql - userspace access vector cache
Next
From: Euler Taveira de Oliveira
Date:
Subject: Re: Displaying accumulated autovacuum cost