lmi
[Top][All Lists]
Advanced

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

Re: [lmi] wx xrcdemo and --disable-gif


From: Vadim Zeitlin
Subject: Re: [lmi] wx xrcdemo and --disable-gif
Date: Mon, 14 Aug 2017 01:41:53 +0200

On Sun, 13 Aug 2017 16:54:56 +0000 Greg Chicares <address@hidden> wrote:

GC> On 2017-08-12 15:47, Greg Chicares wrote:
GC> > It's been a long time since I built the wx samples, but I tried it today
GC> > and it failed as shown below. Could it be that samples/xrc doesn't
GC> > respect the '--disable-gif' configure option that I've specified?

 Yes, indeed, I've applied a trivial fix to it in

https://github.com/wxWidgets/wxWidgets/commit/3654a12d6addaf0d3598ea045c4ebebce46ba07d

GC> BTW, the samples seem to build one at a time even with parallel 'make',
GC> which is a significant pessimization these days.

 Yes, indeed. I've never noticed it because I never build all of them at
once, but it is obviously a real problem.

GC> samples:
GC>     (cd samples && $(MAKE) all)
GC> 
GC> so it just defers to 'samples/Makefile', which contains:
GC> 
GC> SAMPLES_SUBDIRS=access animate artprov calendar [...]
GC> all:
GC>     @for d in $(SAMPLES_SUBDIRS); do (cd $$d && $(MAKE)); done
GC> 
GC> Presumably that shell loop is generated from some 'xyzzy.in', but
GC> I can't find any plausible candidate, or I'd propose a patch for it.
GC> But as for the presumably-generated 'samples/Makefile', wouldn't
GC> the following change (just changing ';' to '&') work?
GC> 
GC>  all:
GC> -   @for d in $(SAMPLES_SUBDIRS); do (cd $$d && $(MAKE)); done
GC> +   @for d in $(SAMPLES_SUBDIRS); do (cd $$d && $(MAKE))& done

 I guess this would indeed work for GNU make which is supposed to ensure
that no more than N make programs are running at once when -jN is
specified, although I haven't tested it yet. But doing this for a make
program without such intelligent rate limiting would be bad (launching 100
builds at one would bring an average machine to its knees...) and I think
they might still be used, e.g. under various BSD systems which
traditionally shy from GNU make.

 So it looks like it might be better to avoid writing loops at all, I
wonder if something like the following would work:

        all clean distclean: $(SAMPLES_SUBDIRS)

        $(SAMPLES_SUBDIRS):
                $(MAKE) -C $@ $(MAKECMDGOALS) $(.TARGETS)

(the last line tries to be compatible with both GNU and BSD makes). AFAICS
it should and seems preferable to explicitly looping anyhow, but I didn't
test this yet. I can do it later, but if you're eager to try it out, could
you please let me know if this works for you?

 Thanks in advance,
VZ


reply via email to

[Prev in Thread] Current Thread [Next in Thread]