]> git.pld-linux.org Git - packages/darkhttpd.git/blob - darkhttpd.spec
new, version 1.11
[packages/darkhttpd.git] / darkhttpd.spec
1 Summary:        A secure, lightweight, fast, single-threaded HTTP/1.1 server
2 Name:           darkhttpd
3 Version:        1.11
4 Release:        1
5 License:        BSD
6 Group:          Networking/Daemons/HTTP
7 Source0:        http://unix4lyfe.org/darkhttpd/%{name}-%{version}.tar.bz2
8 # Source0-md5:  050e5a821b1fa71a82c6efba7fda1323
9 Source1:        %{name}.service
10 Source2:        %{name}.sysconfig
11 URL:            http://unix4lyfe.org/darkhttpd/
12 BuildRequires:  rpmbuild(macros) >= 1.647
13 BuildRequires:  systemd-devel
14 Requires(post,preun,postun):    systemd-units >= 38
15 Requires:       /etc/mime.types
16 Requires:       systemd-units >= 0.38
17 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
18
19 %description
20 darkhttpd is a secure, lightweight, fast and single-threaded HTTP/1.1
21 server.
22
23 Features:
24 - Simple to set up:
25   - Single binary, no other files.
26   - Standalone, doesn't need inetd or ucspi-tcp.
27   - No messing around with config files.
28 - Written in C - efficient and portable.
29 - Small memory footprint.
30 - Event loop, single threaded - no fork() or pthreads.
31 - Generates directory listings.
32 - Supports HTTP GET and HEAD requests.
33 - Supports Range / partial content.
34 - Supports If-Modified-Since.
35 - Supports Keep-Alive connections.
36 - Can serve 301 redirects based on Host header.
37 - Uses sendfile().
38
39 Security:
40 - Can log accesses, including Referer and User-Agent.
41 - Can chroot.
42 - Can drop privileges.
43 - Impervious to /../ sniffing.
44 - Times out idle connections.
45 - Drops overly long requests.
46
47 Limitations:
48 - This server only serves static content - *NO* CGI supported!
49
50 %prep
51 %setup -q
52
53 %build
54 %{__cc} %{rpmcflags} %{rpmcppflags} darkhttpd.c -o %{name} %{rpmldflags}
55
56 %install
57 rm -rf $RPM_BUILD_ROOT
58 install -d $RPM_BUILD_ROOT{%{_sbindir},/etc/sysconfig,%{systemdunitdir}}
59
60 install -p %{name} $RPM_BUILD_ROOT%{_sbindir}/%{name}
61 cp -p %{SOURCE1} $RPM_BUILD_ROOT%{systemdunitdir}/%{name}.service
62 cp -p %{SOURCE2} $RPM_BUILD_ROOT%{_sysconfdir}/sysconfig/%{name}
63
64 %post
65 %systemd_post %{name}.service
66
67 %preun
68 %systemd_preun %{name}.service
69
70 %postun
71 %systemd_reload
72
73 %clean
74 rm -rf $RPM_BUILD_ROOT
75
76 %files
77 %defattr(644,root,root,755)
78 %doc README
79 %config(noreplace) %verify(not md5 mtime size) /etc/sysconfig/%{name}
80 %attr(755,root,root) %{_sbindir}/%{name}
81 %{systemdunitdir}/%{name}.service
This page took 0.067111 seconds and 3 git commands to generate.