WelcomeWelcome | FAQFAQ | DownloadsDownloads | WikiWiki

Author Topic: mpg123 and libtool  (Read 2547 times)

Offline bmarkus

  • Administrator
  • Hero Member
  • *****
  • Posts: 7183
    • My Community Forum
mpg123 and libtool
« on: July 30, 2009, 04:11:29 AM »
mpg123 contains  libltdl.so.7 which is originally part of libtool. Is there any specific reason not to have it there instead of using libtool? Reducing size can be an argument, however on reason why libtool is relatively large that dev files are not separated.
Béla
Ham Radio callsign: HA5DI

"Amateur Radio: The First Technology-Based Social Network."

Offline Jason W

  • Retired Admins
  • Hero Member
  • *****
  • Posts: 9730
Re: mpg123 and libtool
« Reply #1 on: July 30, 2009, 07:21:21 AM »
You bring up an important issue. It is normally incorrect to pack dependent libs into extensions in the normal path as that just causes library conflict when another extension that contains that lib is updated.  With TC's modular approach listing the extension that contains the dependent lib as a dependency is how we do it.  There are exceptions though, when two packages can be combined when they are dependent on one another and are almost never used seperately.  But there is one way to include extra libs into an extension and that is by making the extension self contained, with the dependent lib installed outside of the library path. 

Mpg123 has it's libs installed into /usr/local/mpg123/lib, so other apps will not see that libtool file.  An upgrade of libtool will not cause conflict as the lib that is in mpg123 cannot be used by other apps unless they are invoked by setting /usr/local/mpg123/lib as the primary library path.  I used this same approach with audacity as it needed a version of wxgtk that would not be able to be used with other apps do to configure flags as well as it needed to be an older version.  This is basically how DSL .uci extensions were made and it is valuable when the modular approach cannot be used. 

As for the libtool extension, Debian has it split up between libtool (the /usr/local/bin files basically), libtool-dev (the dev files) and libtdl3 which would be /usr/local/lib/{libltdl.so,libltsl.so.7,libltdl.so.7.2.0}.  My vote would be that libtool be split between the three shared lib files in /usr/local/lib (calling it libtool or libltdl), and call the rest libtool-dev.  That would help from having to create self contained extensions that need the shared libltdl file.

Offline Juanito

  • Administrator
  • Hero Member
  • *****
  • Posts: 14741
Re: mpg123 and libtool
« Reply #2 on: July 30, 2009, 07:44:41 AM »
If the libtool extension were divided into libtool and libtool-devs, what would you put in libtool:
Code: [Select]
/usr/local/lib/libltdl.so
/usr/local/lib/libltdl.so.7
/usr/local/lib/libltdl.so.7.2.0

or

Code: [Select]
/usr/local/lib/libltdl.so
/usr/local/lib/libltdl.so.7
/usr/local/lib/libltdl.so.7.2.0
/usr/local/bin/libtool
/usr/local/bin/libtoolize

or

Code: [Select]
/usr/local/lib/libltdl.so
/usr/local/lib/libltdl.so.7
/usr/local/lib/libltdl.so.7.2.0
/usr/local/bin/libtool
/usr/local/bin/libtoolize
/usr/local/share/libtool/libltdl/*
/usr/local/share/libtool/config/*

Edit: Ah - I see jason made a post in the meantime - I guess the issue is whether all of the files in:

/usr/local/share/libtool/libltdl/*
/usr/local/share/libtool/config/*

..can be consigned to the -devs package or not
« Last Edit: July 30, 2009, 07:48:45 AM by Juanito »

Offline Jason W

  • Retired Admins
  • Hero Member
  • *****
  • Posts: 9730
Re: mpg123 and libtool
« Reply #3 on: July 30, 2009, 07:51:04 AM »
As libtool is mainly a development package, and to prevent name confusion, perhaps we could just make a seperate libltdl extension that would be maintained current alongside libtool and just leave libtool intact.  To call the shared libs libtool would be confusing.  ALsa.tcel and libasound.tcel was done this way and it is not such a bad idea to prevent naming confusion.  And libtool and libltdl overlapping would be harmless as they would be the exact same files.

Offline Juanito

  • Administrator
  • Hero Member
  • *****
  • Posts: 14741
Re: mpg123 and libtool
« Reply #4 on: August 01, 2009, 03:16:36 PM »
libltdl extension posted