Module Name:    src
Committed By:   dholland
Date:           Fri Jun 19 06:02:31 UTC 2015

Modified Files:
        src/games/atc: extern.c extern.h grammar.y graphics.c input.c lex.l
            list.c log.c main.c update.c
Removed Files:
        src/games/atc: include.h

Log Message:
Abolish the foul practice of including every header in existence via a
single central "include.h". Use only headers that are actually needed.


To generate a diff of this commit:
cvs rdiff -u -r1.11 -r1.12 src/games/atc/extern.c src/games/atc/grammar.y
cvs rdiff -u -r1.17 -r1.18 src/games/atc/extern.h
cvs rdiff -u -r1.18 -r1.19 src/games/atc/graphics.c
cvs rdiff -u -r1.9 -r0 src/games/atc/include.h
cvs rdiff -u -r1.28 -r1.29 src/games/atc/input.c
cvs rdiff -u -r1.8 -r1.9 src/games/atc/lex.l src/games/atc/list.c
cvs rdiff -u -r1.21 -r1.22 src/games/atc/log.c
cvs rdiff -u -r1.22 -r1.23 src/games/atc/main.c
cvs rdiff -u -r1.25 -r1.26 src/games/atc/update.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/games/atc/extern.c
diff -u src/games/atc/extern.c:1.11 src/games/atc/extern.c:1.12
--- src/games/atc/extern.c:1.11	Wed Aug 12 04:48:03 2009
+++ src/games/atc/extern.c	Fri Jun 19 06:02:31 2015
@@ -1,4 +1,4 @@
-/*	$NetBSD: extern.c,v 1.11 2009/08/12 04:48:03 dholland Exp $	*/
+/*	$NetBSD: extern.c,v 1.12 2015/06/19 06:02:31 dholland Exp $	*/
 
 /*-
  * Copyright (c) 1990, 1993
@@ -46,11 +46,16 @@
 #if 0
 static char sccsid[] = "@(#)extern.c	8.1 (Berkeley) 5/31/93";
 #else
-__RCSID("$NetBSD: extern.c,v 1.11 2009/08/12 04:48:03 dholland Exp $");
+__RCSID("$NetBSD: extern.c,v 1.12 2015/06/19 06:02:31 dholland Exp $");
 #endif
 #endif /* not lint */
 
-#include "include.h"
+#include <termios.h>
+
+#include "def.h"
+#include "struct.h"
+#include "extern.h"
+#include "tunable.h"
 
 char		GAMES[] =	"Game_List";
 
Index: src/games/atc/grammar.y
diff -u src/games/atc/grammar.y:1.11 src/games/atc/grammar.y:1.12
--- src/games/atc/grammar.y:1.11	Sat Mar 22 22:09:14 2014
+++ src/games/atc/grammar.y	Fri Jun 19 06:02:31 2015
@@ -1,4 +1,4 @@
-/*	$NetBSD: grammar.y,v 1.11 2014/03/22 22:09:14 dholland Exp $	*/
+/*	$NetBSD: grammar.y,v 1.12 2015/06/19 06:02:31 dholland Exp $	*/
 
 /*-
  * Copyright (c) 1990, 1993
@@ -57,17 +57,22 @@
 }
 
 %{
-#include "include.h"
-
 #include <sys/cdefs.h>
 #ifndef lint
 #if 0
 static char sccsid[] = "@(#)grammar.y	8.1 (Berkeley) 5/31/93";
 #else
-__RCSID("$NetBSD: grammar.y,v 1.11 2014/03/22 22:09:14 dholland Exp $");
+__RCSID("$NetBSD: grammar.y,v 1.12 2015/06/19 06:02:31 dholland Exp $");
 #endif
 #endif /* not lint */
 
+#include <stdio.h>
+
+#include "def.h"
+#include "struct.h"
+#include "extern.h"
+#include "tunable.h"
+
 int line = 1;
 
 static int errors = 0;

Index: src/games/atc/extern.h
diff -u src/games/atc/extern.h:1.17 src/games/atc/extern.h:1.18
--- src/games/atc/extern.h:1.17	Sat Mar 22 22:58:56 2014
+++ src/games/atc/extern.h	Fri Jun 19 06:02:31 2015
@@ -1,4 +1,4 @@
-/*	$NetBSD: extern.h,v 1.17 2014/03/22 22:58:56 dholland Exp $	*/
+/*	$NetBSD: extern.h,v 1.18 2015/06/19 06:02:31 dholland Exp $	*/
 
 /*-
  * Copyright (c) 1990, 1993
@@ -43,6 +43,9 @@
  * For more info on this and all of my stuff, mail [email protected].
  */
 
+#include <time.h>  /* for time_t */
+
+
 extern char		GAMES[];
 extern const char	*filename;
 

Index: src/games/atc/graphics.c
diff -u src/games/atc/graphics.c:1.18 src/games/atc/graphics.c:1.19
--- src/games/atc/graphics.c:1.18	Sat Mar 22 22:33:35 2014
+++ src/games/atc/graphics.c	Fri Jun 19 06:02:31 2015
@@ -1,4 +1,4 @@
-/*	$NetBSD: graphics.c,v 1.18 2014/03/22 22:33:35 dholland Exp $	*/
+/*	$NetBSD: graphics.c,v 1.19 2015/06/19 06:02:31 dholland Exp $	*/
 
 /*-
  * Copyright (c) 1990, 1993
@@ -46,11 +46,20 @@
 #if 0
 static char sccsid[] = "@(#)graphics.c	8.1 (Berkeley) 5/31/93";
 #else
-__RCSID("$NetBSD: graphics.c,v 1.18 2014/03/22 22:33:35 dholland Exp $");
+__RCSID("$NetBSD: graphics.c,v 1.19 2015/06/19 06:02:31 dholland Exp $");
 #endif
 #endif /* not lint */
 
-#include "include.h"
+#include <stdio.h>
+#include <stdlib.h>
+#include <curses.h>
+#include <errno.h>
+#include <err.h>
+
+#include "def.h"
+#include "struct.h"
+#include "extern.h"
+#include "tunable.h"
 
 #define C_TOPBOTTOM		'-'
 #define C_LEFTRIGHT		'|'

Index: src/games/atc/input.c
diff -u src/games/atc/input.c:1.28 src/games/atc/input.c:1.29
--- src/games/atc/input.c:1.28	Sat Mar 22 22:58:56 2014
+++ src/games/atc/input.c	Fri Jun 19 06:02:31 2015
@@ -1,4 +1,4 @@
-/*	$NetBSD: input.c,v 1.28 2014/03/22 22:58:56 dholland Exp $	*/
+/*	$NetBSD: input.c,v 1.29 2015/06/19 06:02:31 dholland Exp $	*/
 
 /*-
  * Copyright (c) 1990, 1993
@@ -46,12 +46,26 @@
 #if 0
 static char sccsid[] = "@(#)input.c	8.1 (Berkeley) 5/31/93";
 #else
-__RCSID("$NetBSD: input.c,v 1.28 2014/03/22 22:58:56 dholland Exp $");
+__RCSID("$NetBSD: input.c,v 1.29 2015/06/19 06:02:31 dholland Exp $");
 #endif
 #endif /* not lint */
 
-#include "include.h"
+#include <sys/types.h>
+#include <sys/wait.h>
+#include <stdio.h>
+#include <stdlib.h>
+#include <string.h>
+#include <unistd.h>
+#include <termios.h>
+#include <ctype.h>
+#include <assert.h>
+#include <math.h>
+
 #include "pathnames.h"
+#include "def.h"
+#include "struct.h"
+#include "extern.h"
+#include "tunable.h"
 
 static void rezero(void);
 static void noise(void);

Index: src/games/atc/lex.l
diff -u src/games/atc/lex.l:1.8 src/games/atc/lex.l:1.9
--- src/games/atc/lex.l:1.8	Thu Oct 29 14:27:26 2009
+++ src/games/atc/lex.l	Fri Jun 19 06:02:31 2015
@@ -1,5 +1,5 @@
 %{
-/*	$NetBSD: lex.l,v 1.8 2009/10/29 14:27:26 christos Exp $	*/
+/*	$NetBSD: lex.l,v 1.9 2015/06/19 06:02:31 dholland Exp $	*/
 
 /*-
  * Copyright (c) 1990, 1993
@@ -47,11 +47,10 @@
 #if 0
 static char sccsid[] = "@(#)lex.l	8.1 (Berkeley) 5/31/93";
 #else
-__RCSID("$NetBSD: lex.l,v 1.8 2009/10/29 14:27:26 christos Exp $");
+__RCSID("$NetBSD: lex.l,v 1.9 2015/06/19 06:02:31 dholland Exp $");
 #endif
 #endif /* not lint */
 
-#include "include.h"
 #undef ECHO		/* XXX: work around lex(1) vs termios lameness */
 #include "grammar.h"
 
Index: src/games/atc/list.c
diff -u src/games/atc/list.c:1.8 src/games/atc/list.c:1.9
--- src/games/atc/list.c:1.8	Sat Mar 22 22:09:14 2014
+++ src/games/atc/list.c	Fri Jun 19 06:02:31 2015
@@ -1,4 +1,4 @@
-/*	$NetBSD: list.c,v 1.8 2014/03/22 22:09:14 dholland Exp $	*/
+/*	$NetBSD: list.c,v 1.9 2015/06/19 06:02:31 dholland Exp $	*/
 
 /*-
  * Copyright (c) 1990, 1993
@@ -46,11 +46,16 @@
 #if 0
 static char sccsid[] = "@(#)list.c	8.1 (Berkeley) 5/31/93";
 #else
-__RCSID("$NetBSD: list.c,v 1.8 2014/03/22 22:09:14 dholland Exp $");
+__RCSID("$NetBSD: list.c,v 1.9 2015/06/19 06:02:31 dholland Exp $");
 #endif
 #endif /* not lint */
 
-#include "include.h"
+#include <stdlib.h>
+
+#include "def.h"
+#include "struct.h"
+#include "extern.h"
+#include "tunable.h"
 
 PLANE *
 newplane(void)

Index: src/games/atc/log.c
diff -u src/games/atc/log.c:1.21 src/games/atc/log.c:1.22
--- src/games/atc/log.c:1.21	Wed Aug 12 04:48:03 2009
+++ src/games/atc/log.c	Fri Jun 19 06:02:31 2015
@@ -1,4 +1,4 @@
-/*	$NetBSD: log.c,v 1.21 2009/08/12 04:48:03 dholland Exp $	*/
+/*	$NetBSD: log.c,v 1.22 2015/06/19 06:02:31 dholland Exp $	*/
 
 /*-
  * Copyright (c) 1990, 1993
@@ -46,12 +46,25 @@
 #if 0
 static char sccsid[] = "@(#)log.c	8.1 (Berkeley) 5/31/93";
 #else
-__RCSID("$NetBSD: log.c,v 1.21 2009/08/12 04:48:03 dholland Exp $");
+__RCSID("$NetBSD: log.c,v 1.22 2015/06/19 06:02:31 dholland Exp $");
 #endif
 #endif /* not lint */
 
-#include "include.h"
+#include <sys/types.h>
+#include <sys/utsname.h>
+#include <stdio.h>
+#include <stdlib.h>
+#include <string.h>
+#include <unistd.h>
+#include <fcntl.h>
+#include <pwd.h>
+#include <err.h>
+
 #include "pathnames.h"
+#include "def.h"
+#include "struct.h"
+#include "extern.h"
+#include "tunable.h"
 
 static FILE *score_fp;
 

Index: src/games/atc/main.c
diff -u src/games/atc/main.c:1.22 src/games/atc/main.c:1.23
--- src/games/atc/main.c:1.22	Sat Mar 22 22:58:56 2014
+++ src/games/atc/main.c	Fri Jun 19 06:02:31 2015
@@ -1,4 +1,4 @@
-/*	$NetBSD: main.c,v 1.22 2014/03/22 22:58:56 dholland Exp $	*/
+/*	$NetBSD: main.c,v 1.23 2015/06/19 06:02:31 dholland Exp $	*/
 
 /*-
  * Copyright (c) 1990, 1993
@@ -51,12 +51,23 @@ __COPYRIGHT("@(#) Copyright (c) 1990, 19
 #if 0
 static char sccsid[] = "@(#)main.c	8.1 (Berkeley) 5/31/93";
 #else
-__RCSID("$NetBSD: main.c,v 1.22 2014/03/22 22:58:56 dholland Exp $");
+__RCSID("$NetBSD: main.c,v 1.23 2015/06/19 06:02:31 dholland Exp $");
 #endif
 #endif /* not lint */
 
-#include "include.h"
+#include <stdio.h>
+#include <stdlib.h>
+#include <string.h>
+#include <signal.h>
+#include <termios.h>
+#include <getopt.h>
+#include <err.h>
+
 #include "pathnames.h"
+#include "def.h"
+#include "struct.h"
+#include "extern.h"
+#include "tunable.h"
 
 extern FILE	*yyin;
 

Index: src/games/atc/update.c
diff -u src/games/atc/update.c:1.25 src/games/atc/update.c:1.26
--- src/games/atc/update.c:1.25	Sat Mar 22 22:58:56 2014
+++ src/games/atc/update.c	Fri Jun 19 06:02:31 2015
@@ -1,4 +1,4 @@
-/*	$NetBSD: update.c,v 1.25 2014/03/22 22:58:56 dholland Exp $	*/
+/*	$NetBSD: update.c,v 1.26 2015/06/19 06:02:31 dholland Exp $	*/
 
 /*-
  * Copyright (c) 1990, 1993
@@ -46,11 +46,19 @@
 #if 0
 static char sccsid[] = "@(#)update.c	8.1 (Berkeley) 5/31/93";
 #else
-__RCSID("$NetBSD: update.c,v 1.25 2014/03/22 22:58:56 dholland Exp $");
+__RCSID("$NetBSD: update.c,v 1.26 2015/06/19 06:02:31 dholland Exp $");
 #endif
 #endif /* not lint */
 
-#include "include.h"
+#include <stdio.h>
+#include <stdlib.h>
+#include <string.h>
+#include <ctype.h>
+
+#include "def.h"
+#include "struct.h"
+#include "extern.h"
+#include "tunable.h"
 
 static int next_plane(void);
 static int too_close(const PLANE *p1, const PLANE *p2, int);

Reply via email to