https://bugzilla.redhat.com/show_bug.cgi?id=863499
Bug ID: 863499 QA Contact: extras-qa@fedoraproject.org Severity: high Version: 18 Priority: unspecified CC: haskell-devel@lists.fedoraproject.org, lakshminaras2002@gmail.com Assignee: lakshminaras2002@gmail.com Summary: error while loading shared libraries: libHSleksah-0.12.1.3-ghc7.4.1.so: cannot open shared object file: No such file or directory Regression: --- Story Points: --- Classification: Fedora OS: Linux Reporter: matteo@member.fsf.org Type: Bug Documentation: --- Hardware: Unspecified Mount Type: --- Status: NEW Component: leksah Product: Fedora
Description of problem:
In f18 current (alpha), leksah fails to start with the following error on the command line:
leksah: error while loading shared libraries: libHSleksah-0.12.1.3-ghc7.4.1.so: cannot open shared object file: No such file or directory
Indeed, ldd /usr/bin/leksah reports:
linux-vdso.so.1 => (0x00007fffdd7ff000) libHSleksah-0.12.1.3-ghc7.4.1.so => not found libHSutf8-string-0.3.7-ghc7.4.1.so => /usr/lib64/ghc-7.4.1/utf8-string-0.3.7/libHSutf8-string-0.3.7-ghc7.4.1.so (0x00007f69b6102000) libHSregex-tdfa-1.1.8-ghc7.4.1.so => /usr/lib64/ghc-7.4.1/regex-tdfa-1.1.8/libHSregex-tdfa-1.1.8-ghc7.4.1.so (0x00007f69b57d5000) libHSregex-base-0.93.2-ghc7.4.1.so => /usr/lib64/ghc-7.4.1/regex-base-0.93.2/libHSregex-base-0.93.2-ghc7.4.1.so (0x00007f69b55b1000) libHSleksah-server-0.12.1.2-ghc7.4.1.so => /usr/lib64/ghc-7.4.1/leksah-server-0.12.1.2/libHSleksah-server-0.12.1.2-ghc7.4.1.so (0x00007f69b51e3000) [ ...SNIP... ]
It seems the other SOs are found correctly. libHSleksah-0.12.1.3-ghc7.4.1.so is installed in /usr/lib64/ghc-7.4.1/leksah-0.12.1.3/
Version-Release number of selected component (if applicable):
ghc-leksah-0.12.1.3-5.fc18.x86_64 leksah-server-0.12.1.2-5.fc18.x86_64 ghc-leksah-server-0.12.1.2-5.fc18.x86_64 leksah-0.12.1.3-5.fc18.x86_64
https://bugzilla.redhat.com/show_bug.cgi?id=863499
Lakshmi Narasimhan lakshminaras2002@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |ASSIGNED
--- Comment #1 from Lakshmi Narasimhan lakshminaras2002@gmail.com --- I will take a look. Setting LD_LIBRARY_PATH to the leksah directory inside /usr/lib64/ghc-7.4.1 works. I will check why the path information is not getting written while building the rpm.
https://bugzilla.redhat.com/show_bug.cgi?id=863499
--- Comment #2 from Lakshmi Narasimhan lakshminaras2002@gmail.com --- The rpath information in leksah starts with /builddir/build/BUILD/leksah-0.12.1.3/dist/build and hence the "library not found" error.
leksah exports modules in a library package and this package is in turn listed as a dependency for the executable. If we use --shared option, this exported package becomes a shared library dependency for leksah binary. Before 7.4.1, I patched leksah to remove the library as a dependency. This was done to solve an issue that occurred while running haddock after build ( http://hackage.haskell.org/trac/hackage/ticket/656 ). The issue got fixed in 7.4.1 and I removed the patch.
This "library not found" issue could have been there before but never surfaced because of the patch. I checked that putting the patch back again removes libHSleksah-0.12.1.3-ghc7.4.1.so as a dependency of leksah binary and the issue is fixed.
https://bugzilla.redhat.com/show_bug.cgi?id=863499
Lakshmi Narasimhan lakshminaras2002@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Status|ASSIGNED |ON_DEV
--- Comment #3 from Lakshmi Narasimhan lakshminaras2002@gmail.com --- Built for rawhide. http://koji.fedoraproject.org/koji/taskinfo?taskID=4584121
F18 scratch build http://koji.fedoraproject.org/koji/buildinfo?buildID=359681
Build for f18 will be done once ghc-7.4.1 update gets pushed to stable.
https://bugzilla.redhat.com/show_bug.cgi?id=863499
--- Comment #4 from Lakshmi Narasimhan lakshminaras2002@gmail.com --- Incorrect update
Built for rawhide. http://koji.fedoraproject.org/koji/buildinfo?buildID=359681
F18 scratch build https://koji.fedoraproject.org/koji/taskinfo?taskID=4584107
https://bugzilla.redhat.com/show_bug.cgi?id=863499
Lakshmi Narasimhan lakshminaras2002@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Priority|unspecified |high Hardware|Unspecified |All
https://bugzilla.redhat.com/show_bug.cgi?id=863499
--- Comment #5 from Jens Petersen petersen@redhat.com --- I see - sorry my fault for just dropping that patch earlier.
The self-dependency is "interesting" though - maybe worth asking upstream about the story behind it? As such it has the potential to save a lot of build time.
How about trying to use chrpath to edit the RPATH in the leksak binary instead?
https://bugzilla.redhat.com/show_bug.cgi?id=863499
--- Comment #6 from Jens Petersen petersen@redhat.com --- So actually I had the same problem when moving "back" to monolithic haskell-platform.
Anyway I think you can fix it like this:
BuildRequires: chrpath
: :
%install
:
PROG=%{buildroot}%{_bindir}/%name RPATH=$(chrpath $PROG| sed -e "s!^$PROG: RPATH=!!") case $RPATH in *$PWD*) NEWRPATH=$(echo $RPATH | sed -e "s!$PWD!%{ghclibdir}!g" -e "s!/dist/build!!g") chrpath -r $NEWRPATH $PROG ;; esac
(taken from haskell-platform.spec though untested here).
Then you could drop the patch and benefit from the shared lib.
In the long term I would like to see all dynamically linked binlib haskell packages doing this.
https://bugzilla.redhat.com/show_bug.cgi?id=863499
--- Comment #7 from Lakshmi Narasimhan lakshminaras2002@gmail.com --- Jens, I think you were right in dropping the patch earlier because the haddock issue was fixed in ghc-7.4.1. Thanks for the new patch. I did modify rpath of leksah binary using chrpath and was able to get it working. I will incorporate this into the spec file for f18 and rawhide.
https://bugzilla.redhat.com/show_bug.cgi?id=863499
--- Comment #8 from Lakshmi Narasimhan lakshminaras2002@gmail.com --- Jens, I have built leksah for F18 with the deps patch. I will try out the patch that you have mentioned in comment 6 in rawhide and then port it back to F18. Will keep this bug open.
https://bugzilla.redhat.com/show_bug.cgi?id=863499
Fedora Update System updates@fedoraproject.org changed:
What |Removed |Added ---------------------------------------------------------------------------- Status|ON_DEV |MODIFIED
https://bugzilla.redhat.com/show_bug.cgi?id=863499
--- Comment #9 from Fedora Update System updates@fedoraproject.org --- leksah-0.12.1.3-6.fc18 has been submitted as an update for Fedora 18. https://admin.fedoraproject.org/updates/leksah-0.12.1.3-6.fc18
https://bugzilla.redhat.com/show_bug.cgi?id=863499
--- Comment #10 from Fedora Update System updates@fedoraproject.org --- leksah-0.12.1.3-6.fc18 has been pushed to the Fedora 18 stable repository. If problems still persist, please make note of it in this bug report.
Product: Fedora https://bugzilla.redhat.com/show_bug.cgi?id=863499
Jens Petersen petersen@redhat.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Status|MODIFIED |CLOSED Fixed In Version| |leksah-0.12.1.3-6.fc18 Resolution|--- |ERRATA Last Closed| |2012-12-03 22:10:31
--- Comment #11 from Jens Petersen petersen@redhat.com --- works for me
closing for bodhi
haskell-devel@lists.fedoraproject.org