maintainer mode

Andrew Tridgell tridge at samba.anu.edu.au
Sat Oct 31 13:37:34 GMT 1998


> > c.o:
> > @OBJ_SAVE@
> > 	$(CC) -I. -I$(srcdir) $(CFLAGS) -c $< @CC_SHOBJ_FLAG@
> > @OBJ_RESTORE@
> 
> Starting to get unreadable, huh? :-D

actually, yes! which is why I'd prefer a CC shell wrapper for broken
compilers. 

> assume you have foo/x.c and bar/x.c; try to compile them both at once
> without `-c -o'.  Unless @OBJ_SAVE@ and @OBJ_RESTORE@ do some kind of
> locking to avoid trouble, it will probably break.

it will break, but only on systems that can't handle -c and -o on the
same command line. What kind of system will have a parallel make and
not be able to do that? 

on systems that can handle -c and -o (ie. all systesm that Samba
currently builds on) parallel make will work fine.

> It's not easy to write a portable script that takes care of this
> problem.  We're discussing this very issue in the libtool mailing
> list, and, IMO, I'd prefer not to rely on shell-script based locking
> to avoid problems in parallel builds...

then just forget the locking. If someone tries a parallel make on an
ancient SCO system that can't do -c and -o then they are very
silly. There is a limit to how far developers should go to accomodate
broken systems and I think that a combination of parallel building
with a broken compiler is way past that limit. We gave up on non-ansi
compilers a long time ago in Samba. I think we can give up on this
too.

the fact that it actually will work because samba doesn't have any C
files of the same name in 2 directories is largely irrelevant :-)


More information about the samba-technical mailing list