Re: broken: pkg-config and $includedir/gnome-2.0



On Sun, 2001-10-28 at 10:10, Havoc Pennington wrote:
> 
> jacob berkman <jacob ximian com> writes:
> > i've found some brokenness in how pkg-config handles having multiple
> > versions of packages in $PKG_CONFIG_PATH.  i apologize for the lack of
> > brevity in this mail, but the problem is a little complex.
> 
> It may simply be that pkg-config searches PKG_CONFIG_PATH backward.

this isn't it - because i do the the -L/gnome/lib when i put
libgnomecanvas first.  the problem is that i get different (ie, one is
broken) ordering of the -L lines depending on the order they are passed
to pkg-config.
  
> > pkg-config guys, thoughts?
> 
> I just woke up, but I didn't figure out yet why your algorithm would
> have different results - give me a few minutes. ;-)
>
> Note that the reason pkg-config scans dirs first is that you have to
> load all the .pc files before you have the full package list (due to
> pulling in dependencies).

ok, i think this algorithm will handle deps correctly:

    for pkg in pkglist:
        add to required hash
    
    for directory in searchpath:
        for file in directory:
        if file is in required hash
	    add to loaded hash
            mark pkg as found
	    for dep in file:
		if dep is in loaded:
		    output flags
		else if dep is not in required:
		    add to required
	    output flags
	else if file is not in loaded:
	    add to loaded hash
    
    for pkg in pkglist
        if pkg isn't found
        error



jacob
-- 
"Beat mixing is 10000 times more fun than even video games."
	-- bt



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]