arg.h Public declarations for the above
array.c Numerically subscripted arrays
array.h Public declarations for the above
+cflags.SH A script that emits C compilation flags per file
client A client to test sockets
cmd.c Command interpreter
cmd.h Public declarations for the above
handy.h Handy definitions
hash.c Associative arrays
hash.h Public declarations for the above
+hints/3b2.sh
+hints/aix_rs.sh
+hints/aix_rt.sh
+hints/apollo_C6_7.sh
+hints/aux.sh
+hints/dnix.sh
+hints/dynix.sh
+hints/fps.sh
+hints/genix.sh
+hints/hp9000_300.sh
+hints/hp9000_400.sh
+hints/hpux.sh
+hints/i386.sh
+hints/mips.sh
+hints/ncr_tower.sh
+hints/next.sh
+hints/osf_1.sh
+hints/sco_2_3_0.sh
+hints/sco_2_3_1.sh
+hints/sco_2_3_2.sh
+hints/sco_2_3_3.sh
+hints/sco_3.sh
+hints/sgi.sh
+hints/sunos_3_4.sh
+hints/sunos_3_5.sh
+hints/sunos_4_0_1.sh
+hints/sunos_4_0_2.sh
+hints/ultrix_3.sh
+hints/ultrix_4.sh
+hints/uts.sh
installperl Perl script to do "make install" dirty work
ioctl.pl Sample ioctl.pl
lib/abbrev.pl An abbreviation table builder
echo "Extracting Makefile (with variable substitutions)"
cat >Makefile <<!GROK!THIS!
-# $Header: Makefile.SH,v 4.0 91/03/20 00:58:54 lwall Locked $
+# $RCSfile: Makefile.SH,v $$Revision: 4.0.1.1 $$Date: 91/04/11 17:30:39 $
#
# $Log: Makefile.SH,v $
+# Revision 4.0.1.1 91/04/11 17:30:39 lwall
+# patch1: C flags are now settable on a per-file basis
+#
# Revision 4.0 91/03/20 00:58:54 lwall
# 4.0 baseline.
#
privlib = $installprivlib
mansrc = $mansrc
manext = $manext
-CFLAGS = $ccflags $optimize
LDFLAGS = $ldflags
CLDFLAGS = $ldflags
SMALL = $small
!GROK!THIS!
cat >>Makefile <<'!NO!SUBS!'
+
+CFLAGS = `sh cflags.SH $@`
+
private =
scripts = h2ph
SHELL = /bin/sh
.c.o:
- $(CC) -c $(CFLAGS) $(LARGE) $*.c
+ $(CC) -c $(CFLAGS) $*.c
all: $(public) $(private) $(util) uperl.o $(scripts)
cd x2p; $(MAKE) all
# This is the standard version that contains no "taint" checks and is
# used for all scripts that aren't set-id or running under something set-id.
+# The $& notation is tells Sequent machines that it can do a parallel make,
+# and is harmless otherwise.
perl: $& perly.o $(obj) usersub.o
$(CC) $(LARGE) $(CLDFLAGS) $(obj) perly.o usersub.o $(libs) -o perl
tperly.o: perly.c perly.h $(h)
/bin/rm -f tperly.c
$(SLN) perly.c tperly.c
- $(CC) -c -DTAINT $(CFLAGS) $(LARGE) tperly.c
+ $(CC) -c -DTAINT $(CFLAGS) tperly.c
/bin/rm -f tperly.c
tperl.o: perl.c perly.h patchlevel.h perl.h $(h)
/bin/rm -f tperl.c
$(SLN) perl.c tperl.c
- $(CC) -c -DTAINT $(CFLAGS) $(LARGE) tperl.c
+ $(CC) -c -DTAINT $(CFLAGS) tperl.c
/bin/rm -f tperl.c
sperl.o: perl.c perly.h patchlevel.h $(h)
/bin/rm -f sperl.c
$(SLN) perl.c sperl.c
- $(CC) -c -DTAINT -DIAMSUID $(CFLAGS) $(LARGE) sperl.c
+ $(CC) -c -DTAINT -DIAMSUID $(CFLAGS) sperl.c
/bin/rm -f sperl.c
tarray.o: array.c $(h)
/bin/rm -f tarray.c
$(SLN) array.c tarray.c
- $(CC) -c -DTAINT $(CFLAGS) $(LARGE) tarray.c
+ $(CC) -c -DTAINT $(CFLAGS) tarray.c
/bin/rm -f tarray.c
tcmd.o: cmd.c $(h)
/bin/rm -f tcmd.c
$(SLN) cmd.c tcmd.c
- $(CC) -c -DTAINT $(CFLAGS) $(LARGE) tcmd.c
+ $(CC) -c -DTAINT $(CFLAGS) tcmd.c
/bin/rm -f tcmd.c
tcons.o: cons.c $(h) perly.h
/bin/rm -f tcons.c
$(SLN) cons.c tcons.c
- $(CC) -c -DTAINT $(CFLAGS) $(LARGE) tcons.c
+ $(CC) -c -DTAINT $(CFLAGS) tcons.c
/bin/rm -f tcons.c
tconsarg.o: consarg.c $(h)
/bin/rm -f tconsarg.c
$(SLN) consarg.c tconsarg.c
- $(CC) -c -DTAINT $(CFLAGS) $(LARGE) tconsarg.c
+ $(CC) -c -DTAINT $(CFLAGS) tconsarg.c
/bin/rm -f tconsarg.c
tdoarg.o: doarg.c $(h)
/bin/rm -f tdoarg.c
$(SLN) doarg.c tdoarg.c
- $(CC) -c -DTAINT $(CFLAGS) $(LARGE) tdoarg.c
+ $(CC) -c -DTAINT $(CFLAGS) tdoarg.c
/bin/rm -f tdoarg.c
tdoio.o: doio.c $(h)
/bin/rm -f tdoio.c
$(SLN) doio.c tdoio.c
- $(CC) -c -DTAINT $(CFLAGS) $(LARGE) tdoio.c
+ $(CC) -c -DTAINT $(CFLAGS) tdoio.c
/bin/rm -f tdoio.c
tdolist.o: dolist.c $(h)
/bin/rm -f tdolist.c
$(SLN) dolist.c tdolist.c
- $(CC) -c -DTAINT $(CFLAGS) $(LARGE) tdolist.c
+ $(CC) -c -DTAINT $(CFLAGS) tdolist.c
/bin/rm -f tdolist.c
tdump.o: dump.c $(h)
/bin/rm -f tdump.c
$(SLN) dump.c tdump.c
- $(CC) -c -DTAINT $(CFLAGS) $(LARGE) tdump.c
+ $(CC) -c -DTAINT $(CFLAGS) tdump.c
/bin/rm -f tdump.c
teval.o: eval.c $(h)
/bin/rm -f teval.c
$(SLN) eval.c teval.c
- $(CC) -c -DTAINT $(CFLAGS) $(LARGE) teval.c
+ $(CC) -c -DTAINT $(CFLAGS) teval.c
/bin/rm -f teval.c
tform.o: form.c $(h)
/bin/rm -f tform.c
$(SLN) form.c tform.c
- $(CC) -c -DTAINT $(CFLAGS) $(LARGE) tform.c
+ $(CC) -c -DTAINT $(CFLAGS) tform.c
/bin/rm -f tform.c
thash.o: hash.c $(h)
/bin/rm -f thash.c
$(SLN) hash.c thash.c
- $(CC) -c -DTAINT $(CFLAGS) $(LARGE) thash.c
+ $(CC) -c -DTAINT $(CFLAGS) thash.c
/bin/rm -f thash.c
tregcomp.o: regcomp.c $(h)
/bin/rm -f tregcomp.c
$(SLN) regcomp.c tregcomp.c
- $(CC) -c -DTAINT $(CFLAGS) $(LARGE) tregcomp.c
+ $(CC) -c -DTAINT $(CFLAGS) tregcomp.c
/bin/rm -f tregcomp.c
tregexec.o: regexec.c $(h)
/bin/rm -f tregexec.c
$(SLN) regexec.c tregexec.c
- $(CC) -c -DTAINT $(CFLAGS) $(LARGE) tregexec.c
+ $(CC) -c -DTAINT $(CFLAGS) tregexec.c
/bin/rm -f tregexec.c
tstab.o: stab.c $(h)
/bin/rm -f tstab.c
$(SLN) stab.c tstab.c
- $(CC) -c -DTAINT $(CFLAGS) $(LARGE) tstab.c
+ $(CC) -c -DTAINT $(CFLAGS) tstab.c
/bin/rm -f tstab.c
tstr.o: str.c $(h) perly.h
/bin/rm -f tstr.c
$(SLN) str.c tstr.c
- $(CC) -c -DTAINT $(CFLAGS) $(LARGE) tstr.c
+ $(CC) -c -DTAINT $(CFLAGS) tstr.c
/bin/rm -f tstr.c
ttoke.o: toke.c $(h) perly.h
/bin/rm -f ttoke.c
$(SLN) toke.c ttoke.c
- $(CC) -c -DTAINT $(CFLAGS) $(LARGE) ttoke.c
+ $(CC) -c -DTAINT $(CFLAGS) ttoke.c
/bin/rm -f ttoke.c
tutil.o: util.c $(h)
/bin/rm -f tutil.c
$(SLN) util.c tutil.c
- $(CC) -c -DTAINT $(CFLAGS) $(LARGE) tutil.c
+ $(CC) -c -DTAINT $(CFLAGS) tutil.c
/bin/rm -f tutil.c
perly.h: perly.c
echo 'extern YYSTYPE yylval;' >>perly.h
perly.o: perly.c perly.h $(h)
- $(CC) -c $(CFLAGS) $(LARGE) perly.c
+ $(CC) -c $(CFLAGS) perly.c
install: all
./perl installperl
Most of them should have been taken care of by running the Configure script.
If you have any additional changes to make to the C definitions, they
- can be done in the Makefile, or in config.h. Bear in mind that they will
- get undone next time you run Configure.
+ can be done in cflags.SH. For instance, to turn off the optimizer
+ on eval.c, find the line in the switch structure for eval.c and
+ put the command $optimize='-g' before the ;;. You will probably
+ want to change the entry for teval.c too. To change the C flags
+ for all the files, edit config.sh and change either $ccflags or $optimize.
3) make depend
Some compilers will not compile or optimize the larger files without
some extra switches to use larger jump offsets or allocate larger
- internal tables. It's okay to insert rules for specific files into
+ internal tables. You can customize the switches for each file in
+ cflags.SH. It's okay to insert rules for specific files into
Makefile.SH, since a default rule only takes effect in the
absence of a specific rule.
+ Most of the following hints are now done automatically by Configure.
+
The 3b2 needs to turn off -O.
Compilers with limited switch tables may have to define -DSMALLSWITCHES
Domain/OS 10.3 (at least) native C 6.7 may need -opt 2 for eval.c
SGI machines may need -Ddouble="long float" and -O1.
Vax-based systems may need to hand assemble teval.s with a -J switch.
Ultrix on MIPS machines may need -DLANGUAGE_C.
- Ultrix 4.0 on MIPS machines may need -Olimit 2820 or so.
+ Ultrix 4.0 on MIPS machines may need -Olimit 2900 or so.
Ultrix 3.[01] on MIPS needs to undefine WAITPID--the system call is busted.
MIPS machines may need to undef d_volatile.
MIPS machines may need to turn off -O on cmd.c, perl.c and tperl.c.
See the README in the t subdirectory. Note that you can't run it
in background if this disables opening of /dev/tty. If "make test"
bombs out, just cd to the t directory and run TEST by hand to see if
- it makes any difference.
+ it makes any difference. If individual tests bomb, you can run
+ them by hand, e.g., ./perl op/groups.t
6) make install
--- /dev/null
+case $CONFIG in
+'')
+ if test ! -f config.sh; then
+ ln ../config.sh . || \
+ ln ../../config.sh . || \
+ ln ../../../config.sh . || \
+ (echo "Can't find config.sh."; exit 1)
+ fi 2>/dev/null
+ . ./config.sh
+ ;;
+esac
+case "$0" in
+*/*) cd `expr X$0 : 'X\(.*\)/'` ;;
+esac
+
+also=': '
+case $# in
+1) also='echo 1>&2 " CFLAGS = "'
+esac
+
+case $# in
+0) set *.c; echo "The current C flags are:" ;;
+*) set `echo "$* " | sed 's/\.o /.c /g'`
+esac
+for file do
+
+ case "$#" in
+ 1) ;;
+ *) echo $n " $file $c" ;;
+ esac
+
+ case "$file" in
+ array.c) ;;
+ cmd.c) ;;
+ cons.c) ;;
+ consarg.c) ;;
+ doarg.c) ;;
+ doio.c) ;;
+ dolist.c) ;;
+ dump.c) ;;
+ eval.c) ;;
+ form.c) ;;
+ hash.c) ;;
+ malloc.c) ;;
+ perl.c) ;;
+ perly.c) ;;
+ regcomp.c) ;;
+ regexec.c) ;;
+ stab.c) ;;
+ str.c) ;;
+ toke.c) ;;
+ usersub.c) ;;
+ util.c) ;;
+ tarray.c) ;;
+ tcmd.c) ;;
+ tcons.c) ;;
+ tconsarg.c) ;;
+ tdoarg.c) ;;
+ tdoio.c) ;;
+ tdolist.c) ;;
+ tdump.c) ;;
+ teval.c) ;;
+ tform.c) ;;
+ thash.c) ;;
+ tmalloc.c) ;;
+ tperl.c) ;;
+ tperly.c) ;;
+ tregcomp.c) ;;
+ tregexec.c) ;;
+ tstab.c) ;;
+ tstr.c) ;;
+ ttoke.c) ;;
+ tusersub.c) ;;
+ tutil.c) ;;
+ *) ;;
+ esac
+
+ echo "$ccflags $optimize $large $split"
+ eval "$also $ccflags $optimize $large $split"
+done
-/* $Header: cmd.c,v 4.0 91/03/20 01:04:18 lwall Locked $
+/* $RCSfile: cmd.c,v $$Revision: 4.0.1.1 $$Date: 91/04/11 17:36:16 $
*
* Copyright (c) 1989, Larry Wall
*
* as specified in the README file that comes with the perl 3.0 kit.
*
* $Log: cmd.c,v $
+ * Revision 4.0.1.1 91/04/11 17:36:16 lwall
+ * patch1: you may now use "die" and "caller" in a signal handler
+ *
* Revision 4.0 91/03/20 01:04:18 lwall
* 4.0 baseline.
*
}
#ifdef DEBUGGING
-# ifndef VARARGS
+# ifndef I_VARARGS
/*VARARGS1*/
deb(pat,a1,a2,a3,a4,a5,a6,a7,a8)
char *pat;
}
void
+saveaptr(aptr)
+ARRAY **aptr;
+{
+ register STR *str;
+
+ str = Str_new(17,0);
+ str->str_state = SS_SAPTR;
+ str->str_u.str_array = *aptr; /* remember value */
+ if (str->str_ptr) {
+ Safefree(str->str_ptr);
+ str->str_len = 0;
+ }
+ str->str_ptr = (char*)aptr; /* remember pointer */
+ (void)apush(savestack,str);
+}
+
+void
savelist(sarg,maxsarg)
register STR **sarg;
int maxsarg;
value->str_ptr = Nullch;
str_free(value);
break;
+ case SS_SAPTR: /* ARRAY* reference */
+ *((ARRAY**)value->str_ptr) = value->str_u.str_array;
+ value->str_ptr = Nullch;
+ str_free(value);
+ break;
case SS_SNSTAB:
stab = (STAB*)value->str_magic;
value->str_magic = Nullstr;
*/
#define GIDTYPE $gidtype /**/
+/* GROUPSTYPE
+ * This symbol has a value like gid_t, int, ushort, or whatever type is
+ * used in the return value of getgroups().
+ */
+#define GROUPSTYPE $groupstype /**/
+
/* I_FCNTL
* This manifest constant tells the C program to include <fcntl.h>.
*/
#$i_my_dir I_MY_DIR /**/
#$d_dirnamlen DIRNAMLEN /**/
+/* MALLOCPTRTYPE
+ * This symbol defines the kind of ptr returned by malloc and realloc.
+ */
+#define MALLOCPTRTYPE $mallocptrtype /**/
+
/* RANDBITS
* This symbol contains the number of bits of random number the rand()
-/* $Header: consarg.c,v 4.0 91/03/20 01:06:15 lwall Locked $
+/* $RCSfile: consarg.c,v $$Revision: 4.0.1.1 $$Date: 91/04/11 17:38:34 $
*
* Copyright (c) 1989, Larry Wall
*
* as specified in the README file that comes with the perl 3.0 kit.
*
* $Log: consarg.c,v $
+ * Revision 4.0.1.1 91/04/11 17:38:34 lwall
+ * patch1: fixed "Bad free" error
+ *
* Revision 4.0 91/03/20 01:06:15 lwall
* 4.0 baseline.
*
if (str) {
arg->arg_type = O_ITEM; /* note arg1 type is already SINGLE */
str_free(s1);
- str_free(s2);
arg[1].arg_ptr.arg_str = str;
- arg[2].arg_ptr.arg_str = Nullstr;
- arg[2].arg_type = A_NULL;
+ if (s2) {
+ str_free(s2);
+ arg[2].arg_ptr.arg_str = Nullstr;
+ arg[2].arg_type = A_NULL;
+ }
}
}
}
-/* $Header: doarg.c,v 4.0 91/03/20 01:06:42 lwall Locked $
+/* $RCSfile: doarg.c,v $$Revision: 4.0.1.1 $$Date: 91/04/11 17:40:14 $
*
* Copyright (c) 1989, Larry Wall
*
* as specified in the README file that comes with the perl 3.0 kit.
*
* $Log: doarg.c,v $
+ * Revision 4.0.1.1 91/04/11 17:40:14 lwall
+ * patch1: fixed undefined environ problem
+ * patch1: fixed debugger coredump on subroutines
+ *
* Revision 4.0 91/03/20 01:06:42 lwall
* 4.0 baseline.
*
extern unsigned char fold[];
-#ifndef __STDC__
-extern char **environ;
-#endif /* ! __STDC__ */
-
#ifdef BUGGY_MSC
#pragma function(memcmp)
#endif /* BUGGY_MSC */
*t = '\0';
xs = str_get(*sarg);
xlen = (*sarg)->str_cur;
- if (*xs == 'S' && xs[1] == 't' && xs[2] == 'B'
- && xlen == sizeof(STBP) && strlen(xs) < xlen) {
+ if (*xs == 'S' && xs[1] == 't' && xs[2] == 'B' && xs[3] == '\0'
+ && xlen == sizeof(STBP)) {
STR *tmpstr = Str_new(24,0);
stab_fullname(tmpstr, ((STAB*)(*sarg))); /* a stab value! */
}
if (!stab)
fatal("Undefined subroutine called");
+ if (!(sub = stab_sub(stab))) {
+ STR *tmpstr = arg[0].arg_ptr.arg_str;
+
+ stab_fullname(tmpstr, stab);
+ fatal("Undefined subroutine \"%s\" called",tmpstr->str_ptr);
+ }
if (arg->arg_type == O_DBSUBR && !sub->usersub) {
str = stab_val(DBsub);
saveitem(str);
if (!sub)
fatal("No DBsub routine");
}
- else {
- if (!(sub = stab_sub(stab))) {
- STR *tmpstr = arg[0].arg_ptr.arg_str;
-
- stab_fullname(tmpstr, stab);
- fatal("Undefined subroutine \"%s\" called",tmpstr->str_ptr);
- }
- }
str = Str_new(15, sizeof(CSV));
str->str_state = SS_SCSV;
(void)apush(savestack,str);
-/* $Header: doio.c,v 4.0 91/03/20 01:07:06 lwall Locked $
+/* $RCSfile: doio.c,v $$Revision: 4.0.1.1 $$Date: 91/04/11 17:41:06 $
*
* Copyright (c) 1989, Larry Wall
*
* as specified in the README file that comes with the perl 3.0 kit.
*
* $Log: doio.c,v $
+ * Revision 4.0.1.1 91/04/11 17:41:06 lwall
+ * patch1: hopefully straightened out some of the Xenix mess
+ *
* Revision 4.0 91/03/20 01:07:06 lwall
* 4.0 baseline.
*
#include <netdb.h>
#endif
-#ifdef M_UNIX
-#if defined(HAS_SELECT) && !defined(I_SYS_TIME)
-#include <sys/select.h>
-#endif
-#endif
-
-#ifdef M_XENIX
#ifdef HAS_SELECT
+#ifdef I_SYS_SELECT
+#ifndef I_SYS_TIME
#include <sys/select.h>
#endif
#endif
+#endif
#if defined(HAS_MSG) || defined(HAS_SEM) || defined(HAS_SHM)
#include <sys/ipc.h>
#define NGROUPS 32
#endif
{
- GIDTYPE gary[NGROUPS];
+ GROUPSTYPE gary[NGROUPS];
int anum;
anum = getgroups(NGROUPS,gary);
-/* $Header: eval.c,v 4.0 91/03/20 01:16:48 lwall Locked $
+/* $RCSfile: eval.c,v $$Revision: 4.0.1.1 $$Date: 91/04/11 17:43:48 $
*
* Copyright (c) 1989, Larry Wall
*
* as specified in the README file that comes with the perl 3.0 kit.
*
* $Log: eval.c,v $
+ * Revision 4.0.1.1 91/04/11 17:43:48 lwall
+ * patch1: fixed failed fork to return undef as documented
+ * patch1: reduced maximum branch distance in eval.c
+ *
* Revision 4.0 91/03/20 01:16:48 lwall
* 4.0 baseline.
*
case O_FORK:
#ifdef HAS_FORK
anum = fork();
+ if (anum < 0)
+ goto say_undef;
if (!anum) {
if (tmpstab = stabent("$",allstabs))
str_numset(STAB_STR(tmpstab),(double)getpid());
else
value = (double)scanoct(tmps, 99, &argtype);
goto donumset;
+
+/* These common exits are hidden here in the middle of the switches for the
+/* benefit of those machines with limited branch addressing. Sigh. */
+
+array_return:
+#ifdef DEBUGGING
+ if (debug) {
+ dlevel--;
+ if (debug & 8) {
+ anum = sp - arglast[0];
+ switch (anum) {
+ case 0:
+ deb("%s RETURNS ()\n",opname[optype]);
+ break;
+ case 1:
+ deb("%s RETURNS (\"%s\")\n",opname[optype],str_get(st[1]));
+ break;
+ default:
+ tmps = str_get(st[1]);
+ deb("%s RETURNS %d ARGS (\"%s\",%s\"%s\")\n",opname[optype],
+ anum,tmps,anum==2?"":"...,",str_get(st[anum]));
+ break;
+ }
+ }
+ }
+#endif
+ return sp;
+
+say_yes:
+ str = &str_yes;
+ goto normal_return;
+
+say_no:
+ str = &str_no;
+ goto normal_return;
+
+say_undef:
+ str = &str_undef;
+ goto normal_return;
+
+say_zero:
+ value = 0.0;
+ /* FALL THROUGH */
+
+donumset:
+ str_numset(str,value);
+ STABSET(str);
+ st[1] = str;
+#ifdef DEBUGGING
+ if (debug) {
+ dlevel--;
+ if (debug & 8)
+ deb("%s RETURNS \"%f\"\n",opname[optype],value);
+ }
+#endif
+ return arglast[0] + 1;
#ifdef SMALLSWITCHES
}
else
}
#endif
return arglast[0] + 1;
-
-array_return:
-#ifdef DEBUGGING
- if (debug) {
- dlevel--;
- if (debug & 8) {
- anum = sp - arglast[0];
- switch (anum) {
- case 0:
- deb("%s RETURNS ()\n",opname[optype]);
- break;
- case 1:
- deb("%s RETURNS (\"%s\")\n",opname[optype],str_get(st[1]));
- break;
- default:
- tmps = str_get(st[1]);
- deb("%s RETURNS %d ARGS (\"%s\",%s\"%s\")\n",opname[optype],
- anum,tmps,anum==2?"":"...,",str_get(st[anum]));
- break;
- }
- }
- }
-#endif
- return sp;
-
-say_yes:
- str = &str_yes;
- goto normal_return;
-
-say_no:
- str = &str_no;
- goto normal_return;
-
-say_undef:
- str = &str_undef;
- goto normal_return;
-
-say_zero:
- value = 0.0;
- /* FALL THROUGH */
-
-donumset:
- str_numset(str,value);
- STABSET(str);
- st[1] = str;
-#ifdef DEBUGGING
- if (debug) {
- dlevel--;
- if (debug & 8)
- deb("%s RETURNS \"%f\"\n",opname[optype],value);
- }
-#endif
- return arglast[0] + 1;
}
--- /dev/null
+optimize='-g'
--- /dev/null
+optimize='-g'
--- /dev/null
+ccflags="$ccflags -a -DCRIPPLED_CC"
--- /dev/null
+optimize='-opt 2'
--- /dev/null
+optimize='-O'
+ccflags="$ccflags -B/usr/lib/bin/'
--- /dev/null
+optimize='-g'
--- /dev/null
+d_castneg=undef
--- /dev/null
+ccflags="$ccflags -J -DBADSWITCH"
--- /dev/null
+i_varargs=undef
--- /dev/null
+optimize='+O1'
+ccflags="$ccflags -Wc,-Nw500"
--- /dev/null
+optimize='+O1'
+ccflags="$ccflags -Wc,-Nw500"
--- /dev/null
+d_syscall=$undef
+echo " "
+echo "NOTE: regression test op.read may fail due to an NFS bug in HP/UX."
+echo "If so, don't worry about it."
--- /dev/null
+ldflags='-L/usr/ucblib'
}
print ")\n";
}
- if ($key ne "_$package" && defined %entry) {
+ if ($key ne "_$package" && $key ne "_DB" && defined %entry) {
print "\%$key = (\n";
foreach $key (sort keys(%entry)) {
print " $key\t'",&unctrl($entry{$key}),"'\n";
-#define PATCHLEVEL 0
+#define PATCHLEVEL 1
have to worry about removing the extra print statements later since TEST
ignores lines beginning with '#'.
-If you come up with new tests, send them to lwall@jpl-devvax.jpl.nasa.gov.
+If you come up with new tests, send them to lwall@netlabs.com.
}
if (@ARGV) {
if ($ARGV[0] eq '-o') {
- local($indent) = $indent - 4;
+ $statdone = 0 if $indent == 1 && $delayedstat;
+ $saw_or++;
$out .= "\n" . &tab . "||\n";
shift;
}
next if $_ eq '.';
next if $_ eq '..';
$name = "$dir/$_";
+ $nlink = 0;
&wanted;
}
}
local($tabstring);
$tabstring = "\t" x ($indent / 2) . ' ' x ($indent % 2 * 4);
- if ($_ !~ /^(name|print)/) {
- if (!$statdone) {
- $tabstring .= <<'ENDOFSTAT' . $tabstring;
+ if (!$statdone) {
+ if ($_ =~ /^(name|print)/) {
+ $delayedstat++;
+ }
+ else {
+ if ($saw_or) {
+ $tabstring .= <<'ENDOFSTAT' . $tabstring;
+($nlink || (($dev,$ino,$mode,$nlink,$uid,$gid) = lstat($_))) &&
+ENDOFSTAT
+ }
+ else {
+ $tabstring .= <<'ENDOFSTAT' . $tabstring;
(($dev,$ino,$mode,$nlink,$uid,$gid) = lstat($_)) &&
ENDOFSTAT
+ }
$statdone = 1;
}
}
sub n {
local($n) = @_;
- $n =~ s/^-0*/< / || $n =~ s/^\+0*/> / || $n =~ s/^0*/== /;
+ $n =~ s/^-/< / || $n =~ s/^\+/> / || $n =~ s/^/== /;
+ $n =~ s/ 0*(\d)/ $1/;
$n;
}
-/* $Header: handy.h,v 4.0 91/03/20 01:57:45 lwall Locked $
+/* $RCSfile: handy.h,v $$Revision: 4.0.1.1 $$Date: 91/04/12 09:29:08 $
*
* Copyright (c) 1989, Larry Wall
*
* as specified in the README file that comes with the perl 3.0 kit.
*
* $Log: handy.h,v $
+ * Revision 4.0.1.1 91/04/12 09:29:08 lwall
+ * patch1: random cleanup in cpp namespace
+ *
* Revision 4.0 91/03/20 01:57:45 lwall
* 4.0 baseline.
*
#define Nullfp Null(FILE*)
#define bool char
+#ifdef TRUE
+#undef TRUE
+#endif
+#ifdef FALSE
+#undef FALSE
+#endif
#define TRUE (1)
#define FALSE (0)