1 # Copyright 1999-2018 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
6 inherit autotools eutils multilib
10 DESCRIPTION="Name Service Switch module for use with PostgreSQL"
11 HOMEPAGE="http://pgfoundry.org/projects/sysauth/"
12 SRC_URI="http://pgfoundry.org/frs/download.php/605/${P}.tgz"
17 DEPEND="dev-db/postgresql
24 epatch "${FILESDIR}/${P}-gentoo.patch"
25 epatch "${FILESDIR}/${P}-schema.patch"
32 --with-docdir=/usr/share/doc/${PF}/html || die "econf failed"
33 emake || die "emake failed"
37 insinto /$(get_libdir)
38 doins src/.libs/libnss_pgsql.so.2.0.0
39 dosym libnss_pgsql.so.2.0.0 /lib/libnss_pgsql.so.2
40 dosym libnss_pgsql.so.2.0.0 /lib/libnss_pgsql.so
42 dodoc AUTHORS ChangeLog NEWS README
43 dohtml doc/*.{png,html}
44 insinto /usr/share/doc/${PF}/examples
50 elog "1. Create the required tables in the database:"
51 elog " $ psql a_database -f ${ROOT}usr/share/${PN}/conf/dbschema.sql"
52 elog "2. Create the configuration file '/etc/nss-pgsql.conf'"
53 elog " You can copy the example from ${ROOT}usr/share/doc/${PF}/examples/nss-pgsql.conf"
54 elog "3. Edit /etc/nsswitch.conf to use the NSS service 'pgsql'"
55 elog " An example is available here: ${ROOT}usr/share/doc/${PF}/examples/nsswitch.conf"