[gentoo-dev] Better handling of USE flags to enable/disable system libraries

2013-05-28 Thread David Carlos Manuelda
I posted a bug about that along with a suggestion, despite sometimes I do not 
explain myself correctly (I am very sorry): bug #471590

Many packages are bundling its own libraries rather than link against system 
ones, and there is a bug tracker for that (bug #251464)

As I saw in many ebuilds, it is fixed by putting a new system-{$LIBRARY} 
IUSE in the affected ebuilds to enable/disable linking with external or 
bundled library, but there are plenty of libraries and packages out there to 
pullute the use's config files with several combinations of that USE flags.

What I propose here, is to simplify the process a lot by handling those 
system-{$LIBRARY} USE flags internally with a very simple configuration for 
the user, rather than expose the USE flag directly and forcing user to save 
all combinations for that purpose.

This request/idea is inspired on how the x86_ABI is handled:
As a comparison only, most packages have 32 and 64, and you don't have to 
handle them via USE flag per-package, rather, you have an option in make.conf 
to set it all of them automatically.

What I propose for example, is a very good and simple approach: to have an 
option in portage's make.conf, something like that (the name may change):

1.- USE_SYSTEM_LIBRARIES=cairo sqlite XXX
2.- USE_SYSTEM_LIBRARIES=* -cairo
3.- USE_SYSTEM_LIBRARIES=*

Case explanation:
1.- Will trigger automatically (and enable) USE flags: system-cairo, system-
sqlite and system-XXX
2.- Will trigger all system-* related USE except system-cairo which will be 
disabled
3.- Will trigger all system-* related USE variables with no exception.

I honestly think, it is a best aproach to resolve the library bundling, along 
with a correct fix for affected ebuilds.

What do you think?

Thanks for taking your time to read this suggestion.

David Carlos Manuelda.

signature.asc
Description: This is a digitally signed message part.


Re: [gentoo-dev] Better handling of USE flags to enable/disable system libraries

2013-05-28 Thread David Carlos Manuelda
El Martes, 28 de mayo de 2013 14:03:52 Mike Frysinger escribió:
 On Tuesday 28 May 2013 13:53:54 Michał Górny wrote:
  On Tue, 28 May 2013 16:43:10 +0200 David Carlos Manuelda wrote:
   I posted a bug about that along with a suggestion, despite sometimes I
   do
   not explain myself correctly (I am very sorry): bug #471590
   
   Many packages are bundling its own libraries rather than link against
   system ones, and there is a bug tracker for that (bug #251464)
   [...]
   What I propose for example, is a very good and simple approach: to have
   an option in portage's make.conf, something like that (the name may
   change):
   
   1.- USE_SYSTEM_LIBRARIES=cairo sqlite XXX
   2.- USE_SYSTEM_LIBRARIES=* -cairo
   3.- USE_SYSTEM_LIBRARIES=*
  
  I don't think we should do it like this.
  
  Bundling libraries is a pathological case. In general, we should work
  on fixing this and getting rid of bundled libraries. In that general
  case, the flags are not required.
 
 +1
 -mike
Ok, thinking it better I agree, that having them use system libraries is far 
better, but why then those affected ebuilds have corresponding USE disabled by 
default?

signature.asc
Description: This is a digitally signed message part.