]> git.pld-linux.org Git - packages/apache-mod_roaming.git/blobdiff - apache-mod_roaming.spec
- version 2.0.0; fails on linking
[packages/apache-mod_roaming.git] / apache-mod_roaming.spec
index 53b0d880858ca9f9455b30b975a88b8b466b3902..128d4f5509e22b153022e4c343e879988a11242e 100644 (file)
@@ -1,39 +1,35 @@
+%define                mod_name        roaming
+%define        apxs            /usr/sbin/apxs
 Summary:       Enables Netscape Communicator roaming profiles with Apache
 Summary(cs):   Modul podpory roamingových profilù Netscape Communicatora pro Apache
 Summary(da):   Et apachemodul som lader webtjeneren håndtere profiler for Netscape Communicator
 Summary(de):   Aktiviert den Netscape Communicator für das Profilroaming mit Apache
+Summary(es):   Módulo de acceso roaming para navegación en red para Apache
 Summary(fr):   Permet l'itinérance de profils Netscape Communicator avec Apache
 Summary(it):   Abilita i profili di roaming di Netscape Communicator con Apache
-Summary(no):   En apachemodul som lar webtjeneren håndtere profiler for Netscape Communicator
+Summary(nb):   En apachemodul som lar webtjeneren håndtere profiler for Netscape Communicator
 Summary(pl):   Modu³ Apache obs³uguj±cy przechodnie profile Netscape Communicatora
+Summary(pt_BR):        Modulo "Netscape Roaming Access" para o Apache
 Summary(sk):   WWW prehliadaè Netscape Navigator
 Summary(sv):   Möjliggör Netscape Communicator reseprofiler med Apache
-Summary():     
-Name:          mod_roaming
-Version:       1.0.2
-Release:       4
-License:       BSD type
+Name:          apache-mod_%{mod_name}
+Version:       2.0.0
+Release:       1
+License:       BSD-like
 Group:         Networking/Daemons
-Group(cs):     Sí»ové/Démoni
-Group(da):     Netværks/Dæmoner
-Group(de):     Netzwerkwesen/Server
-Group(es):     Red/Servidores
-Group(fr):     Réseau/Serveurs
-Group(is):     Net/Púkar
-Group(it):     Rete/Demoni
-Group(no):     Nettverks/Daemoner
-Group(pl):     Sieciowe/Serwery
-Group(pt):     Rede/Servidores
-Group(ru):     óÅÔØ/äÅÍÏÎÙ
-Group(sl):     Omre¾ni/Stre¾niki
-Group(sv):     Nätverk/Demoner
-Group(uk):     íÅÒÅÖÁ/äÅÍÏÎÉ
-Source0:       http://www.klomp.org/mod_roaming/%{name}-%{version}.tar.gz
-Source1:       roaming.conf
+Source0:       http://www.klomp.org/mod_roaming/mod_%{mod_name}-%{version}.tar.gz
+# Source0-md5: ad2d720d7ffd08c4e7f2e6979795237e
+Source1:       %{name}.conf
 URL:           http://www.klomp.org/mod_roaming/
+BuildRequires: %{apxs}
+BuildRequires: apache-devel >= 2
+Requires(post,preun):  %{apxs}
+Requires(post,preun):  grep
+Requires(preun):       fileutils
+Requires:      apache >= 2
 BuildRoot:     %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
-BuildRequires: apache-devel
-Requires:      webserver
+
+%define                _pkglibdir      %(%{apxs} -q LIBEXECDIR)
 
 %description
 With mod_roaming you can use your Apache web server as a Netscape
@@ -97,6 +93,14 @@ serwerze, dzi
 ustawieñ z dowolnego Netscape Communicatora >= 4.5, który ma dostêp do
 serwera.
 
+%description -l pt_BR
+Com o mod_roaming você pode usar o Apache como um servidor de "Roaming
+Access" para o Netscape. Isto permite que você armazene preferências,
+bookmarks, livros de acessos, cookies, etc, do Netscape Communicator
+4.5 no servidor, sendo que com isso, você pode usar as mesmas
+configurações para qualquer Netscape 4.5 que possa acessar este
+servidor.
+
 %description -l sv
 Med mod_roaming kan du använda din webbserver Apache som en server för
 Netscape reseprofiler. Detta låter dig lagra dina Netscape
@@ -105,26 +109,45 @@ servern s
 Netscape Communicator 4.5 som kan komma åt servern.
 
 %prep
-%setup -q
+%setup -q -n mod_%{mod_name}-%{version}
 
 %build
-%{_sbindir}/apxs -c -o mod_roaming.so -lc mod_roaming.c
+%{apxs} -c -o mod_roaming.so -lc mod_roaming.c
 
 %install
 rm -rf $RPM_BUILD_ROOT
-install -d $RPM_BUILD_ROOT{%{_libdir}/apache,%{_sysconfdir}/httpd,%{_var}/lib/mod_roaming}
+install -d $RPM_BUILD_ROOT{%{_pkglibdir},%{_sysconfdir}/httpd,%{_var}/lib/mod_roaming}
 
-install mod_roaming.so $RPM_BUILD_ROOT%{_libdir}/apache
-install %{SOURCE1} $RPM_BUILD_ROOT%{_sysconfdir}/httpd
-
-gzip -9nf CHANGES INSTALL LICENSE README
+install mod_%{mod_name}.so $RPM_BUILD_ROOT%{_pkglibdir}
+install %{SOURCE1} $RPM_BUILD_ROOT%{_sysconfdir}/httpd/mod_roaming.conf
 
 %clean
 rm -rf $RPM_BUILD_ROOT
 
+%post
+%{apxs} -e -a -n %{mod_name} %{_pkglibdir}/mod_%{mod_name}.so 1>&2
+if [ -f /etc/httpd/httpd.conf ] && ! grep -q "^Include.*mod_%{mod_name}.conf" /etc/httpd/httpd.conf; then
+       echo "Include /etc/httpd/mod_%{mod_name}.conf" >> /etc/httpd/httpd.conf
+fi
+if [ -f /var/lock/subsys/httpd ]; then
+       /etc/rc.d/init.d/httpd restart 1>&2
+fi
+
+%preun
+if [ "$1" = "0" ]; then
+       %{apxs} -e -A -n %{mod_name} %{_pkglibdir}/mod_%{mod_name}.so 1>&2
+       umask 027
+       grep -v "^Include.*mod_%{mod_name}.conf" /etc/httpd/httpd.conf > \
+               /etc/httpd/httpd.conf.tmp
+       mv -f /etc/httpd/httpd.conf.tmp /etc/httpd/httpd.conf
+       if [ -f /var/lock/subsys/httpd ]; then
+               /etc/rc.d/init.d/httpd restart 1>&2
+       fi
+fi
+
 %files
 %defattr(644,root,root,755)
-%doc CHANGES* INSTALL* LICENSE* README*
-%attr(755,root,root) %{_libdir}/apache/mod_roaming.so
+%doc CHANGES INSTALL LICENSE README
+%attr(755,root,root) %{_pkglibdir}/mod_roaming.so
 %attr(660,root,http) %dir %{_var}/lib/mod_roaming
-%config %{_sysconfdir}/httpd/roaming.conf
+%config(noreplace) %{_sysconfdir}/httpd/mod_roaming.conf
This page took 0.372823 seconds and 4 git commands to generate.