Re: gar.lib.mk still wrong



On Thu, 2007-03-01 at 21:31 +0000, Peter wrote:
> This logic is wrong.  I've posted a patch previously.
> The assignment of INTTLOOLIZE and LIBTOOLIZE are reversed.
> A TRUE condition will assign $bindir whereas it should not.
> It should be the other way around.

GAR. Even worse, that code was totally broken. Yes, you are correct, the
logic was reversed -- however, it never could have worked with anything
but a GARNOME provided tool.

>     @if which intltoolize > /dev/null; then \
>         INTLTOOLIZE=$(bindir)/intltoolize; \
>     else \
>         INTLTOOLIZE=$(shell which intltoolize > /dev/null 2>&1); \

Redirecting both STDOUT and STDERR to the big bitbucket results in
assigning an empty string always for the 'else' case. If the fixup tool
actually has been called, it definitely was the one in our $prefix.

I had a look at your previously posted patch, and that indeed works. You
removed that bad redirection, too. :)


However, IMHO we should default to the GARNOME built tool, if it exists,
and fall back to the system one otherwise. If neither one exists, just
freak out and stop the build. :)

That's exactly what the new code does. Also, that old hack has been
unnecessarily complicated and confusing. To fix this, I hardly did
anything but remove a huge mess. See the diff. [1]

All we need to do is just call the tool we want. The $PATH already takes
care about it for us. In gar.conf.mk the $PATH is set to explicitly use
the GARNOME $prefix first, then whatever the $PATH has been before. Thus
we default to an executable in our $prefix if it exists, and try the
system ones otherwise.


Peter, thanks again for pointing this out and repeatedly poking. :)

  guenther


[1] http://svn.gnome.org/viewcvs/garnome/trunk/gar.lib.mk?r1=4586&r2=4777

-- 
char *t="\10pse\0r\0dtu\0  ghno\x4e\xc8\x79\xf4\xab\x51\x8a\x10\xf4\xf4\xc4";
main(){ char h,m=h=*t++,*x=t+2*h,c,i,l=*x,s=0; for (i=0;i<l;i++){ i%8? c<<=1:
(c=*++x); c&128 && (s+=h); if (!(h>>=1)||!t[s+h]){ putchar(t[s]);h=m;s=0; }}}




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