pkgsrc-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[pkgsrc/trunk]: pkgsrc/devel/bmake/files Import bmake-20080215
details: https://anonhg.NetBSD.org/pkgsrc/rev/27e39d965439
branches: trunk
changeset: 539620:27e39d965439
user: joerg <joerg%pkgsrc.org@localhost>
date: Sun Mar 09 19:39:31 2008 +0000
description:
Import bmake-20080215
diffstat:
devel/bmake/files/FILES | 6 +
devel/bmake/files/arch.c | 60 +-
devel/bmake/files/bmake.cat1 | 190 ++-
devel/bmake/files/buf.c | 6 +-
devel/bmake/files/buf.h | 2 +-
devel/bmake/files/dir.c | 121 +-
devel/bmake/files/dir.h | 2 +-
devel/bmake/files/for.c | 35 +-
devel/bmake/files/lst.h | 16 +-
devel/bmake/files/lst.lib/Makefile | 4 +-
devel/bmake/files/lst.lib/lstAppend.c | 14 +-
devel/bmake/files/lst.lib/lstAtEnd.c | 8 +-
devel/bmake/files/lst.lib/lstAtFront.c | 8 +-
devel/bmake/files/lst.lib/lstClose.c | 8 +-
devel/bmake/files/lst.lib/lstConcat.c | 10 +-
devel/bmake/files/lst.lib/lstDatum.c | 8 +-
devel/bmake/files/lst.lib/lstDeQueue.c | 10 +-
devel/bmake/files/lst.lib/lstDestroy.c | 8 +-
devel/bmake/files/lst.lib/lstDupl.c | 8 +-
devel/bmake/files/lst.lib/lstEnQueue.c | 10 +-
devel/bmake/files/lst.lib/lstFindFrom.c | 12 +-
devel/bmake/files/lst.lib/lstFirst.c | 8 +-
devel/bmake/files/lst.lib/lstForEach.c | 10 +-
devel/bmake/files/lst.lib/lstForEachFrom.c | 15 +-
devel/bmake/files/lst.lib/lstInit.c | 8 +-
devel/bmake/files/lst.lib/lstInsert.c | 14 +-
devel/bmake/files/lst.lib/lstIsAtEnd.c | 8 +-
devel/bmake/files/lst.lib/lstLast.c | 8 +-
devel/bmake/files/lst.lib/lstMember.c | 10 +-
devel/bmake/files/lst.lib/lstNext.c | 10 +-
devel/bmake/files/lst.lib/lstOpen.c | 12 +-
devel/bmake/files/lst.lib/lstPrev.c | 79 +
devel/bmake/files/lst.lib/lstRemove.c | 10 +-
devel/bmake/files/lst.lib/lstReplace.c | 8 +-
devel/bmake/files/lst.lib/lstSucc.c | 8 +-
devel/bmake/files/make-conf.h | 13 +-
devel/bmake/files/make.1 | 167 ++-
devel/bmake/files/make.c | 710 ++++++++---
devel/bmake/files/make.h | 90 +-
devel/bmake/files/nonints.h | 21 +-
devel/bmake/files/parse.c | 1685 +++++++++++----------------
devel/bmake/files/str.c | 16 +-
devel/bmake/files/suff.c | 574 ++++----
devel/bmake/files/targ.c | 294 +++-
devel/bmake/files/trace.c | 10 +-
devel/bmake/files/trace.h | 2 +-
devel/bmake/files/unit-tests/Makefile.in | 16 +-
devel/bmake/files/unit-tests/dotwait | 61 +
devel/bmake/files/unit-tests/export | 22 +
devel/bmake/files/unit-tests/export-all | 11 +
devel/bmake/files/unit-tests/moderrs | 31 +
devel/bmake/files/unit-tests/modmisc | 33 +
devel/bmake/files/unit-tests/modorder | 4 +-
devel/bmake/files/unit-tests/test.exp | 74 +-
devel/bmake/files/util.c | 56 +-
55 files changed, 2714 insertions(+), 1930 deletions(-)
diffs (truncated from 8477 to 300 lines):
diff -r 967bcf3b1b8d -r 27e39d965439 devel/bmake/files/FILES
--- a/devel/bmake/files/FILES Sun Mar 09 19:25:16 2008 +0000
+++ b/devel/bmake/files/FILES Sun Mar 09 19:39:31 2008 +0000
@@ -56,6 +56,7 @@
lst.lib/lstMember.c
lst.lib/lstNext.c
lst.lib/lstOpen.c
+lst.lib/lstPrev.c
lst.lib/lstRemove.c
lst.lib/lstReplace.c
lst.lib/lstSucc.c
@@ -84,6 +85,9 @@
unit-tests/Makefile.in
unit-tests/cond1
unit-tests/comment
+unit-tests/export
+unit-tests/export-all
+unit-tests/moderrs
unit-tests/modmatch
unit-tests/modorder
unit-tests/modts
@@ -92,3 +96,5 @@
unit-tests/ternary
unit-tests/test.exp
unit-tests/varcmd
+unit-tests/modmisc
+unit-tests/dotwait
diff -r 967bcf3b1b8d -r 27e39d965439 devel/bmake/files/arch.c
--- a/devel/bmake/files/arch.c Sun Mar 09 19:25:16 2008 +0000
+++ b/devel/bmake/files/arch.c Sun Mar 09 19:39:31 2008 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: arch.c,v 1.1.1.1 2005/12/02 00:02:59 sjg Exp $ */
+/* $NetBSD: arch.c,v 1.1.1.2 2008/03/09 19:39:32 joerg Exp $ */
/*
* Copyright (c) 1988, 1989, 1990, 1993
@@ -69,14 +69,14 @@
*/
#ifndef MAKE_NATIVE
-static char rcsid[] = "$NetBSD: arch.c,v 1.1.1.1 2005/12/02 00:02:59 sjg Exp $";
+static char rcsid[] = "$NetBSD: arch.c,v 1.1.1.2 2008/03/09 19:39:32 joerg Exp $";
#else
#include <sys/cdefs.h>
#ifndef lint
#if 0
static char sccsid[] = "@(#)arch.c 8.2 (Berkeley) 1/2/94";
#else
-__RCSID("$NetBSD: arch.c,v 1.1.1.1 2005/12/02 00:02:59 sjg Exp $");
+__RCSID("$NetBSD: arch.c,v 1.1.1.2 2008/03/09 19:39:32 joerg Exp $");
#endif
#endif /* not lint */
#endif
@@ -288,19 +288,18 @@
* so we can safely advance beyond it...
*/
int length;
- Boolean freeIt;
+ void *freeIt;
char *result;
- result=Var_Parse(cp, ctxt, TRUE, &length, &freeIt);
+ result = Var_Parse(cp, ctxt, TRUE, &length, &freeIt);
+ if (freeIt)
+ free(freeIt);
if (result == var_Error) {
return(FAILURE);
} else {
subLibName = TRUE;
}
- if (freeIt) {
- free(result);
- }
cp += length-1;
}
}
@@ -330,19 +329,18 @@
* so we can safely advance beyond it...
*/
int length;
- Boolean freeIt;
+ void *freeIt;
char *result;
- result=Var_Parse(cp, ctxt, TRUE, &length, &freeIt);
+ result = Var_Parse(cp, ctxt, TRUE, &length, &freeIt);
+ if (freeIt)
+ free(freeIt);
if (result == var_Error) {
return(FAILURE);
} else {
doSubst = TRUE;
}
- if (freeIt) {
- free(result);
- }
cp += length;
} else {
cp++;
@@ -412,7 +410,7 @@
return(FAILURE);
} else {
gn->type |= OP_ARCHV;
- (void)Lst_AtEnd(nodeLst, (ClientData)gn);
+ (void)Lst_AtEnd(nodeLst, gn);
}
} else if (Arch_ParseArchive(&sacrifice, nodeLst, ctxt)!=SUCCESS) {
/*
@@ -454,7 +452,7 @@
* end of the provided list.
*/
gn->type |= OP_ARCHV;
- (void)Lst_AtEnd(nodeLst, (ClientData)gn);
+ (void)Lst_AtEnd(nodeLst, gn);
}
}
Lst_Destroy(members, NOFREE);
@@ -476,7 +474,7 @@
* provided list.
*/
gn->type |= OP_ARCHV;
- (void)Lst_AtEnd(nodeLst, (ClientData)gn);
+ (void)Lst_AtEnd(nodeLst, gn);
}
}
if (doSubst) {
@@ -578,7 +576,7 @@
member = cp + 1;
}
- ln = Lst_Find(archives, (ClientData) archive, ArchFindArchive);
+ ln = Lst_Find(archives, archive, ArchFindArchive);
if (ln != NILLNODE) {
ar = (Arch *)Lst_Datum(ln);
@@ -589,7 +587,7 @@
} else {
/* Try truncated name */
char copy[AR_MAX_NAME_LEN+1];
- int len = strlen(member);
+ size_t len = strlen(member);
if (len > AR_MAX_NAME_LEN) {
len = AR_MAX_NAME_LEN;
@@ -711,7 +709,7 @@
memName[elen] = '\0';
fseek(arch, -elen, SEEK_CUR);
if (DEBUG(ARCH) || DEBUG(MAKE)) {
- printf("ArchStat: Extended format entry for %s\n", memName);
+ fprintf(debug_file, "ArchStat: Extended format entry for %s\n", memName);
}
}
#endif
@@ -725,7 +723,7 @@
fclose(arch);
- (void)Lst_AtEnd(archives, (ClientData) ar);
+ (void)Lst_AtEnd(archives, ar);
/*
* Now that the archive has been read and cached, we can look into
@@ -782,7 +780,7 @@
if (ar->fnametab != NULL) {
if (DEBUG(ARCH)) {
- printf("Attempted to redefine an SVR4 name table\n");
+ fprintf(debug_file, "Attempted to redefine an SVR4 name table\n");
}
return -1;
}
@@ -796,7 +794,7 @@
if (fread(ar->fnametab, size, 1, arch) != 1) {
if (DEBUG(ARCH)) {
- printf("Reading an SVR4 name table failed\n");
+ fprintf(debug_file, "Reading an SVR4 name table failed\n");
}
return -1;
}
@@ -815,7 +813,7 @@
break;
}
if (DEBUG(ARCH)) {
- printf("Found svr4 archive name table with %lu entries\n",
+ fprintf(debug_file, "Found svr4 archive name table with %lu entries\n",
(u_long)entry);
}
return 0;
@@ -827,20 +825,20 @@
entry = (size_t)strtol(&name[1], &eptr, 0);
if ((*eptr != ' ' && *eptr != '\0') || eptr == &name[1]) {
if (DEBUG(ARCH)) {
- printf("Could not parse SVR4 name %s\n", name);
+ fprintf(debug_file, "Could not parse SVR4 name %s\n", name);
}
return 2;
}
if (entry >= ar->fnamesize) {
if (DEBUG(ARCH)) {
- printf("SVR4 entry offset %s is greater than %lu\n",
+ fprintf(debug_file, "SVR4 entry offset %s is greater than %lu\n",
name, (u_long)ar->fnamesize);
}
return 2;
}
if (DEBUG(ARCH)) {
- printf("Replaced %s with %s\n", name, &ar->fnametab[entry]);
+ fprintf(debug_file, "Replaced %s with %s\n", name, &ar->fnametab[entry]);
}
(void)strncpy(name, &ar->fnametab[entry], MAXPATHLEN);
@@ -882,7 +880,7 @@
int size; /* Size of archive member */
char *cp; /* Useful character pointer */
char magic[SARMAG];
- int len, tlen;
+ size_t len, tlen;
arch = fopen(archive, mode);
if (arch == NULL) {
@@ -954,7 +952,7 @@
isdigit((unsigned char)arhPtr->AR_NAME[sizeof(AR_EFMT1) - 1])) {
unsigned int elen = atoi(&arhPtr->AR_NAME[sizeof(AR_EFMT1)-1]);
- char ename[MAXPATHLEN];
+ char ename[MAXPATHLEN + 1];
if (elen > MAXPATHLEN) {
fclose(arch);
@@ -966,7 +964,7 @@
}
ename[elen] = '\0';
if (DEBUG(ARCH) || DEBUG(MAKE)) {
- printf("ArchFind: Extended format entry for %s\n", ename);
+ fprintf(debug_file, "ArchFind: Extended format entry for %s\n", ename);
}
if (strncmp(ename, member, len) == 0) {
/* Found as extended name */
@@ -1290,7 +1288,7 @@
modTimeTOC = (int)strtol(arhPtr->AR_DATE, NULL, 10);
if (DEBUG(ARCH) || DEBUG(MAKE)) {
- printf("%s modified %s...", RANLIBMAG, Targ_FmtTime(modTimeTOC));
+ fprintf(debug_file, "%s modified %s...", RANLIBMAG, Targ_FmtTime(modTimeTOC));
}
oodate = (gn->cmtime > modTimeTOC);
} else {
@@ -1298,7 +1296,7 @@
* A library w/o a table of contents is out-of-date
*/
if (DEBUG(ARCH) || DEBUG(MAKE)) {
- printf("No t.o.c....");
+ fprintf(debug_file, "No t.o.c....");
}
oodate = TRUE;
}
diff -r 967bcf3b1b8d -r 27e39d965439 devel/bmake/files/bmake.cat1
--- a/devel/bmake/files/bmake.cat1 Sun Mar 09 19:25:16 2008 +0000
+++ b/devel/bmake/files/bmake.cat1 Sun Mar 09 19:39:31 2008 +0000
@@ -1,7 +1,7 @@
-MAKE(1) NetBSD General Commands Manual MAKE(1)
+MAKE(1) BSD General Commands Manual MAKE(1)
NNAAMMEE
- bbmmaakkee - maintain program dependencies
+ bbmmaakkee -- maintain program dependencies
SSYYNNOOPPSSIISS
bbmmaakkee [--BBeeiikkNNnnqqrrssttWWXX] [--DD _v_a_r_i_a_b_l_e] [--dd _f_l_a_g_s] [--ff _m_a_k_e_f_i_l_e]
@@ -11,15 +11,18 @@
DDEESSCCRRIIPPTTIIOONN
bbmmaakkee is a program designed to simplify the maintenance of other pro-
grams. Its input is a list of specifications as to the files upon which
- programs and other files depend. If the file `_m_a_k_e_f_i_l_e' exists, it is
- read for this list of specifications. If it does not exist, the file
- `_M_a_k_e_f_i_l_e' is read. If the file `_._d_e_p_e_n_d' exists, it is read (see
+ programs and other files depend. If no --ff _m_a_k_e_f_i_l_e makefile option is
+ given, bbmmaakkee will try to open `_m_a_k_e_f_i_l_e' then `_M_a_k_e_f_i_l_e' in order to find
+ the specifications. If the file `_._d_e_p_e_n_d' exists, it is read (see
mkdep(1)).
This manual page is intended as a reference document only. For a more
thorough description of bbmmaakkee and makefiles, please refer to _M_a_k_e _- _A
_T_u_t_o_r_i_a_l.
+ bbmmaakkee will prepend the contents of the _M_A_K_E_F_L_A_G_S environment variable to
+ the command line arguments before parsing them.
+
The options are as follows:
--BB Try to be backwards compatible by executing a single shell per
@@ -29,10 +32,12 @@
--DD _v_a_r_i_a_b_l_e
Define _v_a_r_i_a_b_l_e to be 1, in the global context.
- --dd _f_l_a_g_s
Home |
Main Index |
Thread Index |
Old Index