Bug 511204

Summary: Review Request: wicd - A wireless and wired network manager
Product: [Fedora] Fedora Reporter: Rangeen Basu Roy Chowdhury <sherry151>
Component: Package ReviewAssignee: Nobody's working on this, feel free to take it <nobody>
Status: CLOSED DUPLICATE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: medium Docs Contact:
Priority: medium    
Version: rawhideCC: cwickert, dcantrell, fedora-package-review, gareth.l.john, herrold, leigh123linux, lemenkov, notting, pablomg+fedora, promac, rootoutcast, sherry151, sundaram, tuju
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2010-05-20 11:25:11 EDT Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Bug Depends On: 510097    
Bug Blocks: 201449    
Attachments:
Description Flags
my wicd.spec none

Description Rangeen Basu Roy Chowdhury 2009-07-14 04:24:36 EDT
Spec URL: http://sherry151.fedorapeople.org/wicd.spec
SRPM URL: http://sherry151.fedorapeople.org/wicd-1.6.2-3.fc10.src.rpm

Description:  Complete network connection manager Wicd supports wired and wireless networks, and capable of creating and tracking profiles for both. It has a template-based wireless encryption system, which allows the user to easily add encryption methods used. It ships with some common encryption types, such as WPA and WEP. Wicd will automatically connect at startup to any preferred network within range.
Comment 1 Rangeen Basu Roy Chowdhury 2009-07-14 08:10:22 EDT
Modified spec file urlhttp://sherry151.fedorapeople.org/wicd/wicd.spec
Modified srpm
url:http://sherry151.fedorapeople.org/wicd/wicd-1.6.2-3.fc10.src.rpm

I wanted to preserve the original files and so changed the urls to point to new
files

Successful koji scratch builds:

F-10: http://koji.fedoraproject.org/koji/taskinfo?taskID=1472887
F-11: http://koji.fedoraproject.org/koji/taskinfo?taskID=1472992
F-12: http://koji.fedoraproject.org/koji/taskinfo?taskID=1472994
Comment 2 Paulo Roma Cavalcanti 2009-07-30 09:05:19 EDT
It does not build on x86_64.

/usr/lib is hardcoded in setup.py. Therefore,
%{_libdir} will install in the wrong place.


You can use 

 sed -i -e 's|/usr/lib|%{_libdir}|g' setup.py

to make it install in /usr/lib64,
but I do not understand why the source
want to install python scripts there.
Comment 3 Christoph Wickert 2009-07-30 09:10:45 EDT
The hardcoded /usr/lib/ is only used, when you don't pass %{_libdir} as an option:

%{__python} setup.py configure --distro=redhat \
  --lib=%{wicddir} \
  --share=%{_datadir}/%{name} \
  --etc=%{_sysconfdir}/%{name} \
  --bin=%{_bindir} \
  --sbin=%{_sbindir} \
  --mandir=%{_mandir} \
  --varlib=%{_sharedstatedir}/wicd \
  --pmutils=%{_libdir}/pm-utils/sleep.d \
  --resume=%{_sysconfdir}/acpi/resume.d \
  --suspend=%{_sysconfdir}/acpi/suspend.d \
  --docdir=%{_docdir}/%{name}-%{version} \
  --no-install-kde \
  --no-install-docs

... and everything is fine.
Comment 4 Christoph Wickert 2009-07-30 09:11:34 EDT
Sorry, I forgot to mention, that I defined %{wicddir} as

%global wicddir %{_prefix}/lib/%{name}
Comment 5 Christoph Wickert 2009-07-30 09:13:09 EDT
Created attachment 355670 [details]
my wicd.spec

I packaged wicd last weekend, just before I found this review. Attaching my spec, take what you need from it.
Comment 6 Paulo Roma Cavalcanti 2009-07-30 10:11:02 EDT
(In reply to comment #5)
> Created an attachment (id=355670) [details]
> my wicd.spec
> 
> I packaged wicd last weekend, just before I found this review. Attaching my
> spec, take what you need from it.  

python-setuptools is version 0.6c9 on F10. Therefore, you should not use a
versioned

BuildRequires: python-setuptools-devel >= 2.4

Also you do not need %dir for claiming ownership, and you should exclude
any useless egg-info.
This is enough, I guess.

%{wicddir}
%{_datadir}/applications/wicd.desktop
%{_datadir}/icons/hicolor/*/apps/wicd-*.*
%{_datadir}/pixmaps/wicd
%{_datadir}/wicd
%{_mandir}/man*/wicd*.gz
%{_sharedstatedir}/wicd

# For noarch packages: sitelib
%{python_sitelib}/%{name}
%exclude %{python_sitelib}/*.egg-info

and why did you comment the noarch?
Comment 7 Christoph Wickert 2009-07-30 10:36:45 EDT
(In reply to comment #6)

> python-setuptools is version 0.6c9 on F10. Therefore, you should not use a
> versioned
> 
> BuildRequires: python-setuptools-devel >= 2.4

You are correct. I thought python-setuptools was built as a subpackage of python, but it's not. I wanted to require python >= 2.4

> Also you do not need %dir for claiming ownership, 

What %dir statement are you referring to?

The first one is used to prevent accidentally packaging unwanted files in %{wicddir} and %{wicddir}/backends. We just want python files there. If you just use %{wicddir}, you wont realize if you accidentally include other files due to a bad setup.py or a bad tarball.

The other %dir statements in %{_sharedstatedir} are not really needed from a technical POV, but from a human one. Other packagers should be able to see that these dirs are empty from a glance at the spec.

> and you should exclude any useless egg-info.

Why is it useless? Are you familiar with
https://fedoraproject.org/wiki/Packaging/Python/Eggs

> %{python_sitelib}/%{name}
> %exclude %{python_sitelib}/*.egg-info

Please don't use excludes, as the break rpm's size calculation.

> and why did you comment the noarch?  

The package itself is noarch, but it cannot be packaged noarch as it puts the pm-utils script into %{_libdir}. I suggest to package them as a arch'ed subpackage so the main wicd package can be noarch.

I also suggest to package the GUI and the TUI separately. It would be cool to have a wireless config tool without X and it would allow users of the GUI to install wicd without python-urwid.
Comment 8 Paulo Roma Cavalcanti 2009-07-30 11:00:49 EDT
(In reply to comment #7)
> (In reply to comment #6)
> 

> 
> > and you should exclude any useless egg-info.
> 
> Why is it useless? Are you familiar with
> https://fedoraproject.org/wiki/Packaging/Python/Eggs
> 
> > %{python_sitelib}/%{name}
> > %exclude %{python_sitelib}/*.egg-info
> 
> Please don't use excludes, as the break rpm's size calculation.
> 
>

Thanks for the explanation.

Have you tested wicd? I am having a lot of disconnections/password re-entering
when using NetworkManager on one of my netbooks. 
Do you think wicd can help in this case (I saw some posts
stating that)?
Comment 9 Christoph Wickert 2009-07-30 11:17:58 EDT
NetworkManager works fine here, no complainants except that it requires a lot of Gnome stuff. This is why I was looking for alternatives for my upcoming LXDE spin. I know many LXDE users use it, so I gave it a try.

First I was very disappointed, because I could not get it to work with WPA/WPA2 encryption. Others confirmed that there were issues and they had to connect several times until it worked. But since 1.5.8 it seems these problems have been solved. I'm using 1.5.9 now for a nearly three weeks and it has always worked flawlessly. The only issue is that it does not work with SELinux currently.

I'm going to review this package when Rangeen gives us an updated spec. I really like to see this in Fedora ASAP, but first we need to fix selinux-policy-targeted.
Comment 10 Paulo Roma Cavalcanti 2009-07-30 22:21:19 EDT
wicd is working just fine for me with WPA.

I just had to enter my password a single time, and it
reconnects without my intervention.

It seems it will be a very strong concurrent to NetworkManager.

The only thing is that it brings the tray icon even without
a running copy of wicd.
Comment 11 Rangeen Basu Roy Chowdhury 2009-08-09 02:00:25 EDT
> 
> I'm going to review this package when Rangeen gives us an updated spec. I
> really like to see this in Fedora ASAP, but first we need to fix
> selinux-policy-targeted.  

Please take up the this package as I am not able to dedicate enough time towards packaging and Fedora in general ( Little busy with my job). You can put me as a co maintainer. If you want I can also review the package at some point of time. By the way, if this package can wait for some time then I will take up the task after some time, once I have sufficient time.
Comment 12 leigh scott 2009-10-04 08:26:20 EDT
(In reply to comment #9)
> NetworkManager works fine here, no complainants except that it requires a lot
> of Gnome stuff. This is why I was looking for alternatives for my upcoming LXDE
> spin. I know many LXDE users use it, so I gave it a try.
> 
> First I was very disappointed, because I could not get it to work with WPA/WPA2
> encryption. Others confirmed that there were issues and they had to connect
> several times until it worked. But since 1.5.8 it seems these problems have
> been solved. I'm using 1.5.9 now for a nearly three weeks and it has always
> worked flawlessly. The only issue is that it does not work with SELinux
> currently.
> 
> I'm going to review this package when Rangeen gives us an updated spec. I
> really like to see this in Fedora ASAP, but first we need to fix
> selinux-policy-targeted.  


There is a bugreport for the selinux issue.

https://bugzilla.redhat.com/show_bug.cgi?id=481511
Comment 13 Rahul Sundaram 2009-10-04 14:14:36 EDT
That bug report seems to be resolved with an updated policy. If it is not working for anyone yet, they should add comments to the bug report.
Comment 14 Fabian Affolter 2009-12-21 12:03:58 EST
*** Bug 546138 has been marked as a duplicate of this bug. ***
Comment 15 Gareth John 2010-02-26 12:32:22 EST
(In reply to comment #11)
> > 
> > I'm going to review this package when Rangeen gives us an updated spec. I
> > really like to see this in Fedora ASAP, but first we need to fix
> > selinux-policy-targeted.  
> 
> Please take up the this package as I am not able to dedicate enough time
> towards packaging and Fedora in general ( Little busy with my job). You can put
> me as a co maintainer. If you want I can also review the package at some point
> of time. By the way, if this package can wait for some time then I will take up
> the task after some time, once I have sufficient time.    

I will offer help in anyway if anybody would like it. May be work together on spec and co-maintain? I will await for any updates.
Comment 16 Gareth John 2010-02-26 12:57:17 EST
Under files section:
%{_icondir}/hicolor/??x??/apps/wicd-client.png
%{_icondir}/hicolor/128x128/apps/wicd-client.png
%{_icondir}/hicolor/192x192/apps/wicd-client.png
%{_icondir}/hicolor/scalable/apps/wicd-client.svg

Should be:

%{_icondir}/hicolor/*/apps/wicd-client.*

or possibly: 

%{_icondir}/hicolor/*/apps/%{name}*

As for the use of tags there are quite a few files I would use name tag on myself. 

I will play with the spec later and produce an updated one that gives effect to all comments on file.
Comment 17 Gareth John 2010-05-06 10:12:46 EDT
(In reply to comment #11)
> > 
> > I'm going to review this package when Rangeen gives us an updated spec. I
> > really like to see this in Fedora ASAP, but first we need to fix
> > selinux-policy-targeted.  
> 
> Please take up the this package as I am not able to dedicate enough time
> towards packaging and Fedora in general ( Little busy with my job). You can put
> me as a co maintainer. If you want I can also review the package at some point
> of time. By the way, if this package can wait for some time then I will take up
> the task after some time, once I have sufficient time.    

http://gljohn.fedorapeople.org/wicd/wicd.spec
http://gljohn.fedorapeople.org/wicd/wicd-1.7.0-4.fc12.src.rpm

I have updated to version 1.7.0 and modified the files as required. I have also used glob and macros to remove excessive file lines. I have never package a python package before and i have just picked up and modified the current one in this review. Having looked at the python packaging guide I'm not sure if the spec file used is acceptable.
Comment 18 Chen Lei 2010-05-20 05:21:34 EDT
*** Bug 593841 has been marked as a duplicate of this bug. ***
Comment 19 leigh scott 2010-05-20 05:38:34 EDT
(In reply to comment #18)
> *** Bug 593841 has been marked as a duplicate of this bug. ***    

Why close 593841 ?

I believe  Gareth John should submit a fresh review and this old review closed.
Comment 20 Christoph Wickert 2010-05-20 07:38:45 EDT
When somebody starts a new approach to package this:
- Please take care of the noarch/arch problem with %{_libdir}/pm-utils
- Please CC me to the new review request.
Comment 21 David Cantrell 2010-05-20 11:25:11 EDT

*** This bug has been marked as a duplicate of bug 593841 ***