]> git.pld-linux.org Git - packages/ifplugd.git/blob - ifplugd.spec
- fix permissions
[packages/ifplugd.git] / ifplugd.spec
1 Summary:        Detect and perform actions when an ethernet cable is (un)plugged
2 Summary(pl):    Wykrywanie pod³±czenia/od³±czenia kabla ethernetowego i podejmowanie dzia³añ z tym zwi±zanych
3 Name:           ifplugd
4 Version:        0.16
5 Release:        1
6 Source0:        http://www.stud.uni-hamburg.de/~lennart/projects/ifplugd/ifplugd-0.16.tar.gz
7 # Source0-md5:  56b920b51b05949f8a729e8c3e13ba70
8 Source1:        %{name}.init
9 License:        GPL
10 Group:          Networking
11 URL:            http://www.stud.uni-hamburg.de/users/lennart/projects/ifplugd/
12 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
13 BuildRequires:  libdaemon-devel >= 0.2
14 BuildRequires:  lynx
15
16 %define         _sbindir        /sbin
17
18 %description
19 ifplugd is a Linux daemon which will automatically configure your
20 ethernet device when a cable is plugged in and automatically
21 unconfigure it if the cable is pulled. This is useful on laptops with
22 onboard network adapters, since it will only configure the interface
23 when a cable is really connected.
24
25 %description -l pl
26 ifplugd jest demonem linuksowym, który automatycznie konfiguruje kartê
27 sieciow± ethernet w chwili pod³±czenia do niej kabla i automatycznie
28 usuwa jej konfiguracjê, gdy kabel jest od³±czany. Przydaje siê to w
29 laptopach z kart± sieciow± na p³ycie, gdy¿ powoduje to skonfigurowanie
30 interfejsu tylko wtedy, gdy kabel jest rzeczywi¶cie pod³±czony.
31
32 %prep
33 %setup -q
34
35 %build
36 %configure
37 %{__make}
38
39 %install
40 rm -rf $RPM_BUILD_ROOT
41 install -d $RPM_BUILD_ROOT/etc/rc.d/init.d
42
43 %{__make} install \
44         DESTDIR=$RPM_BUILD_ROOT
45
46 install %{SOURCE1} $RPM_BUILD_ROOT/etc/rc.d/init.d/%{name}
47
48 %clean
49 rm -rf $RPM_BUILD_ROOT
50
51 %post
52 /sbin/chkconfig --add %{name}
53 if [ -f /var/lock/subsys/%{name} ]; then
54         /etc/rc.d/init.d/%{name} restart 1>&2
55 else
56         echo "Run \"/etc/rc.d/init.d/%{name} start\" to start %{name} service."
57 fi
58
59 %preun
60 if [ "$1" = "0" ]; then
61         if [ -f /var/lock/subsys/%{name} ]; then
62                 /etc/rc.d/init.d/%{name} stop 1>&2
63         fi
64         /sbin/chkconfig --del %{name}
65 fi
66
67 %files
68 %defattr(644,root,root,755)
69 %doc doc/README doc/NEWS doc/README.html doc/style.css
70 %attr(755,root,root) %{_sbindir}/*
71 %{_mandir}/man?/*
72 %attr(754,root,root) /etc/rc.d/init.d/%{name}
73 %dir %{_sysconfdir}/ifplugd
74 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/ifplugd/ifplugd.conf
75 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/ifplugd/ifplugd.action
76
77 # end of file
This page took 0.075194 seconds and 3 git commands to generate.