[postgis-devel] on parallel and recursive make

Sandro Santilli strk at kbt.io
Wed Nov 4 03:55:23 PST 2020


On Wed, Nov 04, 2020 at 12:36:50PM +0100, rmrodriguez at carto.com wrote:
> On Wed, Nov 4, 2020 at 11:51 AM Sandro Santilli <strk at kbt.io> wrote:
> >
> > Is that the postgis/ subdir ?
> > I expected this behaviour, yes.
> > The thing is that encoding deps in subdirs means that parallel
> > builds from top-level dir may end up building the same dependency
> > twice (think liblwgeom), which results in instabilities.
> 
> Not true. liblwgeom might be tried to be built twice, but the second
> one won't do anything since it's already built and there weren't any
> changes in the source.

I've seen Travis errors like: .a: unrecognized object
which suggests the linker was trying to use an object file _while_
the object file was being written by another thread (race condition
between checking if the file exists and creating the file).

> And why is that desirable? Before this change you could do a make
> under the postgis/ subdirectory and if there was a change in liblwgeom
> you would get an update

Yes, and if there wasn't a change you'd still have to wait for one
or more "make" processes to start and go verify in each directory.

> This was working perfectly fine before the changes. Why would I now
> need to run make all in parallel, when `make check` in parallel worked
> before?

Ok, I reverted that commit with
ef88e7443188275f14727a33997f43ab118c6bdf

Let's see if bots are happy, and I'll file tickets if there
are errors.

--strk;


More information about the postgis-devel mailing list