From 15bcc2732554c169dffdb88a5ff6a37582801dfd Mon Sep 17 00:00:00 2001 From: Alexandre Perrin Date: Fri, 22 Nov 2013 16:47:44 +0100 Subject: [PATCH 3/4] bmake: new local modifications. --- contrib/bmake/bmake.1 | 2 +- contrib/bmake/main.c | 2 +- contrib/bmake/meta.c | 4 ++-- contrib/bmake/parse.c | 2 +- contrib/bmake/var.c | 2 +- 5 files changed, 6 insertions(+), 6 deletions(-) diff --git a/contrib/bmake/bmake.1 b/contrib/bmake/bmake.1 index df604e7..23a3035 100644 --- a/contrib/bmake/bmake.1 +++ b/contrib/bmake/bmake.1 @@ -1543,8 +1543,8 @@ PATH := ${PATH} .Li .unexport-env .Li .export PATH .Li .endif -.Pp .Ed +.Pp Would result in an environment containing only .Ql Ev PATH , which is the minimal useful environment. diff --git a/contrib/bmake/main.c b/contrib/bmake/main.c index 7c1e64d..fb35601 100644 --- a/contrib/bmake/main.c +++ b/contrib/bmake/main.c @@ -922,7 +922,7 @@ main(int argc, char **argv) const int mib[2] = { CTL_HW, HW_MACHINE_ARCH }; size_t len = sizeof(machine_arch_buf); - if (sysctl(mib, __arraycount(mib), machine_arch_buf, + if (sysctl(__DECONST(int *, mib) /* XXX */, __arraycount(mib), machine_arch_buf, &len, NULL, 0) < 0) { (void)fprintf(stderr, "%s: sysctl failed (%s).\n", progname, strerror(errno)); diff --git a/contrib/bmake/meta.c b/contrib/bmake/meta.c index 3ec0bdc..c5e1c4e 100644 --- a/contrib/bmake/meta.c +++ b/contrib/bmake/meta.c @@ -658,7 +658,7 @@ meta_job_start(Job *job, GNode *gn) * It does not disturb our state. */ void -meta_job_child(Job *job) +meta_job_child(Job __unused *job) { #ifdef USE_FILEMON BuildMon *pbm; @@ -743,7 +743,7 @@ meta_job_output(Job *job, char *cp, const char *nl) } void -meta_cmd_finish(void *pbmp) +meta_cmd_finish(void __unused *pbmp) { #ifdef USE_FILEMON BuildMon *pbm = pbmp; diff --git a/contrib/bmake/parse.c b/contrib/bmake/parse.c index 41323b5..e9c4c76 100644 --- a/contrib/bmake/parse.c +++ b/contrib/bmake/parse.c @@ -1216,7 +1216,7 @@ ParseDoDependency(char *line) */ int length; void *freeIt; - char *result; + __unused char *result; /* XXX */ result = Var_Parse(cp, VAR_CMD, TRUE, &length, &freeIt); if (freeIt) diff --git a/contrib/bmake/var.c b/contrib/bmake/var.c index 290ad3a..fa8b515 100644 --- a/contrib/bmake/var.c +++ b/contrib/bmake/var.c @@ -543,7 +543,7 @@ Var_Delete(const char *name, GNode *ctxt) if (strchr(name, '$')) { cp = Var_Subst(NULL, name, VAR_GLOBAL, 0); } else { - cp = (char *)name; + cp = __DECONST(char *,name); /* XXX */ } ln = Hash_FindEntry(&ctxt->context, cp); if (DEBUG(VAR)) { -- 1.8.4.1