Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/usr.bin/make make(1): normalize whitespace in source code
details: https://anonhg.NetBSD.org/src/rev/64251b563e0b
branches: trunk
changeset: 1014645:64251b563e0b
user: rillig <rillig%NetBSD.org@localhost>
date: Sun Sep 27 21:35:16 2020 +0000
description:
make(1): normalize whitespace in source code
There is no more space tab. Either only tabs or only spaces or tabs
followed by spaces, but not spaces followed by tabs.
diffstat:
usr.bin/make/arch.c | 81 ++++----
usr.bin/make/compat.c | 50 ++--
usr.bin/make/cond.c | 10 +-
usr.bin/make/dir.c | 66 +++---
usr.bin/make/dir.h | 10 +-
usr.bin/make/for.c | 7 +-
usr.bin/make/hash.c | 16 +-
usr.bin/make/hash.h | 16 +-
usr.bin/make/job.c | 209 ++++++++++----------
usr.bin/make/job.h | 54 ++--
usr.bin/make/lst.c | 6 +-
usr.bin/make/main.c | 20 +-
usr.bin/make/make.c | 66 +++---
usr.bin/make/make.h | 66 +++---
usr.bin/make/parse.c | 261 +++++++++++++-------------
usr.bin/make/suff.c | 210 ++++++++++----------
usr.bin/make/targ.c | 93 ++++----
usr.bin/make/unit-tests/cond-func-defined.mk | 6 +-
usr.bin/make/unit-tests/cond-func.mk | 6 +-
usr.bin/make/unit-tests/posix1.mk | 4 +-
usr.bin/make/var.c | 64 +++---
21 files changed, 667 insertions(+), 654 deletions(-)
diffs (truncated from 2395 to 300 lines):
diff -r 239d4766c744 -r 64251b563e0b usr.bin/make/arch.c
--- a/usr.bin/make/arch.c Sun Sep 27 21:19:36 2020 +0000
+++ b/usr.bin/make/arch.c Sun Sep 27 21:35:16 2020 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: arch.c,v 1.123 2020/09/26 16:00:12 rillig Exp $ */
+/* $NetBSD: arch.c,v 1.124 2020/09/27 21:35:16 rillig Exp $ */
/*
* Copyright (c) 1988, 1989, 1990, 1993
@@ -79,41 +79,42 @@
* is referenced.
*
* The interface to this module is:
- * Arch_ParseArchive Given an archive specification, return a list
- * of GNode's, one for each member in the spec.
- * FALSE is returned if the specification is
- * invalid for some reason.
+ * Arch_ParseArchive
+ * Given an archive specification, return a list
+ * of GNode's, one for each member in the spec.
+ * FALSE is returned if the specification is
+ * invalid for some reason.
*
- * Arch_Touch Alter the modification time of the archive
- * member described by the given node to be
- * the current time.
+ * Arch_Touch Alter the modification time of the archive
+ * member described by the given node to be
+ * the current time.
*
- * Arch_TouchLib Update the modification time of the library
- * described by the given node. This is special
- * because it also updates the modification time
- * of the library's table of contents.
+ * Arch_TouchLib Update the modification time of the library
+ * described by the given node. This is special
+ * because it also updates the modification time
+ * of the library's table of contents.
*
- * Arch_MTime Find the modification time of a member of
- * an archive *in the archive*. The time is also
- * placed in the member's GNode. Returns the
- * modification time.
+ * Arch_MTime Find the modification time of a member of
+ * an archive *in the archive*. The time is also
+ * placed in the member's GNode. Returns the
+ * modification time.
*
- * Arch_MemTime Find the modification time of a member of
- * an archive. Called when the member doesn't
- * already exist. Looks in the archive for the
- * modification time. Returns the modification
- * time.
+ * Arch_MemTime Find the modification time of a member of
+ * an archive. Called when the member doesn't
+ * already exist. Looks in the archive for the
+ * modification time. Returns the modification
+ * time.
*
- * Arch_FindLib Search for a library along a path. The
- * library name in the GNode should be in
- * -l<name> format.
+ * Arch_FindLib Search for a library along a path. The
+ * library name in the GNode should be in
+ * -l<name> format.
*
- * Arch_LibOODate Special function to decide if a library node
- * is out-of-date.
+ * Arch_LibOODate Special function to decide if a library node
+ * is out-of-date.
*
- * Arch_Init Initialize this module.
+ * Arch_Init Initialize this module.
*
- * Arch_End Cleanup this module.
+ * Arch_End Cleanup this module.
*/
#include <sys/types.h>
@@ -133,7 +134,7 @@
#include "config.h"
/* "@(#)arch.c 8.2 (Berkeley) 1/2/94" */
-MAKE_RCSID("$NetBSD: arch.c,v 1.123 2020/09/26 16:00:12 rillig Exp $");
+MAKE_RCSID("$NetBSD: arch.c,v 1.124 2020/09/27 21:35:16 rillig Exp $");
#ifdef TARGET_MACHINE
#undef MAKE_MACHINE
@@ -208,13 +209,13 @@
Boolean
Arch_ParseArchive(char **linePtr, GNodeList *nodeLst, GNode *ctxt)
{
- char *cp; /* Pointer into line */
- GNode *gn; /* New node */
- char *libName; /* Library-part of specification */
- char *memName; /* Member-part of specification */
- char saveChar; /* Ending delimiter of member-name */
- Boolean subLibName; /* TRUE if libName should have/had
- * variable substitution performed on it */
+ char *cp; /* Pointer into line */
+ GNode *gn; /* New node */
+ char *libName; /* Library-part of specification */
+ char *memName; /* Member-part of specification */
+ char saveChar; /* Ending delimiter of member-name */
+ Boolean subLibName; /* TRUE if libName should have/had
+ * variable substitution performed on it */
libName = *linePtr;
@@ -946,7 +947,7 @@
{
#ifdef RANLIBMAG
FILE * arch; /* Stream open to archive */
- struct ar_hdr arh; /* Header describing table of contents */
+ struct ar_hdr arh; /* Header describing table of contents */
struct utimbuf times; /* Times for utime() call */
arch = ArchFindMember(gn->path, RANLIBMAG, &arh, "r+");
@@ -1104,7 +1105,7 @@
Boolean
Arch_LibOODate(GNode *gn)
{
- Boolean oodate;
+ Boolean oodate;
if (gn->type & OP_PHONY) {
oodate = TRUE;
@@ -1116,8 +1117,8 @@
oodate = TRUE;
} else {
#ifdef RANLIBMAG
- struct ar_hdr *arhPtr; /* Header for __.SYMDEF */
- int modTimeTOC; /* The table-of-contents's mod time */
+ struct ar_hdr *arhPtr; /* Header for __.SYMDEF */
+ int modTimeTOC; /* The table-of-contents's mod time */
arhPtr = ArchStatMember(gn->path, RANLIBMAG, FALSE);
diff -r 239d4766c744 -r 64251b563e0b usr.bin/make/compat.c
--- a/usr.bin/make/compat.c Sun Sep 27 21:19:36 2020 +0000
+++ b/usr.bin/make/compat.c Sun Sep 27 21:35:16 2020 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: compat.c,v 1.155 2020/09/27 11:43:46 rillig Exp $ */
+/* $NetBSD: compat.c,v 1.156 2020/09/27 21:35:16 rillig Exp $ */
/*
* Copyright (c) 1988, 1989, 1990 The Regents of the University of California.
@@ -78,8 +78,8 @@
* - friendly variable substitution.
*
* Interface:
- * Compat_Run Initialize things for this module and recreate
- * thems as need creatin'
+ * Compat_Run Initialize things for this module and recreate
+ * thems as need creatin'
*/
#include <sys/types.h>
@@ -99,7 +99,7 @@
#include "pathnames.h"
/* "@(#)compat.c 8.2 (Berkeley) 3/19/94" */
-MAKE_RCSID("$NetBSD: compat.c,v 1.155 2020/09/27 11:43:46 rillig Exp $");
+MAKE_RCSID("$NetBSD: compat.c,v 1.156 2020/09/27 21:35:16 rillig Exp $");
static GNode *curTarg = NULL;
static void CompatInterrupt(int);
@@ -187,21 +187,21 @@
int
Compat_RunCommand(const char *cmdp, struct GNode *gn)
{
- char *cmdStart; /* Start of expanded command */
- char *bp;
- Boolean silent, /* Don't print command */
- doIt; /* Execute even if -n */
- volatile Boolean errCheck; /* Check errors */
- int reason; /* Reason for child's death */
- int status; /* Description of child's death */
- pid_t cpid; /* Child actually found */
- pid_t retstat; /* Result of wait */
- StringListNode *cmdNode; /* Node where current command is located */
- const char ** volatile av; /* Argument vector for thing to exec */
- char ** volatile mav;/* Copy of the argument vector for freeing */
- Boolean useShell; /* TRUE if command should be executed
+ char *cmdStart; /* Start of expanded command */
+ char *bp;
+ Boolean silent; /* Don't print command */
+ Boolean doIt; /* Execute even if -n */
+ volatile Boolean errCheck; /* Check errors */
+ int reason; /* Reason for child's death */
+ int status; /* Description of child's death */
+ pid_t cpid; /* Child actually found */
+ pid_t retstat; /* Result of wait */
+ StringListNode *cmdNode; /* Node where current command is located */
+ const char **volatile av; /* Argument vector for thing to exec */
+ char **volatile mav; /* Copy of the argument vector for freeing */
+ Boolean useShell; /* TRUE if command should be executed
* using a shell */
- const char * volatile cmd = cmdp;
+ const char *volatile cmd = cmdp;
silent = (gn->type & OP_SILENT) != 0;
errCheck = !(gn->type & OP_IGNORE);
@@ -664,8 +664,8 @@
void
Compat_Run(GNodeList *targs)
{
- GNode *gn = NULL;/* Current root target */
- int errors; /* Number of targets not remade due to errors */
+ GNode *gn = NULL; /* Current root target */
+ int errors; /* Number of targets not remade due to errors */
if (!shellName)
Shell_Init();
@@ -712,11 +712,11 @@
* For each entry in the list of targets to create, call Compat_Make on
* it to create the thing. Compat_Make will leave the 'made' field of gn
* in one of several states:
- * UPTODATE gn was already up-to-date
- * MADE gn was recreated successfully
- * ERROR An error occurred while gn was being created
- * ABORTED gn was not remade because one of its inferiors
- * could not be made due to errors.
+ * UPTODATE gn was already up-to-date
+ * MADE gn was recreated successfully
+ * ERROR An error occurred while gn was being created
+ * ABORTED gn was not remade because one of its inferiors
+ * could not be made due to errors.
*/
errors = 0;
while (!Lst_IsEmpty(targs)) {
diff -r 239d4766c744 -r 64251b563e0b usr.bin/make/cond.c
--- a/usr.bin/make/cond.c Sun Sep 27 21:19:36 2020 +0000
+++ b/usr.bin/make/cond.c Sun Sep 27 21:35:16 2020 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: cond.c,v 1.152 2020/09/26 16:00:12 rillig Exp $ */
+/* $NetBSD: cond.c,v 1.153 2020/09/27 21:35:16 rillig Exp $ */
/*
* Copyright (c) 1988, 1989, 1990 The Regents of the University of California.
@@ -72,7 +72,7 @@
/* Handling of conditionals in a makefile.
*
* Interface:
- * Cond_EvalLine Evaluate the conditional in the passed line.
+ * Cond_EvalLine Evaluate the conditional in the passed line.
*
* Cond_EvalCondition
* Evaluate the conditional in the passed line, which
@@ -93,7 +93,7 @@
#include "dir.h"
/* "@(#)cond.c 8.2 (Berkeley) 1/2/94" */
-MAKE_RCSID("$NetBSD: cond.c,v 1.152 2020/09/26 16:00:12 rillig Exp $");
+MAKE_RCSID("$NetBSD: cond.c,v 1.153 2020/09/27 21:35:16 rillig Exp $");
/*
* The parsing of conditional expressions is based on this grammar:
@@ -1007,7 +1007,7 @@
*
* Results:
* COND_PARSE if the condition was valid grammatically
- * COND_INVALID if not a valid conditional.
+ * COND_INVALID if not a valid conditional.
*
* (*value) is set to the boolean value of the condition
*/
@@ -1069,7 +1069,7 @@
* COND_SKIP to skip the lines after the conditional
* (when .if or .elif returns FALSE, or when a previous
* branch has already been taken)
- * COND_INVALID if the conditional was not valid, either because of
+ * COND_INVALID if the conditional was not valid, either because of
* a syntax error or because some variable was undefined
* or because the condition could not be evaluated
*/
diff -r 239d4766c744 -r 64251b563e0b usr.bin/make/dir.c
--- a/usr.bin/make/dir.c Sun Sep 27 21:19:36 2020 +0000
+++ b/usr.bin/make/dir.c Sun Sep 27 21:35:16 2020 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: dir.c,v 1.148 2020/09/26 17:15:20 rillig Exp $ */
+/* $NetBSD: dir.c,v 1.149 2020/09/27 21:35:16 rillig Exp $ */
/*
* Copyright (c) 1988, 1989, 1990 The Regents of the University of California.
@@ -76,47 +76,49 @@
* implicit sources.
*
* The interface for this module is:
- * Dir_Init Initialize the module.
+ * Dir_Init Initialize the module.
*
- * Dir_InitCur Set the cur CachedDir.
+ * Dir_InitCur Set the cur CachedDir.
*
- * Dir_InitDot Set the dot CachedDir.
+ * Dir_InitDot Set the dot CachedDir.
*
- * Dir_End Cleanup the module.
+ * Dir_End Cleanup the module.
Home |
Main Index |
Thread Index |
Old Index