From ee39e4c87b0bd3b3a14d27463e7e3803157d71a7 Mon Sep 17 00:00:00 2001 From: Juan RP Date: Sun, 18 Apr 2010 17:48:17 +0200 Subject: [PATCH] Added cyrus-sasl-2.1.23 build template. --HG-- extra : convert_revision : cd7571b0e341f27eb60fd91525bdfa1a71a51fae --- srcpkgs/cyrus-sasl-modules | 1 + srcpkgs/cyrus-sasl-modules-ldap | 1 + srcpkgs/cyrus-sasl-modules-sql | 1 + .../cyrus-sasl-modules-ldap.template | 17 ++++++ .../cyrus-sasl-modules-sql.template | 18 ++++++ .../cyrus-sasl/cyrus-sasl-modules.template | 20 +++++++ srcpkgs/cyrus-sasl/files/saslauthd.confd | 3 + srcpkgs/cyrus-sasl/files/saslauthd.rc | 9 +++ .../patches/cyrus-sasl-2.1.22-gcc44.patch | 24 ++++++++ srcpkgs/cyrus-sasl/template | 56 +++++++++++++++++++ 10 files changed, 150 insertions(+) create mode 120000 srcpkgs/cyrus-sasl-modules create mode 120000 srcpkgs/cyrus-sasl-modules-ldap create mode 120000 srcpkgs/cyrus-sasl-modules-sql create mode 100644 srcpkgs/cyrus-sasl/cyrus-sasl-modules-ldap.template create mode 100644 srcpkgs/cyrus-sasl/cyrus-sasl-modules-sql.template create mode 100644 srcpkgs/cyrus-sasl/cyrus-sasl-modules.template create mode 100644 srcpkgs/cyrus-sasl/files/saslauthd.confd create mode 100644 srcpkgs/cyrus-sasl/files/saslauthd.rc create mode 100644 srcpkgs/cyrus-sasl/patches/cyrus-sasl-2.1.22-gcc44.patch create mode 100644 srcpkgs/cyrus-sasl/template diff --git a/srcpkgs/cyrus-sasl-modules b/srcpkgs/cyrus-sasl-modules new file mode 120000 index 0000000000..b251eb66f9 --- /dev/null +++ b/srcpkgs/cyrus-sasl-modules @@ -0,0 +1 @@ +cyrus-sasl \ No newline at end of file diff --git a/srcpkgs/cyrus-sasl-modules-ldap b/srcpkgs/cyrus-sasl-modules-ldap new file mode 120000 index 0000000000..b251eb66f9 --- /dev/null +++ b/srcpkgs/cyrus-sasl-modules-ldap @@ -0,0 +1 @@ +cyrus-sasl \ No newline at end of file diff --git a/srcpkgs/cyrus-sasl-modules-sql b/srcpkgs/cyrus-sasl-modules-sql new file mode 120000 index 0000000000..b251eb66f9 --- /dev/null +++ b/srcpkgs/cyrus-sasl-modules-sql @@ -0,0 +1 @@ +cyrus-sasl \ No newline at end of file diff --git a/srcpkgs/cyrus-sasl/cyrus-sasl-modules-ldap.template b/srcpkgs/cyrus-sasl/cyrus-sasl-modules-ldap.template new file mode 100644 index 0000000000..3906307df3 --- /dev/null +++ b/srcpkgs/cyrus-sasl/cyrus-sasl-modules-ldap.template @@ -0,0 +1,17 @@ +# Template file for 'cyrus-sasl-modules-ldap'. +# +short_desc="Cyrus SASL - pluggable authentication modules (LDAP)" +long_desc=" + This is the Cyrus SASL API implementation, version 2.1. See package + libsasl and RFC 2222 for more information. + + This package provides the LDAP plugin." + +Add_dependency run glibc +Add_dependency run libldap + +do_install() +{ + mkdir -p ${DESTDIR}/usr/lib/sasl2 + mv ${SRCPKGDESTDIR}/usr/lib/sasl2/libldapdb.* ${DESTDIR}/usr/lib/sasl2 +} diff --git a/srcpkgs/cyrus-sasl/cyrus-sasl-modules-sql.template b/srcpkgs/cyrus-sasl/cyrus-sasl-modules-sql.template new file mode 100644 index 0000000000..19850193c8 --- /dev/null +++ b/srcpkgs/cyrus-sasl/cyrus-sasl-modules-sql.template @@ -0,0 +1,18 @@ +# Template file for 'cyrus-sasl-modules-sql'. +# +short_desc="Cyrus SASL - pluggable authentication modules (SQL)" +long_desc=" + This is the Cyrus SASL API implementation, version 2.1. See package + libsasl and RFC 2222 for more information. + + This package provides the SQL plugin, which supports MySQL and PostgreSQL." + +Add_dependency run glibc +Add_dependency run libmysqlclient +Add_dependency run postgresql-libs + +do_install() +{ + mkdir -p ${DESTDIR}/usr/lib/sasl2 + mv ${SRCPKGDESTDIR}/usr/lib/sasl2/libsql.* ${DESTDIR}/usr/lib/sasl2 +} diff --git a/srcpkgs/cyrus-sasl/cyrus-sasl-modules.template b/srcpkgs/cyrus-sasl/cyrus-sasl-modules.template new file mode 100644 index 0000000000..790a6e2563 --- /dev/null +++ b/srcpkgs/cyrus-sasl/cyrus-sasl-modules.template @@ -0,0 +1,20 @@ +# Template file for 'cyrus-sasl-plugins'. +# +short_desc="Cyrus SASL - pluggable authentication modules" +long_desc=" + This is the Cyrus SASL API implementation, version 2.1. See package + libsasl and RFC 2222 for more information. + + This package provides the following SASL modules: LOGIN, PLAIN, ANONYMOUS, + NTLM, CRAM-MD5, and DIGEST-MD5 (with DES support)." + +Add_dependency run glibc +Add_dependency run openssl +Add_dependency run mit-krb5-libs +Add_dependency run e2fsprogs-libs + +do_install() +{ + mkdir -p ${DESTDIR}/usr/lib + mv ${SRCPKGDESTDIR}/usr/lib/sasl2 ${DESTDIR}/usr/lib +} diff --git a/srcpkgs/cyrus-sasl/files/saslauthd.confd b/srcpkgs/cyrus-sasl/files/saslauthd.confd new file mode 100644 index 0000000000..25c454f0c4 --- /dev/null +++ b/srcpkgs/cyrus-sasl/files/saslauthd.confd @@ -0,0 +1,3 @@ +# Configuration file for Cyrus-SASL daemon. +# +SASLAUTHD_ARGS="-m /var/run/saslauthd -a pam" diff --git a/srcpkgs/cyrus-sasl/files/saslauthd.rc b/srcpkgs/cyrus-sasl/files/saslauthd.rc new file mode 100644 index 0000000000..e78597abe4 --- /dev/null +++ b/srcpkgs/cyrus-sasl/files/saslauthd.rc @@ -0,0 +1,9 @@ +#!/sbin/runscript + +command=/usr/sbin/saslauthd +command_args="${SASLAUTHD_ARGS}" + +depend() +{ + need net +} diff --git a/srcpkgs/cyrus-sasl/patches/cyrus-sasl-2.1.22-gcc44.patch b/srcpkgs/cyrus-sasl/patches/cyrus-sasl-2.1.22-gcc44.patch new file mode 100644 index 0000000000..bf8c05e11e --- /dev/null +++ b/srcpkgs/cyrus-sasl/patches/cyrus-sasl-2.1.22-gcc44.patch @@ -0,0 +1,24 @@ +fix warnings with gcc-4.4 + +http://bugs.gentoo.org/248738 + +--- plugins/digestmd5.c ++++ plugins/digestmd5.c +@@ -2715,7 +2715,7 @@ static sasl_server_plug_t digestmd5_serv + "DIGEST-MD5", /* mech_name */ + #ifdef WITH_RC4 + 128, /* max_ssf */ +-#elif WITH_DES ++#elif defined(WITH_DES) + 112, + #else + 1, +@@ -4034,7 +4034,7 @@ static sasl_client_plug_t digestmd5_clie + "DIGEST-MD5", + #ifdef WITH_RC4 /* mech_name */ + 128, /* max ssf */ +-#elif WITH_DES ++#elif defined(WITH_DES) + 112, + #else + 1, diff --git a/srcpkgs/cyrus-sasl/template b/srcpkgs/cyrus-sasl/template new file mode 100644 index 0000000000..d42df2aede --- /dev/null +++ b/srcpkgs/cyrus-sasl/template @@ -0,0 +1,56 @@ +# Template file for 'cyrus-sasl' +. ${XBPS_SRCPKGDIR}/libsasl/template + +# Unset some unneeded stuff. +unset run_depends build_depends + +pkgname=cyrus-sasl +configure_args="--with-saslauthd=/var/run/saslauthd +--enable-login --enable-plain --enable-sql --disable-sqlite +--enable-postgresql --enable-mysql --enable-ldapdb --with-ldap=/usr" +short_desc="Cyrus SASL - auth daemon and administration tools" +long_desc="${long_desc} + + This package includes the Cyrus SASL authentication daemon and administration + programs for the SASL users database and common binary files for plugin + modules." + +keep_empty_dirs=yes +subpackages="${pkgname}-modules-ldap ${pkgname}-modules-sql ${pkgname}-modules" +openrc_services="saslauthd default off" +conf_files="/etc/conf.d/saslauthd" + +Add_dependency run glibc +Add_dependency run db +Add_dependency run libsasl +Add_dependency run libldap +Add_dependency run mit-krb5-libs +Add_dependency run e2fsprogs-libs +Add_dependency run pam +Add_dependency run openssl +Add_dependency run cyrus-sasl-modules + +Add_dependency build libsasl-devel +Add_dependency build libldap-devel +Add_dependency build mit-krb5-devel +Add_dependency build e2fsprogs-devel +Add_dependency build pam-devel +Add_dependency build openssl-devel +Add_dependency build postgresql-libs-devel +Add_dependency build libmysqlclient-devel + +post_install() +{ + # Remove stuff in libsasl{,-devel} pkgs. + rm -rf ${DESTDIR}/usr/share/man/man3 + rm -rf ${DESTDIR}/usr/include + rm -f ${DESTDIR}/usr/lib/libsasl* + rm -rf ${DESTDIR}/usr/lib/sasl2/libsasldb* + + # Install OpenRC service. + install -d ${DESTDIR}/var/run/saslauthd + install -D -m755 ${FILESDIR}/saslauthd.rc \ + ${DESTDIR}/etc/init.d/saslauthd + install -D -m755 ${FILESDIR}/saslauthd.confd \ + ${DESTDIR}/etc/conf.d/saslauthd +}