--- /dev/null
+# Copyright 1999-2011 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/net-nds/389-admin/389-admin-1.1.23.ebuild,v 1.1 2011/08/14 09:23:45 lxnay Exp $
+
+EAPI="2"
+
+WANT_AUTOMAKE="1.9"
+
+MY_PV=${PV/_rc/.rc}
+MY_PV=${MY_PV/_a/.a}
+
+inherit eutils multilib autotools depend.apache
+
+DESCRIPTION="389 Directory Server (admin)"
+HOMEPAGE="http://port389.org/"
+SRC_URI="http://directory.fedoraproject.org/sources/${PN}-${MY_PV}.tar.bz2"
+
+LICENSE="GPL-2 Apache-2.0"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE="debug ipv6 selinux"
+
+# TODO snmp agent init script
+
+COMMON_DEPEND=">=app-admin/389-admin-console-1.1.0
+ >=app-admin/389-ds-console-1.1.0
+ app-misc/mime-types
+ dev-libs/389-adminutil
+ dev-libs/cyrus-sasl
+ dev-libs/icu
+ dev-libs/mozldap
+ dev-libs/nss[utils]
+ || ( <=dev-libs/nspr-4.8.3-r3[ipv6?] >=dev-libs/nspr-4.8.4 )
+ dev-libs/svrcore
+ net-analyzer/net-snmp[ipv6?]
+ selinux? (
+ sys-apps/checkpolicy
+ sys-apps/policycoreutils
+ sec-policy/selinux-base-policy
+ )
+ >=sys-libs/db-4.2.52
+ sys-libs/pam
+ sys-apps/tcp-wrappers[ipv6?]
+ www-apache/mod_nss
+ www-servers/apache:2[apache2_modules_actions,apache2_modules_alias,apache2_modules_auth_basic,apache2_modules_authz_default,apache2_modules_cgi,apache2_modules_mime_magic,apache2_modules_rewrite,apache2_modules_setenvif,suexec,threads]"
+RDEPEND="${COMMON_DEPEND} www-client/lynx"
+DEPEND="sys-apps/sed ${COMMON_DEPEND}"
+
+S="${WORKDIR}/${PN}-${MY_PV}"
+
+need_apache2_2
+
+src_prepare() {
+ # as per 389 documentation, when 64bit, export USE_64
+ use amd64 && export USE_64=1
+
+ epatch "${FILESDIR}/1.1.11_rc1/0001-gentoo-apache-names.patch"
+ epatch "${FILESDIR}/1.1.11_rc1/0003-find-mod_nss.m4.patch"
+ epatch "${FILESDIR}/1.1.11_rc1/0004-rpath-fix.configure.ac.patch"
+ # Configuration fixes
+ epatch "${FILESDIR}/${PN}-cfgstuff-1.patch"
+
+ sed -e "s!SUBDIRS!# SUBDIRS!g" -i Makefile.am || die "sed failed"
+ # Setup default user/group, in this case it's dirsrv
+ sed -e "s!nobody!dirsrv!g" -i configure.ac || die "sed failed"
+
+ eautoreconf
+}
+
+src_configure() {
+ # stub autoconf triplet :(
+ local myconf=""
+ use debug && myconf="--enable-debug"
+ use selinux && myconf="${myconf} --with-selinux"
+
+ econf \
+ --enable-threading \
+ --disable-rpath \
+ --with-fhs \
+ --with-apr-config \
+ --with-apxs=${APXS} \
+ --with-httpd=${APACHE_BIN} \
+ ${myconf} || die "econf failed"
+}
+
+src_install () {
+
+ emake DESTDIR="${D}" install || die "emake failed"
+ keepdir /var/log/dirsrv/admin-serv
+
+ # remove redhat style init script.
+ rm -rf "${D}"/etc/rc.d
+ rm -rf "${D}"/etc/default
+
+ # install gentoo style init script.
+ newinitd "${FILESDIR}"/${PN}.initd ${PN}
+ newconfd "${FILESDIR}"/${PN}.confd ${PN}
+
+ # remove redhat style wrapper scripts
+ # and install gentoo scripts.
+ rm -rf "${D}"/usr/sbin/*-ds-admin
+ dosbin "${FILESDIR}"/*-ds-admin || die "cannot install gentoo start/stop scripts"
+
+ # In this version build systems for modules is delete :(
+ # manually install modules, not using apache-modules eclass
+ # because use bindled library
+
+ # install mod_admserv
+ exeinto "${APACHE_MODULESDIR}"
+ doexe "${S}/.libs"/mod_admserv.so || die "internal ebuild error: mod_admserv not found"
+
+ insinto "${APACHE_MODULES_CONFDIR}"
+ newins "${FILESDIR}/1.1.11_rc1"/48_mod_admserv.conf 48_mod_admserv \
+ || die "internal ebuild error: 48_mod_admserv.conf not found"
+
+ # install mod_restard
+ exeinto "${APACHE_MODULESDIR}"
+ doexe "${S}/.libs"/mod_restartd.so || die "internal ebuild error: mod_restartd not found"
+
+ insinto "${APACHE_MODULES_CONFDIR}"
+ newins "${FILESDIR}/1.1.11_rc1"/48_mod_restartd.conf 48_mod_restartd \
+ || die "internal ebuild error: 48_mod_restard.conf not found"
+
+ if use selinux; then
+ local POLICY_TYPES="targeted"
+ cd "${S}"/selinux-build
+ cp /usr/share/selinux/${POLICY_TYPES}/include/Makefile .
+ make || die "selinux policy compile failed"
+ insinto /usr/share/selinux/${POLICY_TYPES}
+ doins -r "${S}/selinux-build/"*.pp
+ fi
+
+}
+
+pkg_postinst() {
+
+ # show setup information
+ elog "Once you configured www-servers/apache as written above,"
+ elog "you need to run (as root): /usr/sbin/setup-ds-admin.pl"
+ elog
+
+ # show security and sysctl info
+ elog "It is recommended to setup net.ipv4.tcp_keep_alive_time"
+ elog "in /etc/sysctl.conf (or via sysctl -w && sysctl -p) to a reasonable"
+ elog "value (in milliseconds) to avoid temporary server congestions"
+ elog "from lost client connections"
+ elog
+
+ # /etc/security/limits.conf settings
+ elog "It is also recommended to fine tune the maximum open files"
+ elog "settings inside /etc/security/limits.conf:"
+ elog "* soft nofile 2048"
+ elog "* hard nofile 4096"
+ elog
+
+ elog "To start 389 Directory Server Administration Interface at boot"
+ elog "please add 389-admin service to the default runlevel:"
+ elog
+ elog " rc-update add 389-admin default"
+ elog
+
+ elog "for 389 Directory Server Admin interface to work, you need"
+ elog "to setup a FQDN hostname and use it while running /usr/sbin/setup-ds-admin.pl"
+ elog
+
+}
# ChangeLog for net-nds/389-admin
# Copyright 1999-2011 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/net-nds/389-admin/ChangeLog,v 1.7 2011/06/14 19:14:10 lxnay Exp $
+# $Header: /var/cvsroot/gentoo-x86/net-nds/389-admin/ChangeLog,v 1.8 2011/08/14 09:23:45 lxnay Exp $
+
+*389-admin-1.1.23 (14 Aug 2011)
+
+ 14 Aug 2011; Fabio Erculiani <lxnay@gentoo.org> +389-admin-1.1.23.ebuild:
+ version bump
*389-admin-1.1.16 (14 Jun 2011)
--- /dev/null
+# Copyright 1999-2011 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/net-nds/389-ds-base/389-ds-base-1.2.9.6.ebuild,v 1.1 2011/08/14 09:24:15 lxnay Exp $
+
+EAPI=2
+
+WANT_AUTOMAKE="1.9"
+MY_P=${P/_alpha/.a}
+MY_P=${MY_P/_rc/.rc}
+inherit eutils multilib flag-o-matic autotools
+
+DESCRIPTION="389 Directory Server (core librares and daemons )"
+HOMEPAGE="http://port389.org/"
+SRC_URI="http://directory.fedoraproject.org/sources/${MY_P}.tar.bz2"
+
+LICENSE="GPL-2-with-exceptions"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE="autobind auto-dn-suffix debug doc +pam-passthru +dna +ldapi +bitwise +presence kerberos selinux"
+
+ALL_DEPEND="!>=sys-libs/db-5.0
+ dev-libs/nss[utils]
+ dev-libs/nspr
+ dev-libs/svrcore
+ dev-libs/mozldap
+ >=dev-libs/cyrus-sasl-2.1.19
+ >=dev-libs/icu-3.4
+ >=sys-libs/db-4.5
+ >=net-analyzer/net-snmp-5.1.2
+ dev-libs/openssl
+ sys-apps/tcp-wrappers
+ sys-libs/pam
+ sys-libs/zlib
+ dev-perl/perl-mozldap
+ dev-libs/libpcre:3
+ kerberos? ( net-nds/openldap
+ >=app-crypt/mit-krb5-1.7-r100[openldap] )
+ selinux? ( >=sys-apps/policycoreutils-1.30.30
+ sec-policy/selinux-base-policy )"
+
+DEPEND="${ALL_DEPEND}
+ dev-util/pkgconfig
+ sys-devel/libtool
+ doc? ( app-doc/doxygen )
+ selinux? ( sys-devel/m4 >=sys-apps/checkpolicy-1.30.12 )
+ sys-apps/sed"
+RDEPEND="${ALL_DEPEND}
+ virtual/perl-Time-Local
+ virtual/perl-MIME-Base64"
+
+S="${WORKDIR}/${MY_P}"
+
+pkg_setup() {
+ enewgroup dirsrv
+ enewuser dirsrv -1 -1 -1 dirsrv
+}
+
+src_prepare() {
+ epatch "${FILESDIR}/selinux.patch"
+
+ # as per 389 documentation, when 64bit, export USE_64
+ use amd64 && export USE_64=1
+
+ sed -i -e 's/nobody/dirsrv/g' configure.ac || die "sed failed on configure.ac"
+ eautoreconf
+
+ # enable nsslapd-allow-unauthenticated-binds by default
+ sed -i '/^nsslapd-allow-unauthenticated-binds/ s/off/on/' "${S}"/ldap/ldif/template-dse.ldif.in || \
+ die "cannot tweak default setting: nsslapd-allow-unauthenticated-binds"
+
+}
+
+src_configure() {
+ local myconf=""
+
+ use auto-dn-suffix && myconf="${myconf} --enable-auto-dn-suffix"
+ use selinux && myconf="${myconf} --with-selinux"
+
+ econf \
+ $(use_enable debug) \
+ $(use_enable pam-passthru) \
+ $(use_enable ldapi) \
+ $(use_enable autobind) \
+ $(use_enable dna) \
+ $(use_enable bitwise) \
+ $(use_enable presence) \
+ $(use_with kerberos) \
+ --enable-maintainer-mode \
+ --enable-autobind \
+ --with-fhs \
+ $myconf || die "econf failed"
+}
+
+src_compile() {
+ append-lfs-flags
+
+ # Use -j1 otherwise libacl-plugin.so could fail to install properly
+ emake -j1 || die "compile failed"
+ if use selinux; then
+ emake -f selinux/Makefile || die " build selinux policy failed"
+ fi
+}
+
+src_install () {
+ # Use -j1 otherwise libacl-plugin.so could fail to install properly
+ emake -j1 DESTDIR="${D}" install || die "emake install failed"
+
+ if use selinux;then
+ emake -f selinux/Makefile DESTDIR="${D}" install || die "Install selinux policy failed"
+ fi
+
+ # install not installed header
+ insinto /usr/include/dirsrv
+ doins ldap/servers/slapd/slapi-plugin.h
+
+ # for build free-ipa require winsync-plugin
+ doins ldap/servers/plugins/replication/winsync-plugin.h
+ doins ldap/servers/plugins/replication/repl-session-plugin.h
+
+ # make sure perl scripts have a proper shebang
+ cd "${D}"/usr/share/dirsrv/script-templates/
+
+ for i in $(find ./ -iname '*.pl') ;do
+ sed -i -e 's/#{{PERL-EXEC}}/#\!\/usr\/bin\/perl/' $i || die
+ done
+
+ # remove redhat style init script
+ rm -rf "${D}"/etc/rc.d || die
+ rm -rf "${D}"/etc/default || die
+
+ # and install gentoo style init script
+ newinitd "${FILESDIR}"/389-ds.initd 389-ds
+ newinitd "${FILESDIR}"/389-ds-snmp.initd 389-ds-snmp
+
+ # install Gentoo-specific start/stop scripts
+ rm -f "${D}"/usr/sbin/{re,}start-dirsrv || die "cannot remove 389 start/stop executables"
+ exeinto /usr/sbin
+ doexe "${FILESDIR}"/{re,}start-dirsrv
+
+ # cope with libraries being in /usr/lib/dirsrv
+ dodir /etc/env.d
+ echo "LDPATH=/usr/$(get_libdir)/dirsrv" > "${D}"/etc/env.d/08dirsrv
+
+ # create the directory where our log file and database
+ diropts -m 0755
+ dodir /var/lib/dirsrv
+ keepdir /var/lib/dirsrv
+ dodir /var/lock/dirsrv
+ keepdir /var/lock/dirsrv
+ # snmp agent, required directory
+ keepdir /var/agentx
+ dodir /var/agentx
+
+ if use doc; then
+ cd "${S}"
+ doxygen slapi.doxy || die "cannot run doxygen"
+ dohtml -r docs/html
+ fi
+}
+
+pkg_postinst() {
+ if use selinux; then
+ if has "loadpolicy" $FEATURES; then
+ einfo "Inserting the following modules into the module store"
+ cd /usr/share/selinux/targeted # struct policy not supported
+ semodule -s dirsrv -i dirsrv.pp
+ else
+ elog
+ elog "Policy has not been loaded. It is strongly suggested"
+ elog "that the policy be loaded before continuing!!"
+ elog
+ elog "Automatic policy loading can be enabled by adding"
+ elog "\"loadpolicy\" to the FEATURES in make.conf."
+ elog
+ ebeep 4
+ fi
+ fi
+
+ elog
+ elog "If you are planning to use 389-ds-snmp (ldap-agent),"
+ elog "make sure to properly configure: /etc/dirsrv/config/ldap-agent.conf"
+ elog "adding proper 'server' entries, and adding the lines below to"
+ elog " => /etc/snmp/snmpd.conf"
+ elog
+ elog "master agentx"
+ elog "agentXSocket /var/agentx/master"
+ elog
+ elog
+ elog "To start 389 Directory Server (LDAP service) at boot:"
+ elog
+ elog " rc-update add 389-ds default"
+ elog
+
+ elog "If you are upgrading from previous 1.2.6 release candidates"
+ elog "please see:"
+ elog "http://directory.fedoraproject.org/wiki/Subtree_Rename#warning:_upgrade_from_389_v1.2.6_.28a.3F.2C_rc1_.7E_rc6.29_to_v1.2.6_rc6_or_newer"
+ elog
+
+}
# ChangeLog for net-nds/389-ds-base
# Copyright 1999-2011 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/net-nds/389-ds-base/ChangeLog,v 1.19 2011/08/13 06:08:30 lxnay Exp $
+# $Header: /var/cvsroot/gentoo-x86/net-nds/389-ds-base/ChangeLog,v 1.20 2011/08/14 09:24:15 lxnay Exp $
+
+*389-ds-base-1.2.9.6 (14 Aug 2011)
+
+ 14 Aug 2011; Fabio Erculiani <lxnay@gentoo.org> +389-ds-base-1.2.9.6.ebuild:
+ version bump
13 Aug 2011; Fabio Erculiani <lxnay@gentoo.org> 389-ds-base-1.2.8.3.ebuild,
+files/selinux.patch: