diff options
author | rsc <devnull@localhost> | 2004-02-29 23:20:28 +0000 |
---|---|---|
committer | rsc <devnull@localhost> | 2004-02-29 23:20:28 +0000 |
commit | d21d62e2fc51e0a6aecd716c47785155b318f5f4 (patch) | |
tree | cb895e3ea1c90f96ae8b301d046e89006b5eebdd /src/cmd | |
parent | c3a72d77dc9e59e2498d68692feb098bf565e119 (diff) | |
download | plan9port-d21d62e2fc51e0a6aecd716c47785155b318f5f4.tar.gz plan9port-d21d62e2fc51e0a6aecd716c47785155b318f5f4.tar.bz2 plan9port-d21d62e2fc51e0a6aecd716c47785155b318f5f4.zip |
Various tweaks.
Diffstat (limited to 'src/cmd')
-rw-r--r-- | src/cmd/9term/mkfile | 4 | ||||
-rw-r--r-- | src/cmd/acme/mkfile | 3 | ||||
-rw-r--r-- | src/cmd/dict/mkfile | 2 | ||||
-rw-r--r-- | src/cmd/diff/mkfile | 2 | ||||
-rw-r--r-- | src/cmd/hoc/code.c | 19 | ||||
-rw-r--r-- | src/cmd/hoc/mkfile | 2 | ||||
-rw-r--r-- | src/cmd/mk/mkfile | 2 | ||||
-rw-r--r-- | src/cmd/mkfile | 3 | ||||
-rw-r--r-- | src/cmd/plumb/mkfile | 2 | ||||
-rw-r--r-- | src/cmd/rc/mkfile | 2 | ||||
-rw-r--r-- | src/cmd/sam/mkfile | 2 | ||||
-rw-r--r-- | src/cmd/samterm/mkfile | 6 | ||||
-rw-r--r-- | src/cmd/yacc.c | 2 |
13 files changed, 32 insertions, 19 deletions
diff --git a/src/cmd/9term/mkfile b/src/cmd/9term/mkfile index b39d2367..d0d5ca72 100644 --- a/src/cmd/9term/mkfile +++ b/src/cmd/9term/mkfile @@ -7,7 +7,9 @@ OFILES=\ 9term.$O\ $SYSNAME.$O\ +SHORTLIB=frame draw plumb fs mux thread 9 + <$PLAN9/src/mkone -LDFLAGS=-lframe -ldraw -lplumb -lfs -lmux -lthread -l9 -L$X11/lib -lX11 -lutil +LDFLAGS=-L$X11/lib -lX11 -lutil diff --git a/src/cmd/acme/mkfile b/src/cmd/acme/mkfile index 86a3fbde..d4738bef 100644 --- a/src/cmd/acme/mkfile +++ b/src/cmd/acme/mkfile @@ -36,8 +36,9 @@ UPDATE=\ $HFILES\ ${OFILES:%.$O=%.c}\ +SHORTLIB=complete plumb fs mux thread frame draw bio 9 <$PLAN9/src/mkone -LDFLAGS=$LDFLAGS -lcomplete -lplumb -lfs -lmux -lthread -lframe -ldraw -lbio -l9 -L$X11/lib -lX11 +LDFLAGS=$LDFLAGS -L$X11/lib -lX11 edit.$O ecmd.$O elog.$O: edit.h diff --git a/src/cmd/dict/mkfile b/src/cmd/dict/mkfile index f5b9e1a2..603ba604 100644 --- a/src/cmd/dict/mkfile +++ b/src/cmd/dict/mkfile @@ -11,7 +11,7 @@ OFILES=dict.$O\ HFILES=dict.h kuten.h -LDFLAGS=$LDFLAGS -lbio -lregexp9 -l9 +SHORTLIB=bio regexp9 9 <$PLAN9/src/mkone mkindex: mkindex.$O $LFILES utils.$O diff --git a/src/cmd/diff/mkfile b/src/cmd/diff/mkfile index 042bd7a0..6445f9dc 100644 --- a/src/cmd/diff/mkfile +++ b/src/cmd/diff/mkfile @@ -10,6 +10,6 @@ OFILES=\ HFILES=diff.h +SHORTLIB=bio 9 <$PLAN9/src/mkone -LDFLAGS=$LDFLAGS -lbio -l9 diff --git a/src/cmd/hoc/code.c b/src/cmd/hoc/code.c index 26762452..7ed3ed1e 100644 --- a/src/cmd/hoc/code.c +++ b/src/cmd/hoc/code.c @@ -38,6 +38,11 @@ initcode(void) } void +nop(void) +{ +} + +void push(Datum d) { if (stackp >= &stack[NSTACK]) @@ -558,10 +563,17 @@ diveq(void) } void +ppush(Datum *d) +{ + push(*d); +} + +void modeq(void) { Datum d1, d2; long x; + d1 = pop(); d2 = pop(); if (d1.sym->type != VAR && d1.sym->type != UNDEF) @@ -570,9 +582,12 @@ modeq(void) /* d2.val = d1.sym->u.val %= d2.val; */ x = d1.sym->u.val; x %= (long) d2.val; - d2.val = d1.sym->u.val = x; + d2.val = x; + d1.sym->u.val = x; d1.sym->type = VAR; - push(d2); + + /* push(d2) generates a compiler error on Linux w. gcc 2.95.4 */ + ppush(&d2); } void diff --git a/src/cmd/hoc/mkfile b/src/cmd/hoc/mkfile index a226a5e8..d3bfd274 100644 --- a/src/cmd/hoc/mkfile +++ b/src/cmd/hoc/mkfile @@ -15,6 +15,6 @@ OFILES=\ YFILES=hoc.y\ +SHORTLIB=bio 9 <$PLAN9/src/mkone -LDFLAGS=$LDFLAGS -lbio -l9 diff --git a/src/cmd/mk/mkfile b/src/cmd/mk/mkfile index dca7c9d4..9b054053 100644 --- a/src/cmd/mk/mkfile +++ b/src/cmd/mk/mkfile @@ -31,7 +31,7 @@ HFILES=\ mk.h\ fns.h\ -LDFLAGS=$LDFLAGS -lregexp9 -lbio -l9 +SHORTLIB=regexp9 bio 9 <$PLAN9/src/mkone diff --git a/src/cmd/mkfile b/src/cmd/mkfile index dbdc1ed4..191ecfe3 100644 --- a/src/cmd/mkfile +++ b/src/cmd/mkfile @@ -2,7 +2,8 @@ PLAN9=../.. <$PLAN9/src/mkhdr TARG=`ls *.c | sed 's/\.c//'` -LDFLAGS=$LDFLAGS -lsec -lfs -lmux -lregexp9 -lthread -lbio -l9 +LDFLAGS=$LDFLAGS +SHORTLIB=sec fs mux regexp9 thread bio 9 <$PLAN9/src/mkmany diff --git a/src/cmd/plumb/mkfile b/src/cmd/plumb/mkfile index 81494416..967cbb3b 100644 --- a/src/cmd/plumb/mkfile +++ b/src/cmd/plumb/mkfile @@ -2,6 +2,7 @@ PLAN9=../../.. <$PLAN9/src/mkhdr TARG=plumber plumb +SHORTLIB=plumb fs mux thread regexp9 bio 9 <$PLAN9/src/mkmany @@ -14,4 +15,3 @@ $PLUMB: $HFILES $O.plumb: $PLUMB $O.plumber: $PLUMBER -LDFLAGS=$LDFLAGS -lplumb -lfs -lmux -lthread -lregexp9 -lbio -l9 diff --git a/src/cmd/rc/mkfile b/src/cmd/rc/mkfile index 38b84404..c1440ce4 100644 --- a/src/cmd/rc/mkfile +++ b/src/cmd/rc/mkfile @@ -31,8 +31,6 @@ HFILES=\ YFILES=syn.y -LDFLAGS=$LDFLAGS -l9 - <$PLAN9/src/mkone x.tab.h: y.tab.h diff --git a/src/cmd/sam/mkfile b/src/cmd/sam/mkfile index febebc5e..aa9a59f4 100644 --- a/src/cmd/sam/mkfile +++ b/src/cmd/sam/mkfile @@ -28,6 +28,4 @@ HFILES=sam.h\ errors.h\ mesg.h\ -LDFLAGS=$LDFLAGS -l9 - <$PLAN9/src/mkone diff --git a/src/cmd/samterm/mkfile b/src/cmd/samterm/mkfile index 9aea7a98..67997f39 100644 --- a/src/cmd/samterm/mkfile +++ b/src/cmd/samterm/mkfile @@ -22,9 +22,7 @@ HFILES=\ $PLAN9/include/draw.h\ CFLAGS=$CFLAGS -I../sam -LDFLAGS=$LDFLAGS -lframe -ldraw -lthread -lregexp9 \ - -lbio -l9 -L$X11/lib -lX11 -lm - -o.samterm: $PLAN9/lib/libframe.a $PLAN9/lib/libdraw.a $PLAN9/lib/libthread.a +LDFLAGS=$LDFLAGS -L$X11/lib -lX11 -lm +SHORTLIB=frame draw thread regexp9 bio 9 <$PLAN9/src/mkone diff --git a/src/cmd/yacc.c b/src/cmd/yacc.c index d9e30761..0ff114bd 100644 --- a/src/cmd/yacc.c +++ b/src/cmd/yacc.c @@ -401,7 +401,7 @@ others(void) finput = Bopen(parser, OREAD); if(finput == 0) - error("cannot find parser %s", parser); + error("cannot open parser %s: %r", parser); warray("yyr1", levprd, nprod); aryfil(temp1, nprod, 0); PLOOP(1, i) |