source: projects/specs/branches/6/w/wicd/wicd-vl.spec @ 6439

Revision 6439, 8.0 KB checked in by kudoh, 12 years ago (diff)
RevLine 
[1161]1#define python_sitelib %(%{__python} -c 'from distutils import sysconfig; print sysconfig.get_python_lib(1)')
[1156]2
3Summary: A wireless and wired network manager
4Summary(ja): 無線・有線ネットワークマネージャ
5Name: wicd
[6439]6Version: 1.7.2.4
[5677]7Release: 1%{?_dist_release}
8Source0: %{name}-%{version}.tar.gz
9Patch0:  wicd-desktop.patch
10Patch1:  02-workaround_dhclient_bug.patch
[6439]11#Patch2:  26-support_etc-network_scripts.patch
12Patch3: 770_769.diff
[5677]13Patch100: add_fix_ja.patch
[1156]14
15License: GPLv2
16Group: System Environment/Base
17BuildRoot: %{_tmppath}/%{name}-%{version}-root
[6439]18URL: https://launchpad.net/wicd
[3932]19BuildArch: noarch
[1156]20
21BuildRequires: gettext
22BuildRequires: desktop-file-utils
23BuildRequires: python >= 2.4 python-devel >= 2.4
[5677]24BuildRequires: python-babel
[1156]25BuildRequires: python-setuptools
26
[3932]27Requires: pm-utils >= 1.2.4
[1156]28
[6439]29Requires: %{name}-common
30Requires: %{name}-curses
31Requires: %{name}-gtk
32
[3932]33#Requires(post):   chkconfig
34#Requires(preun):  chkconfig
35#Requires(preun):  /sbin/service
36#Requires(postun): /sbin/service
[1156]37
38Conflicts: NetworkManager
39
40%description
41A complete network connection manager
42Wicd supports wired and wireless networks, and capable of
43creating and tracking profiles for both.  It has a
44template-based wireless encryption system, which allows the user
45to easily add encryption methods used.  It ships with some common
46encryption types, such as WPA and WEP. Wicd will automatically
47connect at startup to any preferred network within range.
48
[3932]49%package common
50Summary: Wicd common files
51Summary(ja): Wicd の共通ファイル
52Group: System Environment/Base
53BuildArch: noarch
54Requires: dbus
55Requires: dbus-python
56Requires: dhclient
57Requires: ethtool
58Requires: iproute
59Requires: logrotate
60Requires: net-tools
61Requires: pm-utils
62Requires: wireless-tools
63Requires: wpa_supplicant
[1156]64
[3932]65Requires(post):   chkconfig
66Requires(preun):  chkconfig
67Requires(preun):  /sbin/service
68Requires(postun): /sbin/service
69#Requires(preun):  initscripts
70#Requires(postun): initscripts
71
72%description common
73This package provides the main wicd daemon and the wicd-cli front-end.
74
75%package curses
76Summary: Curses client for Wicd
77Summary(ja): Wicd の Curse クライアント
78Group: Applications/System
79BuildArch: noarch
80Requires: %{name}-common = %{version}-%{release}
81Requires: python-urwid >= 0.9.8.3
82
83%description curses
84Client program for wicd that uses a curses interface.
85
86%package gtk
87Summary: GTK+ client for Wicd
88Summary(ja): Wicd の GTK+ クライアント
89Group: Applications/Internet
90BuildArch: noarch
91Requires: %{name}-common = %{version}-%{release}
92Requires: pygtk2 >= 2.10
93Requires: pygtk2-libglade >= 2.10
94Requires: gksu
95
96%description gtk
97Client program for wicd that uses a GTK+ interface.
98
99
[1156]100%prep
101%setup -q
[5677]102%patch0 -p1
[1156]103%patch1 -p1
[6439]104#%patch2 -p1
105%patch3 -p0
[5677]106%patch100 -p1
[1156]107
108%{__sed} -i 's/\r//' wicd/logfile.py
109
110%build
[5677]111python setup.py compile_translations
112
[1156]113%{__python} setup.py configure --share=%{_datadir}/%{name} \
114       --etc=%{_sysconfdir}/%{name} \
115       --bin=%{_bindir} \
116       --sbin=%{_sbindir} \
117       --mandir=%{_mandir} \
118       --varlib=%{_sharedstatedir}/wicd \
119       --pmutils=%{_libdir}/pm-utils/sleep.d \
120       --resume=%{_sysconfdir}/acpi/resume.d \
121       --suspend=%{_sysconfdir}/acpi/suspend.d \
122       --docdir=%{_docdir}/%{name}-%{version} \
[3932]123       --log %{_localstatedir}/log \
[1156]124       --no-install-kde \
125       --no-install-docs
126
127python setup.py build
[6439]128# python-babel currently doesn't support Asturian, using gettext
129msgfmt po/ast.po -o translations/ast/LC_MESSAGES/wicd.mo
[1156]130
131%install
132rm -rf %{buildroot}
133python setup.py install -O1 --skip-build --root=%{buildroot}
134install -D init/redhat/%{name} %{buildroot}%{_initddir}/%{name}
135
[3932]136find %{buildroot} -type f -name ".empty_on_purpose" | xargs rm
[1156]137
[3932]138desktop-file-install \
139    --remove-category="Application" \
140    --delete-original \
141    --dir=%{buildroot}%{_datadir}/applications \
142    %{buildroot}%{_datadir}/applications/wicd.desktop
143
144desktop-file-install \
145    --dir=%{buildroot}%{_sysconfdir}/xdg/autostart \
146    %{buildroot}%{_sysconfdir}/xdg/autostart/wicd-tray.desktop
147
[1156]148%find_lang %{name}
149
[3932]150%post common
[1156]151touch --no-create %{_datadir}/icons/hicolor &>/dev/null || :
[1178]152/sbin/service %{name} restart >/dev/null 2>&1
[1156]153/sbin/chkconfig --add %{name}
[1178]154/sbin/chkconfig --level 345 %{name} on
[1156]155
[3932]156%preun common
[1156]157if [ $1 = 0 ] ; then
158     /sbin/service %{name} stop >/dev/null 2>&1
159     /sbin/chkconfig --del %{name}
160fi
161
[3932]162%postun common
[1156]163if [ "$1" -ge "1" ] ; then
164    /sbin/service %{name} condrestart >/dev/null 2>&1 || :
165fi
166
167if [ $1 -eq 0 ] ; then
168    touch --no-create %{_datadir}/icons/hicolor &>/dev/null
169    gtk-update-icon-cache %{_datadir}/icons/hicolor &>/dev/null || :
170fi
171
[3932]172%post gtk
173touch --no-create %{_datadir}/icons/hicolor &>/dev/null || :
174
175%postun gtk
176if [ $1 -eq 0 ]; then
177    touch --no-create %{_datadir}/icons/hicolor &>/dev/null
178    gtk-update-icon-cache %{_datadir}/icons/hicolor &>/dev/null || :
179fi
180
181%posttrans gtk
[1156]182gtk-update-icon-cache %{_datadir}/icons/hicolor &>/dev/null || :
183
184%clean
185[ -d "$RPM_BUILD_ROOT" -a "$RPM_BUILD_ROOT" != "/" ] && rm -rf $RPM_BUILD_ROOT
186
[3932]187%files
[1156]188%defattr(-,root,root)
189%doc AUTHORS CHANGES INSTALL LICENSE NEWS README other/WHEREAREMYFILES
[5677]190%{_libdir}/pm-utils/sleep.d/55wicd
[3932]191
192%files common -f %{name}.lang
193%{_bindir}/wicd-cli
194%{_bindir}/wicd-client
[1156]195%{python_sitelib}/wicd
196%{python_sitelib}/*.egg-info
197%{_datadir}/applications/wicd.desktop
[5677]198%{_datadir}/dbus-1/system-services/
[3932]199%{_datadir}/man/man1/wicd-client.1*
200%{_datadir}/man/man5/wicd-manager-settings.conf.5*
201%{_datadir}/man/man5/wicd-wired-settings.conf.5*
202%{_datadir}/man/man5/wicd-wireless-settings.conf.5*
203%{_datadir}/man/man8/wicd-cli.8*
204%{_datadir}/man/man8/wicd.8*
205%{_datadir}/pixmaps/wicd*
206%dir %{_datadir}/wicd
207%dir %{_datadir}/wicd/backends
208%dir %{_datadir}/wicd/cli
209%dir %{_datadir}/wicd/daemon
210%{_datadir}/wicd/backends/*
211%{_datadir}/wicd/cli/*
212%{_datadir}/wicd/daemon/*
[5677]213%{_mandir}/nl/man?/%{name}*
[1156]214%{_sysconfdir}/%{name}
215%{_sysconfdir}/acpi/resume.d/80-wicd-connect.sh
216%{_sysconfdir}/acpi/suspend.d/50-wicd-suspend.sh
217%{_sysconfdir}/dbus-1/system.d/wicd.conf
[5677]218%{_sysconfdir}/logrotate.d/
[1156]219%{_sysconfdir}/rc.d/init.d/wicd
220%{_sysconfdir}/xdg/autostart/wicd-tray.desktop
221%{_sbindir}/wicd
222%{_localstatedir}/lib/wicd
[5677]223%exclude /lib/systemd/system/wicd.service
[1156]224
[3932]225%files curses
226%defattr(-,root,root,-)
227%dir %{_datadir}/wicd/curses
228%{_datadir}/wicd/curses/*
229%{_bindir}/wicd-curses
230%{_datadir}/man/man8/wicd-curses.8*
231%lang(nl) %{_datadir}/man/nl/man8/wicd-curses.8*
232
233%files gtk
234%defattr(-,root,root,-)
235%dir %{_datadir}/wicd/gtk
236%dir %{_datadir}/pixmaps/wicd
237%{_sysconfdir}/xdg/autostart/wicd-tray.desktop
238%{_datadir}/wicd/gtk/*
239%{_datadir}/pixmaps/wicd/*
240%{_datadir}/pixmaps/wicd-gtk.xpm
241%{_bindir}/wicd-gtk
242%{_datadir}/icons/hicolor/*/apps/wicd-gtk.png
243%{_datadir}/icons/hicolor/scalable/apps/wicd-gtk.svg
244
[1156]245%changelog
[6439]246* Sat May 05 2012 Toshiharu Kudoh <toshi.kd2@gmail.com> - 1.7.2.4-1
247- new upstream release
248- dropt patch2
249- added Patch3 from upstream
250- fixed patch100
251- added Requires: %%{name}-common, %%{name}-curses %%{name}-gtk in wicd
252- changed URL: https://launchpad.net/wicd
253
[5677]254* Sat Feb 18 2012 Toshiharu Kudoh <toshi.kd2@gmail.com> - 1.7.1-1
255- dropt almost pathces
256  - enabled patch is wicd-desktop.patch (Patch0)
257- added patch1 and patch2 from Debian sid
258- added patch100 to fix Japanese translation
259- added BuildRequires: python-babel
260
[3932]261* Sun May 22 2011 Toshiharu Kudoh <toshi.kd2@gmail.com> - 1.7.0-6
262- changed BuildArch to noarch
263- updated spec
264- splitted -common, -curses, -gtk packages
265- Added Patch4,5,6,7,8 from Debian
266
[1178]267* Wed Jun 9 2010 Toshiharu Kudoh <toshi.kd2@gmail.com> - 1.7.0-5
268- improved service start process in %%post section
269- changed daemon start runlevel
270
[1161]271* Mon Jun 07 2010 Shu KONNO <owa@bg.wakwak.com> - 1.7.0-4
272- fixed %%python_sitelib
273
[1156]274* Sat Jun 5 2010 Toshiharu Kudoh <toshi.kd2@gmail.com> - 1.7.0-3
275- added Rerquires: gksu
276- added Patch2,3 from Debian
277  - to stop running unexpected files in scripts
278  - to fix resolv.conf permission
279
280* Fri Jun 4 2010 Toshiharu Kudoh <toshi.kd2@gmail.com> - 1.7.0-2
281- added chkconfig in %post
282- added Patch1 to add Japanese description for desktop file
283
284* Fri May 28 2010 Toshiharu Kudoh <toshi.kd2@gmail.com> - 1.7.0-1
285- initial build for VineSeed
Note: See TracBrowser for help on using the repository browser.