Bug 480125 - hamlib-python: _Hamlib.so is installed in bad place
hamlib-python: _Hamlib.so is installed in bad place
Status: CLOSED NEXTRELEASE
Product: Fedora
Classification: Fedora
Component: hamlib (Show other bugs)
10
i386 Linux
low Severity high
: ---
: ---
Assigned To: Denis Leroy
Fedora Extras Quality Assurance
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2009-01-15 04:35 EST by Pavel Stárek (CZ)
Modified: 2009-04-06 16:32 EDT (History)
6 users (show)

See Also:
Fixed In Version: 1.2.8-3.fc10
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2009-04-06 16:32:18 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)
patch for hamlib spec file (898 bytes, patch)
2009-03-12 10:21 EDT, Pavel Stárek (CZ)
no flags Details | Diff

  None (edit)
Description Pavel Stárek (CZ) 2009-01-15 04:35:13 EST
Description of problem:
The package hamlib-python needs _Hamlib.so file, which is in the package hamlib, but this file is located in /usr/lib, instead of being located in the /usr/lib/python2.5/site-packages. So after you install a package hamlib and hamlib-python is not possible in the Python script execute command "import Hamlib". This ends with an ImportError exception message: No module named _Hamlib. Manually copying the file /usr/lib/_Hamlib.so to directory /usr/lib/python2.5 can be done Hamlib import command.

Version-Release number of selected component (if applicable):
hamlib-1.2.7-2.fc10.i386.rpm
hamlib-python-1.2.7-2.fc10.i386.rpm

How reproducible:
Allways

Steps to Reproduce:
1. yum install hamlib hamlib-python
2. start terminal and python interpreter
3. enter command import Hamlib
  
Actual results:
ImportError: no module named _Hamlib

Expected results:
correctly imported Hamlib python extension (binding) and _Hamlib.so place in package hamlib-python.

Additional info:
As I see, same things may occur in hamlib-1.2.8 vhich is in updates testing.
Comment 1 Pavel Stárek (CZ) 2009-01-16 04:43:08 EST
Correction:

Manually copying the file /usr/lib/_Hamlib.so to directory
/usr/lib/python2.5/site-packages can be done Hamlib import command.
Comment 2 Sindre Pedersen Bjørdal 2009-03-09 13:54:44 EDT
Do the _Hamlib.so file need to be at both places? Can this be solved by a symlink?
Comment 3 Pavel Stárek (CZ) 2009-03-12 10:19:04 EDT
(In reply to comment #2)
> Do the _Hamlib.so file need to be at both places? Can this be solved by a
> symlink?  

No, not required on both places. This file should be placed only in /usr/lib/python2.5/site-packages . So, i perform some research today, and creating a symlink is now the best way how to correct this. While this is not the best solution, but for the right solution (as I think) it is necessary to carry out some research/hack of the Makefiles. I have a myself edited spec file which adds a python package postinstall and postuninstall things to create/delete symlink, and patch for original one is in attachment.
Comment 4 Pavel Stárek (CZ) 2009-03-12 10:21:57 EDT
Created attachment 334931 [details]
patch for hamlib spec file

This file adds post and postun oneliners for creating/removing symbolic link of _Hamlib.so file into Python's site-packages dir.
Comment 5 Fedora Update System 2009-04-01 13:41:52 EDT
hamlib-1.2.8-3.fc10 has been submitted as an update for Fedora 10.
http://admin.fedoraproject.org/updates/hamlib-1.2.8-3.fc10
Comment 6 Fedora Update System 2009-04-02 13:17:50 EDT
hamlib-1.2.8-3.fc10 has been pushed to the Fedora 10 testing repository.  If problems still persist, please make note of it in this bug report.
 If you want to test the update, you can install it with 
 su -c 'yum --enablerepo=updates-testing update hamlib'.  You can provide feedback for this update here: http://admin.fedoraproject.org/updates/F10/FEDORA-2009-3239
Comment 7 Fedora Update System 2009-04-06 16:32:13 EDT
hamlib-1.2.8-3.fc10 has been pushed to the Fedora 10 stable repository.  If problems still persist, please make note of it in this bug report.

Note You need to log in before you can comment on or make changes to this bug.