dvdbackup: symbol lookup error: /usr/lib/libdvdread.so.4: undefined symbol: dlopen

Bug #869003 reported by Russell Phillips
42
This bug affects 7 people
Affects Status Importance Assigned to Milestone
libdvdread
Confirmed
Undecided
Unassigned
libdvdread (Ubuntu)
Fix Released
High
Unassigned
Oneiric
Fix Released
Undecided
Unassigned
Precise
Fix Released
High
Unassigned

Bug Description

When running any DVD read operation from dvdbackup (such as -I, -F or -M), it immediately fails with the following error:

dvdbackup: symbol lookup error: /usr/lib/libdvdread.so.4: undefined symbol: dlopen

This occurs on oneiric, however the DVD plays fine in totem (gstreamer). I suspect a function in libdvdread4 has gone walkabout, and dvdbackup needs to be rebuilt against the current version.

Revision history for this message
Jason (jason-pfeil) wrote :

I built the .deb from the source package and it still had the same problem. Running nm on the .so doesn't work because it is stripped of symbols. However, after digging into the source directory, running nm on the just-compiled .so works because the symbols are not stripped. The libdl.so functions (dlopen and friends) are not mapped to any library when they should be. Removing the newly-built .so and rerunning make showed that the library was created with this command:

cd obj && gcc -shared -ldl -Wl,-soname=libdvdread.so.4 -o libdvdread.so dvd_input.so dvd_reader.so dvd_udf.so ifo_print.so ifo_read.so md5.so nav_print.so nav_read.so bitreader.so

Moving the linkage command telling gcc to link the libdl.so library to the libdvdread.so library to the end of the command worked. It generated a .so that shows linkage for the libdl.so functions when nm is run on it. The resulting command is:

cd obj && gcc -shared -Wl,-soname=libdvdread.so.4 -o libdvdread.so dvd_input.so dvd_reader.so dvd_udf.so ifo_print.so ifo_read.so md5.so nav_print.so nav_read.so bitreader.so -ldl

Copying the resulting libdvdread.so to /usr/lib/libdvdread.so.4.1.3 worked like a charm.

I have attached a simple patch to the Makefile which makes this correction.?field.comment=I built the .deb from the source package and it still had the same problem. Running nm on the .so doesn't work because it is stripped of symbols. However, after digging into the source directory, running nm on the just-compiled .so works because the symbols are not stripped. The libdl.so functions (dlopen and friends) are not mapped to any library when they should be. Removing the newly-built .so and rerunning make showed that the library was created with this command:

cd obj && gcc -shared -ldl -Wl,-soname=libdvdread.so.4 -o libdvdread.so dvd_input.so dvd_reader.so dvd_udf.so ifo_print.so ifo_read.so md5.so nav_print.so nav_read.so bitreader.so

Moving the linkage command telling gcc to link the libdl.so library to the libdvdread.so library to the end of the command worked. It generated a .so that shows linkage for the libdl.so functions when nm is run on it. The resulting command is:

cd obj && gcc -shared -Wl,-soname=libdvdread.so.4 -o libdvdread.so dvd_input.so dvd_reader.so dvd_udf.so ifo_print.so ifo_read.so md5.so nav_print.so nav_read.so bitreader.so -ldl

Copying the resulting libdvdread.so to /usr/lib/libdvdread.so.4.1.3 worked like a charm.

I have attached a simple patch to the Makefile which makes this correction.

Revision history for this message
Benjamin Drung (bdrung) wrote :

As you said, this is an issue with libdvdread. Therefore I reassign it from dvdbackup to libdvdread.

Thanks for the patch. To correctly fix this issue, the sources of the Makefile needs to be fixed (Makefile.am / configure.ac).

affects: dvdbackup → libdvdread
Kees Cook (kees)
Changed in libdvdread:
status: New → Confirmed
Changed in libdvdread (Ubuntu):
status: New → Triaged
Revision history for this message
Ubuntu Foundations Team Bug Bot (crichton) wrote :

The attachment "Makefile.patch" of this bug report has been identified as being a patch. The ubuntu-reviewers team has been subscribed to the bug report so that they can review the patch. In the event that this is in fact not a patch you can resolve this situation by removing the tag 'patch' from the bug report and editing the attachment so that it is not flagged as a patch. Additionally, if you are member of the ubuntu-sponsors please also unsubscribe the team from this bug report.

[This is an automated message performed by a Launchpad user owned by Brian Murray. Please contact him regarding any issues with the action taken in this bug report.]

tags: added: patch
Revision history for this message
Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in libdvdread (Ubuntu Precise):
status: New → Confirmed
Revision history for this message
Clint Byrum (clint-fewbar) wrote : Please test proposed package

Hello Russell, or anyone else affected,

Accepted libdvdread into oneiric-proposed, the package will build now and be available in a few hours. Please test and give feedback here. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation how to enable and use -proposed. Thank you in advance!

Changed in libdvdread (Ubuntu Oneiric):
status: Triaged → Fix Committed
tags: added: verification-needed
Revision history for this message
Leon Matthews (leon-matthews) wrote :

Thank you very much Clint, that seems to have done the trick. I installed the package from oneiric-proposed manually and can verify that it fixed the issue on 64-bit. Cheers!

Revision history for this message
Miklos Juhasz (mjuhasz) wrote :

I can also confirm that the proposed version fixed the symbol lookup error.

Martin Pitt (pitti)
tags: added: verification-done
removed: verification-needed
Revision history for this message
Russell Phillips (ignissport) wrote :

I can also confirm the fix works.

Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package libdvdread - 4.1.3-10ubuntu4.1

---------------
libdvdread (4.1.3-10ubuntu4.1) oneiric-proposed; urgency=low

  * debian/patches/102-reorder-linkage.patch: corrects the linking order
    for shared library loading, thanks to Jason Pfeil (LP: #869003).
 -- Kees Cook <email address hidden> Tue, 11 Oct 2011 08:43:22 -0700

Changed in libdvdread (Ubuntu Precise):
status: Confirmed → Fix Released
Changed in libdvdread (Ubuntu Oneiric):
status: Fix Committed → Fix Released
Revision history for this message
PeterPall (peterpall) wrote :

On Precise Pangolin the problem has reoccourred.

Bryce Harrington (bryce)
Changed in libdvdread (Ubuntu Precise):
importance: Undecided → High
status: Fix Released → Triaged
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package libdvdread - 4.2.0-1ubuntu2

---------------
libdvdread (4.2.0-1ubuntu2) precise; urgency=low

  * Remove extraneous debian-changes-4.2.0-1ubuntu1 being automatically
    generated by the packaging which reverts the Ubuntu changes.
    (LP: #869003)
  * Disable hurd.patch; causes FTBFS on AMD64 due to undefined
    get_current_dir_name().
 -- Bryce Harrington <email address hidden> Wed, 07 Dec 2011 18:34:56 -0800

Changed in libdvdread (Ubuntu Precise):
status: Triaged → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.