]> git.pld-linux.org Git - packages/wicd.git/blob - wicd.spec
- up to 1.7.0
[packages/wicd.git] / wicd.spec
1 # TODO
2 # - fix pm-utils to store addons in non-arch dependant path so we could make this pkg noarch
3 # - package (acpid-XXX):
4 #   /etc/acpi/resume.d/80-wicd-connect.sh
5 #   /etc/acpi/suspend.d/50-wicd-suspend.sh
6 # - now python libraries installs into /usr/share/wicd by default, so I commented libexecdir redefinition. but its now easy to revert and change install behaviour simply uncomenting it
7 # - translations installing is broken. fr and FR both exists, hack with renaming doesnt work for hr_HR and ar_PS isnt in glibc yet. something is really fucked up, because I cannot find fr_FR nowhere in source dir (find + grep), but instalation creates empty dirs that break installation later :/
8
9 Summary:        wired and wireless network manager
10 Summary(pl.UTF-8):      Zarządca sieci przewodowych i bezprzewodowych
11 Name:           wicd
12 Version:        1.7.0
13 Release:        0.1
14 License:        GPL v2
15 Group:          X11/Applications/Networking
16 Source0:        http://dl.sourceforge.net/wicd/%{name}-%{version}.tar.gz
17 # Source0-md5:  003d2e67240989db55934553437ba32a
18 Source1:        %{name}.init
19 Patch0:         %{name}-init_status.patch
20 Patch1:         bashism.patch
21 URL:            http://www.wicd.net/
22 # /etc/pld-release used to detect platform
23 BuildRequires:  issue
24 BuildRequires:  python-devel
25 BuildRequires:  python-modules
26 BuildRequires:  rpm-pythonprov
27 BuildRequires:  rpmbuild(macros) >= 1.228
28 BuildRequires:  sed >= 4.0
29 Requires(post,preun):   /sbin/chkconfig
30 Requires:       dbus(org.freedesktop.Notifications)
31 Requires:       python-dbus
32 Requires:       python-iwscan
33 Requires:       python-pygobject
34 Requires:       python-pygtk-glade >= 2:2.0
35 Requires:       python-pygtk-gtk >= 2:2.0
36 Requires:       python-wpactrl
37 # not noarch due pm-utils packaging stupidity
38 #BuildArch:     noarch
39 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
40
41 #%define                _libexecdir     %{_prefix}/lib/%{name}
42
43 %description
44 Wicd is an open source wired and wireless network manager for Linux
45 which aims to provide a simple interface to connect to networks with a
46 wide variety of settings.
47
48 %description -l pl.UTF-8
49 Wicd jest zarządcą sieci przewodowych i bezprzewodowych dla Linuksa,
50 mającym zapewnić prosty interfejs do podłączania do sieci z
51 różnorakimi opcjami.
52
53 %package client-cli
54 Summary:        wicd CLI client
55 Summary(pl.UTF-8):      klient wicd CLI
56 Group:          Applications/System
57 Requires:       %{name} = %{version}-%{release}
58 Requires:       python-urwid
59
60 %description client-cli
61 Wicd command line interface (ncurses) client.
62
63 %description client-cli -l pl.UTF-8
64 Klient wicd z międzymordziem wiersza poleceń (ncurses).
65
66 %package client-curses
67 Summary:        wicd TUI client
68 Summary(pl.UTF-8):      klient wicd z TUI
69 Group:          Applications/System
70 Requires:       %{name} = %{version}-%{release}
71
72 %description client-curses
73 Wicd text user interface (ncurses) client.
74
75 %description client-curses -l pl.UTF-8
76 Klient Wicd z tesktowym międzymordziem uzytkownika (ncurses).
77
78 %package client-gtk
79 Summary:        wicd GUI client
80 Summary(pl.UTF-8):      klient wicd z GUI
81 Group:          Applications/System
82 Requires:       %{name} = %{version}-%{release}
83
84 %description client-gtk
85 Wicd graphical user interface (GTK+2) client.
86
87 %description client-gtk -l pl.UTF-8
88 Klient Wicd z graficznym międzymordziem użytkownika (GTK+2).
89
90 %package -n pm-utils-wicd
91 Summary:        wicd script for pm-utils
92 Summary(pl.UTF-8):      Skrypt wicd dla pm-utils
93 Group:          Applications/System
94 Requires:       %{name} = %{version}-%{release}
95 Requires:       pm-utils
96
97 %description -n pm-utils-wicd
98 Wicd script for pm-utils.
99
100 %description -n pm-utils-wicd -l pl.UTF-8
101 Skrypt wicd dla pm-utils.
102
103 %prep
104 %setup -q
105 %patch0 -p1
106 %patch1 -p1
107
108 mv translations/{ar_EG,ar} # WTF? Then what do with ar_PS?
109 rm -rf translations/ar_PS # so removing it temporary until somebody put those dirs into glibc
110 mv translations/{de_DE,de}
111 mv translations/{es_ES,es}
112 rm -rf translations/fr
113 mv translations/{fr_FR,fr} # We got serious problem there, because both fr and fr_FR exsists and differs
114 #mv translations/{hr_HR,hr} # Doesnt work for me
115 mv translations/{it_IT,it}
116 mv translations/{nl_NL,nl}
117 mv translations/{no,nb}
118 mv translations/{ru_RU,ru}
119
120 grep -r bin/env.*python -l . | xargs sed -i -e '1s,^#!.*env python,#!%{__python},'
121
122 %build
123 %{__python} setup.py configure \
124         --backends %{_libexecdir}/backends \
125         --cli %{_libexecdir}/cli \
126         --curses %{_libexecdir}/curses \
127         --daemon %{_libexecdir}/daemon \
128         --gtk %{_libexecdir}/gtk \
129         --pidfile /var/run/wicd.pid \
130         --pmutils %{_libdir}/pm-utils/sleep.d
131
132 %{__python} setup.py build
133
134 %install
135 rm -rf $RPM_BUILD_ROOT
136 %{__python} setup.py install \
137         --optimize=2 \
138         --root=$RPM_BUILD_ROOT
139
140 install -p %{SOURCE1} $RPM_BUILD_ROOT/etc/rc.d/init.d/wicd
141
142 %py_ocomp $RPM_BUILD_ROOT%{py_sitedir}
143 %py_comp $RPM_BUILD_ROOT%{py_sitedir}
144 %py_postclean
145
146 %find_lang %{name}
147
148 rm -rf $RPM_BUILD_ROOT%{_docdir}/%{name}
149
150 %clean
151 rm -rf $RPM_BUILD_ROOT
152
153 %post
154 /sbin/chkconfig --add %{name}
155 %service %{name} restart
156
157 %preun
158 if [ "$1" = "0" ]; then
159         %service -q %{name} stop
160         /sbin/chkconfig --del %{name}
161 fi
162
163 %files -f %{name}.lang
164 %defattr(644,root,root,755)
165 %doc AUTHORS CHANGES INSTALL README
166 %attr(755,root,root) %{_bindir}/wicd-client
167 %attr(755,root,root) %{_sbindir}/wicd
168 %attr(754,root,root) /etc/rc.d/init.d/%{name}
169 %{_mandir}/man5/wicd-manager-settings.conf.5*
170 %lang(nl) %{_mandir}/nl/man5/wicd-manager-settings.conf.5*
171 %{_mandir}/man5/wicd-wired-settings.conf.5*
172 %lang(nl) %{_mandir}/nl/man5/wicd-wired-settings.conf.5*
173 %{_mandir}/man5/wicd-wireless-settings.conf.5*
174 %lang(nl) %{_mandir}/nl/man5/wicd-wireless-settings.conf.5*
175 %{_mandir}/man8/wicd.8*
176 %lang(nl) %{_mandir}/nl/man8/wicd.8*
177 /etc/dbus-1/system.d/wicd.conf
178 %{_sysconfdir}/wicd
179 %{_sysconfdir}/xdg/autostart/wicd-tray.desktop
180 %dir %{_libexecdir}
181 %dir %{_libexecdir}/backends
182 %attr(755,root,root) %{_libexecdir}/backends/*.py
183 %dir %{_libexecdir}/daemon
184 %attr(755,root,root) %{_libexecdir}/daemon/*.py
185 %dir %{py_sitescriptdir}/wicd
186 %{py_sitescriptdir}/wicd/*.py[co]
187 %{py_sitescriptdir}/Wicd-*.egg-info
188 %dir /var/lib/%{name}
189 /var/lib/%{name}/WHEREAREMYFILES
190 %dir /var/log/%{name}
191
192 %files client-cli
193 %defattr(644,root,root,755)
194 %attr(755,root,root) %{_bindir}/wicd-cli
195 %dir %{_libexecdir}/cli
196 %attr(755,root,root) %{_libexecdir}/cli/*.py
197 %{_mandir}/man8/wicd-cli.8*
198
199 %files client-curses
200 %defattr(644,root,root,755)
201 %attr(755,root,root) %{_bindir}/wicd-curses
202 %dir %{_libexecdir}/curses
203 %attr(755,root,root) %{_libexecdir}/curses/*.py
204 %{_mandir}/man8/wicd-curses.8*
205 %lang(nl) %{_mandir}/nl/man8/wicd-curses.8*
206
207 %files client-gtk
208 %defattr(644,root,root,755)
209 %attr(755,root,root) %{_bindir}/wicd-gtk
210 %dir %{_libexecdir}/gtk
211 %{_libexecdir}/gtk/%{name}.glade
212 %attr(755,root,root) %{_libexecdir}/gtk/*.py
213 %{_datadir}/autostart/wicd-tray.desktop
214 %{_desktopdir}/wicd.desktop
215 %{_iconsdir}/hicolor/*/apps/wicd-gtk.*
216 %{_pixmapsdir}/%{name}
217 %{_pixmapsdir}/wicd-gtk.xpm
218 %{_mandir}/man1/wicd-client.1*
219 %lang(nl) %{_mandir}/nl/man1/wicd-client.1*
220
221 %files -n pm-utils-wicd
222 %defattr(644,root,root,755)
223 %attr(755,root,root) %{_libdir}/pm-utils/sleep.d/*wicd
This page took 0.073626 seconds and 3 git commands to generate.