Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 18 Sep 2002 22:27:29 +1000 (EST)
From:      Bruce Evans <bde@zeta.org.au>
To:        Juli Mallett <jmallett@FreeBSD.org>
Cc:        cvs-committers@FreeBSD.org, <cvs-all@FreeBSD.org>
Subject:   Re: cvs commit: src/usr.bin/make Makefile arch.c compat.c cond.c dir.c for.c job.c make.c make.h parse.c suff.c targ.c var.c
Message-ID:  <20020918221316.I15381-100000@gamplex.bde.org>
In-Reply-To: <20020917153759.A23984@FreeBSD.org>

next in thread | previous in thread | raw e-mail | index | archive | help
On Tue, 17 Sep 2002, Juli Mallett wrote:

> * De: Juli Mallett <jmallett@FreeBSD.org> [ Data: 2002-09-17 ]
> 	[ Subjecte: cvs commit: src/usr.bin/make Makefile arch.c compat.c cond.c dir.c for.c job.c make.c make.h parse.c suff.c targ.c var.c ]
> > jmallett    2002/09/17 15:31:27 PDT
> >
> >   Modified files:
> >     usr.bin/make         Makefile arch.c compat.c cond.c dir.c
> >                          for.c job.c make.c make.h parse.c suff.c
> >                          targ.c var.c
> >   Log:
> >   Move common use of if (DEBUG(FOO)) printf... to DEBUGF(FOO, ...), using
> >   variable length arguments to a macro.  Bump version as this makes DEBUG
> >   statements *always* go to stderr rather than sometimes stdout.  There are
> >   a few stragglers, which I will take care of as soon as I can.  Mostly these
> >   relate to the need-for-death-of some of the remote job code.

This greatly unportabilizes make.  Now it can't be compiled by C compilers
(C90).

> Someone who has a good idea for how to stubify this macro in the BOOTSTRAPPING
> case, please let me know.  My solutions fail on using enum { DIR } because DIR
> is an stdio type.

The best solution is to write portable code.

`make' was compileable with a C compiler almost perfectly yesterday,
although it couldn't quite work.  Compilation probably depended on my
local hack to avoid hard-coded long longs and/or gccism's in standard
headers, and running depends on better fixes for the long longs.  Now
compiling fails early with a syntax error in DEBUGF.

%%%
Script started on Wed Sep 18 22:19:10 2002
ttyp0:bde@besplex:/tmp/make> CC='tcc -Ysystem' make
Warning: Using /tmp/make/obj as object directory instead of canonical /usr/obj/tmp/make
tcc -Ysystem -O -pipe  -I/tmp/make -DMAKE_VERSION=\"5200209170\" -DDEFSHELL=1    -c /tmp/make/arch.c
tcc: Warning: Unknown option, -pipe.
"/tmp/make/make.h", line 341: Error:
  [ISO 6.8.3]: Badly punctuated parameters for macro 'DEBUGF'.

*** Error code 1

Stop in /tmp/make.
ttyp0:bde@besplex:/tmp/make> cvs -Q update -Dyesterday
ttyp0:bde@besplex:/tmp/make> CC='tcc -Ysystem' make
Warning: Using /tmp/make/obj as object directory instead of canonical /usr/obj/tmp/make
tcc -Ysystem -O -pipe  -I/tmp/make -DMAKE_VERSION=\"5200208240\" -DDEFSHELL=1    -c /tmp/make/arch.c
tcc: Warning: Unknown option, -pipe.
tcc -Ysystem -O -pipe  -I/tmp/make -DMAKE_VERSION=\"5200208240\" -DDEFSHELL=1    -c /tmp/make/buf.c
tcc: Warning: Unknown option, -pipe.
tcc -Ysystem -O -pipe  -I/tmp/make -DMAKE_VERSION=\"5200208240\" -DDEFSHELL=1    -c /tmp/make/compat.c
tcc: Warning: Unknown option, -pipe.
tcc -Ysystem -O -pipe  -I/tmp/make -DMAKE_VERSION=\"5200208240\" -DDEFSHELL=1    -c /tmp/make/cond.c
tcc: Warning: Unknown option, -pipe.
tcc -Ysystem -O -pipe  -I/tmp/make -DMAKE_VERSION=\"5200208240\" -DDEFSHELL=1    -c /tmp/make/dir.c
tcc: Warning: Unknown option, -pipe.
tcc -Ysystem -O -pipe  -I/tmp/make -DMAKE_VERSION=\"5200208240\" -DDEFSHELL=1    -c /tmp/make/for.c
tcc: Warning: Unknown option, -pipe.
tcc -Ysystem -O -pipe  -I/tmp/make -DMAKE_VERSION=\"5200208240\" -DDEFSHELL=1    -c /tmp/make/hash.c
tcc: Warning: Unknown option, -pipe.
tcc -Ysystem -O -pipe  -I/tmp/make -DMAKE_VERSION=\"5200208240\" -DDEFSHELL=1    -c /tmp/make/job.c
tcc: Warning: Unknown option, -pipe.
"/tmp/make/job.c", line 231: Warning:
  [ISO 6.1.2.2]: 'nJobs' previously declared with external linkage (at "/tmp/make/job.h", line 215).

"/tmp/make/job.c", line 232: Warning:
  [ISO 6.1.2.2]: 'nLocal' previously declared with external linkage (at "/tmp/make/job.h", line 216).

"/tmp/make/job.c", line 233: Warning:
  [ISO 6.1.2.2]: 'jobs' previously declared with external linkage (at "/tmp/make/job.h", line 217).

"/tmp/make/job.c", line 234: Warning:
  [ISO 6.1.2.2]: 'jobFull' previously declared with external linkage (at "/tmp/make/job.h", line 220).

"/tmp/make/job.c", line 244: Warning:
  [ISO 6.1.2.2]: 'lastNode' previously declared with external linkage (at "/tmp/make/job.h", line 211).

"/tmp/make/job.c", line 246: Warning:
  [ISO 6.1.2.2]: 'targFmt' previously declared with external linkage (at "/tmp/make/job.h", line 207).

"/tmp/make/job.c", line 266: Warning:
  [ISO 6.1.2.2]: 'stoppedJobs' previously declared with external linkage (at "/tmp/make/job.h", line 218).

tcc -Ysystem -O -pipe  -I/tmp/make -DMAKE_VERSION=\"5200208240\" -DDEFSHELL=1    -c /tmp/make/main.c
tcc: Warning: Unknown option, -pipe.
tcc -Ysystem -O -pipe  -I/tmp/make -DMAKE_VERSION=\"5200208240\" -DDEFSHELL=1    -c /tmp/make/make.c
tcc: Warning: Unknown option, -pipe.
tcc -Ysystem -O -pipe  -I/tmp/make -DMAKE_VERSION=\"5200208240\" -DDEFSHELL=1    -c /tmp/make/parse.c
tcc: Warning: Unknown option, -pipe.
tcc -Ysystem -O -pipe  -I/tmp/make -DMAKE_VERSION=\"5200208240\" -DDEFSHELL=1    -c /tmp/make/str.c
tcc: Warning: Unknown option, -pipe.
tcc -Ysystem -O -pipe  -I/tmp/make -DMAKE_VERSION=\"5200208240\" -DDEFSHELL=1    -c /tmp/make/suff.c
tcc: Warning: Unknown option, -pipe.
tcc -Ysystem -O -pipe  -I/tmp/make -DMAKE_VERSION=\"5200208240\" -DDEFSHELL=1    -c /tmp/make/targ.c
tcc: Warning: Unknown option, -pipe.
tcc -Ysystem -O -pipe  -I/tmp/make -DMAKE_VERSION=\"5200208240\" -DDEFSHELL=1    -c /tmp/make/var.c
tcc: Warning: Unknown option, -pipe.
tcc -Ysystem -O -pipe  -I/tmp/make -DMAKE_VERSION=\"5200208240\" -DDEFSHELL=1    -c /tmp/make/lst.lib/lstAppend.c
tcc: Warning: Unknown option, -pipe.
tcc -Ysystem -O -pipe  -I/tmp/make -DMAKE_VERSION=\"5200208240\" -DDEFSHELL=1    -c /tmp/make/lst.lib/lstAtEnd.c
tcc: Warning: Unknown option, -pipe.
tcc -Ysystem -O -pipe  -I/tmp/make -DMAKE_VERSION=\"5200208240\" -DDEFSHELL=1    -c /tmp/make/lst.lib/lstAtFront.c
tcc: Warning: Unknown option, -pipe.
tcc -Ysystem -O -pipe  -I/tmp/make -DMAKE_VERSION=\"5200208240\" -DDEFSHELL=1    -c /tmp/make/lst.lib/lstClose.c
tcc: Warning: Unknown option, -pipe.
tcc -Ysystem -O -pipe  -I/tmp/make -DMAKE_VERSION=\"5200208240\" -DDEFSHELL=1    -c /tmp/make/lst.lib/lstConcat.c
tcc: Warning: Unknown option, -pipe.
tcc -Ysystem -O -pipe  -I/tmp/make -DMAKE_VERSION=\"5200208240\" -DDEFSHELL=1    -c /tmp/make/lst.lib/lstDatum.c
tcc: Warning: Unknown option, -pipe.
tcc -Ysystem -O -pipe  -I/tmp/make -DMAKE_VERSION=\"5200208240\" -DDEFSHELL=1    -c /tmp/make/lst.lib/lstDeQueue.c
tcc: Warning: Unknown option, -pipe.
tcc -Ysystem -O -pipe  -I/tmp/make -DMAKE_VERSION=\"5200208240\" -DDEFSHELL=1    -c /tmp/make/lst.lib/lstDestroy.c
tcc: Warning: Unknown option, -pipe.
tcc -Ysystem -O -pipe  -I/tmp/make -DMAKE_VERSION=\"5200208240\" -DDEFSHELL=1    -c /tmp/make/lst.lib/lstDupl.c
tcc: Warning: Unknown option, -pipe.
tcc -Ysystem -O -pipe  -I/tmp/make -DMAKE_VERSION=\"5200208240\" -DDEFSHELL=1    -c /tmp/make/lst.lib/lstEnQueue.c
tcc: Warning: Unknown option, -pipe.
tcc -Ysystem -O -pipe  -I/tmp/make -DMAKE_VERSION=\"5200208240\" -DDEFSHELL=1    -c /tmp/make/lst.lib/lstFind.c
tcc: Warning: Unknown option, -pipe.
tcc -Ysystem -O -pipe  -I/tmp/make -DMAKE_VERSION=\"5200208240\" -DDEFSHELL=1    -c /tmp/make/lst.lib/lstFindFrom.c
tcc: Warning: Unknown option, -pipe.
tcc -Ysystem -O -pipe  -I/tmp/make -DMAKE_VERSION=\"5200208240\" -DDEFSHELL=1    -c /tmp/make/lst.lib/lstFirst.c
tcc: Warning: Unknown option, -pipe.
tcc -Ysystem -O -pipe  -I/tmp/make -DMAKE_VERSION=\"5200208240\" -DDEFSHELL=1    -c /tmp/make/lst.lib/lstForEach.c
tcc: Warning: Unknown option, -pipe.
tcc -Ysystem -O -pipe  -I/tmp/make -DMAKE_VERSION=\"5200208240\" -DDEFSHELL=1    -c /tmp/make/lst.lib/lstForEachFrom.c
tcc: Warning: Unknown option, -pipe.
tcc -Ysystem -O -pipe  -I/tmp/make -DMAKE_VERSION=\"5200208240\" -DDEFSHELL=1    -c /tmp/make/lst.lib/lstInit.c
tcc: Warning: Unknown option, -pipe.
tcc -Ysystem -O -pipe  -I/tmp/make -DMAKE_VERSION=\"5200208240\" -DDEFSHELL=1    -c /tmp/make/lst.lib/lstInsert.c
tcc: Warning: Unknown option, -pipe.
tcc -Ysystem -O -pipe  -I/tmp/make -DMAKE_VERSION=\"5200208240\" -DDEFSHELL=1    -c /tmp/make/lst.lib/lstIsAtEnd.c
tcc: Warning: Unknown option, -pipe.
tcc -Ysystem -O -pipe  -I/tmp/make -DMAKE_VERSION=\"5200208240\" -DDEFSHELL=1    -c /tmp/make/lst.lib/lstIsEmpty.c
tcc: Warning: Unknown option, -pipe.
tcc -Ysystem -O -pipe  -I/tmp/make -DMAKE_VERSION=\"5200208240\" -DDEFSHELL=1    -c /tmp/make/lst.lib/lstLast.c
tcc: Warning: Unknown option, -pipe.
tcc -Ysystem -O -pipe  -I/tmp/make -DMAKE_VERSION=\"5200208240\" -DDEFSHELL=1    -c /tmp/make/lst.lib/lstMember.c
tcc: Warning: Unknown option, -pipe.
tcc -Ysystem -O -pipe  -I/tmp/make -DMAKE_VERSION=\"5200208240\" -DDEFSHELL=1    -c /tmp/make/lst.lib/lstNext.c
tcc: Warning: Unknown option, -pipe.
tcc -Ysystem -O -pipe  -I/tmp/make -DMAKE_VERSION=\"5200208240\" -DDEFSHELL=1    -c /tmp/make/lst.lib/lstOpen.c
tcc: Warning: Unknown option, -pipe.
tcc -Ysystem -O -pipe  -I/tmp/make -DMAKE_VERSION=\"5200208240\" -DDEFSHELL=1    -c /tmp/make/lst.lib/lstRemove.c
tcc: Warning: Unknown option, -pipe.
tcc -Ysystem -O -pipe  -I/tmp/make -DMAKE_VERSION=\"5200208240\" -DDEFSHELL=1    -c /tmp/make/lst.lib/lstReplace.c
tcc: Warning: Unknown option, -pipe.
tcc -Ysystem -O -pipe  -I/tmp/make -DMAKE_VERSION=\"5200208240\" -DDEFSHELL=1    -c /tmp/make/lst.lib/lstSucc.c
tcc: Warning: Unknown option, -pipe.
tcc -Ysystem -O -pipe  -I/tmp/make -DMAKE_VERSION=\"5200208240\" -DDEFSHELL=1     -static -o make arch.o buf.o compat.o cond.o dir.o for.o hash.o job.o main.o make.o parse.o str.o suff.o targ.o var.o lstAppend.o lstAtEnd.o lstAtFront.o lstClose.o lstConcat.o lstDatum.o lstDeQueue.o lstDestroy.o lstDupl.o lstEnQueue.o lstFind.o lstFindFrom.o lstFirst.o lstForEach.o lstForEachFrom.o lstInit.o lstInsert.o lstIsAtEnd.o lstIsEmpty.o lstLast.o lstMember.o lstNext.o lstOpen.o lstRemove.o lstReplace.o lstSucc.o
tcc: Warning: Unknown option, -pipe.
tcc: Warning: Unknown option, -static.
gzip -cn /tmp/make/make.1 > make.1.gz
ttyp0:bde@besplex:/tmp/make> obj/make -n
make: cannot open current directory: Too many open files
ttyp0:bde@besplex:/tmp/make> exit

Script done on Wed Sep 18 22:19:58 2002
%%%

Bruce


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe cvs-all" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20020918221316.I15381-100000>