rpms/dap-server/devel dap-server.spec,1.17,1.18

Patrice Dumas (pertusus) fedora-extras-commits at redhat.com
Tue Sep 26 09:10:03 UTC 2006


Author: pertusus

Update of /cvs/extras/rpms/dap-server/devel
In directory cvs-int.fedora.redhat.com:/tmp/cvs-serv24866

Modified Files:
	dap-server.spec 
Log Message:
* Tue Sep 26 2006 Patrice Dumas <pertusus at free.fr> 3.7.1-2
- install cgi files according to the FHS, owned by root



Index: dap-server.spec
===================================================================
RCS file: /cvs/extras/rpms/dap-server/devel/dap-server.spec,v
retrieving revision 1.17
retrieving revision 1.18
diff -u -r1.17 -r1.18
--- dap-server.spec	19 Sep 2006 23:53:31 -0000	1.17
+++ dap-server.spec	26 Sep 2006 09:10:02 -0000	1.18
@@ -1,13 +1,14 @@
 %define dap_cachedir     /var/cache/dap-server
 %define dap_webconfdir   %{_sysconfdir}/httpd/conf.d
-%define dap_cgidir       /var/www/opendap
+%define dap_cgidir       %{_datadir}/opendap-cgi
+%define dap_cgiconfdir   %{_sysconfdir}/opendap/
 %define __perl_provides %{nil}
 %define __perl_requires %{nil}
 
 Summary:         Basic request handling for OPeNDAP servers 
 Name:            dap-server
 Version:         3.7.1
-Release:         1%{?dist}
+Release:         2%{?dist}
 License:         LGPL
 Group:           System Environment/Daemons 
 Source0:         ftp://ftp.unidata.ucar.edu/pub/opendap/source/%{name}-%{version}.tar.gz
@@ -44,6 +45,9 @@
 configuration. The web server is setup such that the CGI directory is
 at %{dap_cgidir}. 
 
+The config file for the cgi script, dap-server.rc, is in 
+%{dap_cgiconfdir}.
+
 The default configuration allows for the use of the following handlers:
 freeform, netcdf and hdf4.
 
@@ -55,7 +59,8 @@
 %patch0
 
 %build
-%configure --with-cgidir=%{dap_cgidir}
+%configure --with-cgidir=%{dap_cgidir} 
+#--with-cgiconfdir=%{dap_cgiconfdir}
 make %{?_smp_mflags}
 
 # prepend -sample to cgi and config file to install them as doc
@@ -67,6 +72,8 @@
 # adjust jgofs paths
 sed -i -e 's:^\$ENV{"JGOFS_METHOD"} = "`pwd`";:\$ENV{"JGOFS_METHOD"} = "%{_bindir}";:' nph-dods
 sed -i -e 's:^\$ENV{"JGOFS_OBJECT"} = "`pwd`";:\$ENV{"JGOFS_OBJEXT"} = "%{dap_cgidir}";:' nph-dods
+# put the cgi config file at a right place
+sed -i -e 's:\./dap-server.rc:%{dap_cgiconfdir}dap-server.rc:' nph-dods
 
 # /usr/tmp isn't a safe place, substitute to a dir in 
 # /var/cache
@@ -78,12 +85,18 @@
 sed -e 's:<<prefix>>/share/dap-server-cgi:%{dap_cgidir}:' \
     opendap_apache.conf-sample > opendap_apache.conf
 
+
 %install
 rm -rf $RPM_BUILD_ROOT
 make DESTDIR=$RPM_BUILD_ROOT install
 install -d -m755 $RPM_BUILD_ROOT/%{dap_cachedir}
 install -d -m755 $RPM_BUILD_ROOT/%{dap_webconfdir}
-install -m644 opendap_apache.conf $RPM_BUILD_ROOT/%{dap_webconfdir}/opendap_apache.conf
+install -d -m755 $RPM_BUILD_ROOT/%{dap_cgiconfdir}
+install -m644 opendap_apache.conf $RPM_BUILD_ROOT/%{dap_webconfdir}/
+# install the config file below %_sysconfdir
+install -m644 dap-server.rc $RPM_BUILD_ROOT/%{dap_cgiconfdir}/
+# the config file is also installed in the cgi directory
+rm $RPM_BUILD_ROOT/%{dap_cgidir}/dap-server.rc
 
 %clean
 rm -rf $RPM_BUILD_ROOT
@@ -103,12 +116,15 @@
 %files cgi
 %defattr(-,root,root,-)
 %config(noreplace) %{dap_webconfdir}/opendap_apache.conf
-%attr(-,apache,apache) %dir %{dap_cgidir}
-%attr(-,apache,apache) %config(noreplace) %{dap_cgidir}/dap-server.rc
-%attr(-,apache,apache) %{dap_cgidir}/nph-dods
+%dir %{dap_cgiconfdir}
+%config(noreplace) %{dap_cgiconfdir}/dap-server.rc
+%{dap_cgidir}/
 
 
 %changelog
+* Tue Sep 26 2006 Patrice Dumas <pertusus at free.fr> 3.7.1-2
+- install cgi files according to the FHS, owned by root
+
 * Wed Sep  6 2006 Patrice Dumas <pertusus at free.fr> 3.7.1-1
 - update to 3.7.1
 - remove patch not needed anymore to link against libdap >= 3.7.0




More information about the fedora-extras-commits mailing list