From b4c9a78425ac098201096fe2b3045b9c12c0eb6d Mon Sep 17 00:00:00 2001 From: christos Date: Fri, 5 Feb 1999 07:52:51 +0000 Subject: [PATCH] PR/5577: Craig M. Chase: sh does not build with PARALLEL set. - Added YHEADER in Makefile, removed arith.h and adjusted the sources. --- bin/sh/Makefile | 3 ++- bin/sh/arith.h | 41 ----------------------------------------- bin/sh/arith.y | 6 +++--- bin/sh/arith_lex.l | 8 ++++---- bin/sh/expand.c | 5 ++--- bin/sh/expand.h | 8 +++++++- 6 files changed, 18 insertions(+), 53 deletions(-) delete mode 100644 bin/sh/arith.h diff --git a/bin/sh/Makefile b/bin/sh/Makefile index 370a8a689a79..8a93b08edbb2 100644 --- a/bin/sh/Makefile +++ b/bin/sh/Makefile @@ -1,6 +1,7 @@ -# $NetBSD: Makefile,v 1.46 1998/10/08 00:29:38 ross Exp $ +# $NetBSD: Makefile,v 1.47 1999/02/05 07:52:51 christos Exp $ # @(#)Makefile 8.4 (Berkeley) 5/5/95 +YHEADER=1 PROG= sh SHSRCS= alias.c cd.c echo.c error.c eval.c exec.c expand.c \ histedit.c input.c jobs.c mail.c main.c memalloc.c miscbltin.c \ diff --git a/bin/sh/arith.h b/bin/sh/arith.h deleted file mode 100644 index d40e14b1956a..000000000000 --- a/bin/sh/arith.h +++ /dev/null @@ -1,41 +0,0 @@ -/* $NetBSD: arith.h,v 1.2 1997/07/04 21:01:49 christos Exp $ */ - -/*- - * Copyright (c) 1995 - * The Regents of the University of California. All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in the - * documentation and/or other materials provided with the distribution. - * 3. All advertising materials mentioning features or use of this software - * must display the following acknowledgement: - * This product includes software developed by the University of - * California, Berkeley and its contributors. - * 4. Neither the name of the University nor the names of its contributors - * may be used to endorse or promote products derived from this software - * without specific prior written permission. - * - * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND - * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE - * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE - * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL - * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS - * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) - * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT - * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY - * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * - * @(#)arith.h 1.1 (Berkeley) 5/4/95 - */ - -int arith __P((char *)); -int expcmd __P((int , char **)); -void arith_lex_reset __P((void)); -int yylex __P((void)); diff --git a/bin/sh/arith.y b/bin/sh/arith.y index e62b88434c68..7e0eeddb43b6 100644 --- a/bin/sh/arith.y +++ b/bin/sh/arith.y @@ -1,5 +1,5 @@ %{ -/* $NetBSD: arith.y,v 1.11 1998/07/28 11:41:52 mycroft Exp $ */ +/* $NetBSD: arith.y,v 1.12 1999/02/05 07:52:52 christos Exp $ */ /*- * Copyright (c) 1993 @@ -42,12 +42,12 @@ #if 0 static char sccsid[] = "@(#)arith.y 8.3 (Berkeley) 5/4/95"; #else -__RCSID("$NetBSD: arith.y,v 1.11 1998/07/28 11:41:52 mycroft Exp $"); +__RCSID("$NetBSD: arith.y,v 1.12 1999/02/05 07:52:52 christos Exp $"); #endif #endif /* not lint */ #include -#include "arith.h" +#include "expand.h" #include "shell.h" #include "error.h" #include "output.h" diff --git a/bin/sh/arith_lex.l b/bin/sh/arith_lex.l index 769af0a2e938..7a4b68abb9cc 100644 --- a/bin/sh/arith_lex.l +++ b/bin/sh/arith_lex.l @@ -1,5 +1,5 @@ %{ -/* $NetBSD: arith_lex.l,v 1.9 1998/05/18 22:50:20 christos Exp $ */ +/* $NetBSD: arith_lex.l,v 1.10 1999/02/05 07:52:52 christos Exp $ */ /*- * Copyright (c) 1993 @@ -42,14 +42,14 @@ #if 0 static char sccsid[] = "@(#)arith_lex.l 8.3 (Berkeley) 5/4/95"; #else -__RCSID("$NetBSD: arith_lex.l,v 1.9 1998/05/18 22:50:20 christos Exp $"); +__RCSID("$NetBSD: arith_lex.l,v 1.10 1999/02/05 07:52:52 christos Exp $"); #endif #endif /* not lint */ #include -#include "y.tab.h" -#include "error.h" #include "arith.h" +#include "error.h" +#include "expand.h" extern int yylval; extern char *arith_buf, *arith_startbuf; diff --git a/bin/sh/expand.c b/bin/sh/expand.c index bae5cbeb59b0..bc2e7c87f6ee 100644 --- a/bin/sh/expand.c +++ b/bin/sh/expand.c @@ -1,4 +1,4 @@ -/* $NetBSD: expand.c,v 1.42 1999/01/25 14:20:56 mycroft Exp $ */ +/* $NetBSD: expand.c,v 1.43 1999/02/05 07:52:52 christos Exp $ */ /*- * Copyright (c) 1991, 1993 @@ -41,7 +41,7 @@ #if 0 static char sccsid[] = "@(#)expand.c 8.5 (Berkeley) 5/15/95"; #else -__RCSID("$NetBSD: expand.c,v 1.42 1999/01/25 14:20:56 mycroft Exp $"); +__RCSID("$NetBSD: expand.c,v 1.43 1999/02/05 07:52:52 christos Exp $"); #endif #endif /* not lint */ @@ -75,7 +75,6 @@ __RCSID("$NetBSD: expand.c,v 1.42 1999/01/25 14:20:56 mycroft Exp $"); #include "memalloc.h" #include "error.h" #include "mystring.h" -#include "arith.h" #include "show.h" /* diff --git a/bin/sh/expand.h b/bin/sh/expand.h index d104bbaafeb3..d9c0762fd63a 100644 --- a/bin/sh/expand.h +++ b/bin/sh/expand.h @@ -1,4 +1,4 @@ -/* $NetBSD: expand.h,v 1.9 1998/01/31 12:45:07 christos Exp $ */ +/* $NetBSD: expand.h,v 1.10 1999/02/05 07:52:52 christos Exp $ */ /*- * Copyright (c) 1991, 1993 @@ -67,3 +67,9 @@ void expari __P((int)); int patmatch __P((char *, char *)); void rmescapes __P((char *)); int casematch __P((union node *, char *)); + +/* From arith.y */ +int arith __P((char *)); +int expcmd __P((int , char **)); +void arith_lex_reset __P((void)); +int yylex __P((void));