#Module-Specific definitions %define mod_name mod_pubcookie %define mod_conf A62_%{mod_name}.conf %define mod_so %{mod_name}.so Summary: Open-source software for intra-institutional web authentication Name: pubcookie Version: 3.3.0a Release: %mkrel 2 Group: System/Servers License: Apache License URL: http://www.pubcookie.org/ Source0: http://www.pubcookie.org/downloads/%{name}-%{version}.tar.bz2 Source1: %{mod_conf}.bz2 Source2: pubcookie.xinetd.bz2 Patch0: pubcookie-3.3.0a-DESTDIR.diff Patch1: pubcookie-3.3.0a-paths.diff Patch2: pubcookie-3.3.0a-pki_dir.diff Patch3: pubcookie-3.3.0a-no_install-modules.diff Requires: xinetd Requires: rootcerts Requires: openssl Requires(pre): rpm-helper Requires(postun): rpm-helper BuildRequires: apache-devel >= 2.0.54 BuildRequires: openssl-devel BuildRequires: openldap-devel BuildRequires: krb5-devel BuildRequires: file BuildRequires: autoconf2.5 BuildRequires: automake1.7 BuildRequires: libtool BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-buildroot %description Pubcookie consists of a standalone login server and modules for common web server platforms like Apache and Microsoft IIS. Together, these components can turn existing authentication services (like Kerberos, LDAP, or NIS) into a solution for single sign-on authentication to websites throughout an institution. %package -n apache-%{mod_name} Summary: Open-source software for intra-institutional web authentication Group: System/Servers Requires(pre): rpm-helper Requires(postun): rpm-helper Requires(pre): apache-conf >= 2.0.54 Requires(pre): apache >= 2.0.54 Requires(pre): apache-mod_ssl >= 2.0.54 Requires(pre): %{name} = %{version}-%{release} Requires: apache-conf >= 2.0.54 Requires: apache >= 2.0.54 Requires: apache-mod_ssl >= 2.0.54 Requires: %{name} = %{version}-%{release} %description -n apache-%{mod_name} Pubcookie consists of a standalone login server and modules for common web server platforms like Apache and Microsoft IIS. Together, these components can turn existing authentication services (like Kerberos, LDAP, or NIS) into a solution for single sign-on authentication to websites throughout an institution. %prep %setup -q -n %{name}-%{version} %patch0 -p0 %patch1 -p0 %patch2 -p0 %patch3 -p0 bzcat %{SOURCE2} > pubcookie.xinetd find . -type d -perm 0700 -exec chmod 755 {} \; find . -type d -perm 0555 -exec chmod 755 {} \; find . -type f -perm 0555 -exec chmod 755 {} \; find . -type f -perm 0444 -exec chmod 644 {} \; for i in `find . -type d -name CVS` `find . -type d -name .svn` `find . -type f -name .cvs\*` `find . -type f -name .#\*`; do if [ -e "$i" ]; then rm -r $i; fi >&/dev/null done # strip away annoying ^M find . -type f|xargs file|grep 'CRLF'|cut -d: -f1|xargs perl -p -i -e 's/\r//' find . -type f|xargs file|grep 'text'|cut -d: -f1|xargs perl -p -i -e 's/\r//' %build rm -f configure libtoolize --copy --force; aclocal-1.7; autoconf %configure2_5x \ --enable-apache \ --enable-login \ --enable-default-des \ --enable-krb5 \ --enable-ldap \ --enable-shadow \ --with-apxs=%{_sbindir}/apxs %make %install [ "%{buildroot}" != "/" ] && rm -rf %{buildroot} install -d %{buildroot}%{_sysconfdir}/httpd/modules.d install -d %{buildroot}%{_sysconfdir}/xinetd.d install -d %{buildroot}%{_libdir}/apache-extramodules install -d %{buildroot}%{_datadir}/pubcookie/login_templates.default install -d %{buildroot}%{_localstatedir}/pubcookie/keys %makeinstall_std mv %{buildroot}%{_libdir}/apache/%{mod_so} %{buildroot}%{_libdir}/apache-extramodules/ bzcat %{SOURCE1} > %{buildroot}%{_sysconfdir}/httpd/modules.d/%{mod_conf} cp %{buildroot}%{_sysconfdir}/pubcookie/config.login.sample %{buildroot}%{_sysconfdir}/pubcookie/config install -m0644 pubcookie.xinetd %{buildroot}%{_sysconfdir}/xinetd.d/pubcookie %post service xinetd restart %postun service xinetd restart %post -n apache-%{mod_name} if [ -f /var/lock/subsys/httpd ]; then %{_initrddir}/httpd restart 1>&2; fi %postun -n apache-%{mod_name} if [ "$1" = "0" ]; then if [ -f /var/lock/subsys/httpd ]; then %{_initrddir}/httpd restart 1>&2 fi fi %clean [ "%{buildroot}" != "/" ] && rm -rf %{buildroot} %files %defattr(-,root,root) %doc doc/*.txt %attr(0644,root,root) %config(noreplace) %{_sysconfdir}/xinetd.d/pubcookie %attr(0644,root,root) %config(noreplace) %{_sysconfdir}/pubcookie/config %attr(0644,root,root) %{_sysconfdir}/pubcookie/config.login.sample %attr(0755,root,root) %{_sbindir}/keyclient %attr(0755,root,root) %{_sbindir}/keyserver %dir %attr(0755,root,root) %{_localstatedir}/pubcookie %dir %attr(0755,root,root) %{_localstatedir}/pubcookie/keys %{_datadir}/pubcookie %files -n apache-%{mod_name} %defattr(-,root,root) %doc doc/*.html doc/*.css %attr(0644,root,root) %config(noreplace) %{_sysconfdir}/httpd/modules.d/%{mod_conf} %attr(0755,root,root) %{_libdir}/apache-extramodules/%{mod_so} %changelog * Fri Aug 11 2006 Oden Eriksson <oeriksson@mandriva.com> 3.3.0a-2mdk - rebuild * Thu May 11 2006 Oden Eriksson <oeriksson@mandriva.com> 3.3.0a-1mdk - initial Mandriva package