]> git.pld-linux.org Git - packages/dhcdbd.git/blob - dhcdbd.spec
- version 2.14
[packages/dhcdbd.git] / dhcdbd.spec
1 #
2 # TODO:
3 # - move header file to -devel
4 # - split an -init  (what for? --radek)
5 #
6 Summary:        DHCP D-BUS daemon (dhcdbd) controls dhclient sessions with D-BUS, stores and presents DHCP options
7 Summary(pl):    Demon DHCP D-BUS (dhcdbd) - sterowanie sesjami dhclient przy u¿yciu D-BUS, przechowywanie opcji DHCP
8 Name:           dhcdbd
9 Version:        1.14
10 Release:        0.1
11 License:        GPL
12 Group:          Networking/Daemons
13 Source0:        http://people.redhat.com/~jvdias/dhcdbd/%{name}-%{version}.tar.gz
14 # Source0-md5:  1180dee7a51a4384d55768650634cf93
15 Source1:        %{name}.init
16 URL:            http://people.redhat.com/~jvdias/dhcdbd/
17 BuildRequires:  dbus-devel >= 0.33
18 BuildRequires:  rpmbuild(macros) >= 1.268
19 Requires(post,preun):   /sbin/chkconfig
20 Requires:       dbus >= 0.33
21 Requires:       dhcp-client >= 3:3.0.3-3
22 Requires:       rc-scripts
23 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
24
25 %description
26 DHCP D-BUS daemon (dhcdbd) controls dhclient sessions with D-BUS,
27 stores and presents DHCP options.
28
29 %description -l pl
30 Demon DHCP D-BUS (dhcdbd) steruje sesjami dhclient przy u¿yciu D-BUS,
31 a tak¿e przechowuje i przedstawia opcje DHCP.
32
33 %prep
34 %setup -q
35
36 %build
37 %{__make} \
38         CC="%{__cc}" \
39         CFLAGS="%{rpmcflags} -I%{_libdir}/dbus-1.0/include" \
40         LDFLAGS="%{rpmldflags}"
41
42 %install
43 rm -rf $RPM_BUILD_ROOT
44 install -d $RPM_BUILD_ROOT{/etc/rc.d/init.d,%{_sbindir}}
45
46 %{__make} install \
47         DESTDIR=$RPM_BUILD_ROOT
48
49 mv $RPM_BUILD_ROOT{/sbin/dhcdbd,%{_sbindir}}
50
51 install %{SOURCE1} $RPM_BUILD_ROOT/etc/rc.d/init.d/dhcdbd
52
53 %clean
54 rm -rf $RPM_BUILD_ROOT
55
56 %post
57 /sbin/chkconfig --add dhcdbd
58 %service dhcdbd restart "DHCP D-BUS daemon"
59 if [ -f /var/lock/subsys/dhcdbd ]; then
60         echo "You will probably also need \"/sbin/service messagebus restart\""
61         echo "to reload the *.service database."
62 fi
63
64 %preun
65 if [ "$1" = "0" ]; then
66         %service dhcdbd stop
67         /sbin/chkconfig --del dhcdbd
68 fi
69
70 %files
71 %defattr(644,root,root,755)
72 %doc README LICENSE
73 %attr(755,root,root) %{_sbindir}/dhcdbd
74 %attr(754,root,root) /etc/rc.d/init.d/dhcdbd
75 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/dbus-1/system.d/dhcdbd.conf
76 %{_datadir}/dbus-1/services/dhcdbd.service
This page took 0.064833 seconds and 3 git commands to generate.