]> git.pld-linux.org Git - packages/mathopd.git/commitdiff
- init PLD spec
authorareq <areq@pld-linux.org>
Sun, 30 Dec 2001 18:10:31 +0000 (18:10 +0000)
committercvs2git <feedback@pld-linux.org>
Sun, 24 Jun 2012 12:13:13 +0000 (12:13 +0000)
Changed files:
    mathopd.spec -> 1.1

mathopd.spec [new file with mode: 0644]

diff --git a/mathopd.spec b/mathopd.spec
new file mode 100644 (file)
index 0000000..9bb7842
--- /dev/null
@@ -0,0 +1,110 @@
+Summary:       A fast, lightweight, non-forking HTTP server for UN*X systems
+Summary(pl):   Szybki, niedu¿y non-forking serwer httpd
+Name:          mathopd
+Version:       1.4b15
+Release:       1
+Group:         Networking
+Group(de):     Netzwerkwesen
+Group(es):     Red
+Group(pl):     Sieciowe
+Group(pt_BR):  Rede
+License:       BSD
+Source0:       http://mathop.diva.nl/dist/%{name}-%{version}.tar.gz
+Source1:       %{name}.init
+Source2:       %{name}.conf
+Provides:      httpd
+Provides:      webserver
+Prereq:                /sbin/chkconfig
+Prereq:                /usr/sbin/useradd
+Prereq:                /usr/bin/getgid
+Prereq:                /bin/id
+Prereq:                sh-utils
+Prereq:                rc-scripts
+URL:           http://www.mathopd.org
+BuildRoot:     %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
+
+%description
+Mathopd is a very small, yet very fast HTTP server for UN*X systems.
+Mathopd is designed specifically to handle a large number of
+connections with minimal fuss. It contains no unnecessary add-ons, but
+it does the trick for most things.
+
+
+%description -l pl
+Mathopd jest bardzo ma³ym, bardzo szybkim serwerewm HTTP dla UN*X
+systemów.
+
+%prep
+%setup -q
+
+%build
+CFLAGS="%{rpmcflags}"; export CFLAGS
+cd src
+%{__make}
+
+%install
+rm -rf $RPM_BUILD_ROOT
+
+install -d $RPM_BUILD_ROOT/home/httpd/cgi-bin
+install -d $RPM_BUILD_ROOT/etc/rc.d/init.d
+install -d $RPM_BUILD_ROOT{%{_sbindir},%{_var}/log/mathopd}
+
+install %{SOURCE1} $RPM_BUILD_ROOT/etc/rc.d/init.d/mathopd
+install %{SOURCE2} $RPM_BUILD_ROOT%{_sysconfdir}/
+install src/mathopd $RPM_BUILD_ROOT/%{_sbindir}
+
+gzip -9nf [A-Z]* doc/*
+
+%clean
+rm -rf $RPM_BUILD_ROOT
+
+%pre
+if [ -n "`getgid http`" ]; then
+        if [ "`getgid http`" != "51" ]; then
+                echo "Warning: group http haven't gid=51. Correct this before install %{name}" 1>&2
+                exit 1
+        fi
+else
+        /usr/sbin/groupadd -g 51 -r -f http
+fi
+if [ -n "`id -u http 2>/dev/null`" ]; then
+        if [ "`id -u http`" != "51" ]; then
+                echo "Warning: user http haven't uid=51. Correct this before install %{name}" 1>&2
+                exit 1
+        fi
+else
+        /usr/sbin/useradd -u 51 -r -d /home/httpd -s /bin/false -c "HTTP User" -g http http 1>&2
+fi
+
+%post
+/sbin/chkconfig --add %{name}
+if [ -f /var/lock/subsys/mathopd ]; then
+       /etc/rc.d/init.d/mathopd restart 1>&2
+else
+       echo "Run \"/etc/rc.d/init.d/mathopd start\" to start %{name} daemon."
+fi
+
+%preun
+if [ "$1" = "0" ]; then
+       if [ -f /var/lock/subsys/mathopd ]; then
+               /etc/rc.d/init.d/mathopd stop 1>&2
+       fi
+fi
+if [ "$1" = "0" ]; then
+       /sbin/chkconfig --del %{name}
+fi
+
+%postun
+if [ "$1" = "0" ]; then
+        /usr/sbin/userdel http
+        /usr/sbin/groupdel http
+fi
+
+%files
+%defattr(644,root,root,755)
+%doc doc/*.gz *.gz
+%attr(755,root,root) %{_sbindir}/mathopd
+%attr(-, http, http) /home/httpd
+%attr(0755, root, root) /etc/rc.d/init.d/mathopd
+%config %{_sysconfdir}/mathopd.conf
+%attr( 750,http,http) %dir %{_var}/log/mathopd
This page took 0.176786 seconds and 4 git commands to generate.