Hello community,

here is the log from the commit of package bmake for openSUSE:Factory checked 
in at 2019-09-13 14:58:52
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/bmake (Old)
 and      /work/SRC/openSUSE:Factory/.bmake.new.7948 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "bmake"

Fri Sep 13 14:58:52 2019 rev:18 rq:730140 version:20181221

Changes:
--------
--- /work/SRC/openSUSE:Factory/bmake/bmake.changes      2018-08-07 
09:43:09.725318791 +0200
+++ /work/SRC/openSUSE:Factory/.bmake.new.7948/bmake.changes    2019-09-13 
14:58:54.177278722 +0200
@@ -1,0 +2,6 @@
+Wed Sep 11 12:52:21 UTC 2019 - Martin Pluskal <[email protected]>
+
+- Update to version 20181221:
+  * For full list of changes see provided Changelog
+
+-------------------------------------------------------------------

Old:
----
  bmake-20180512.tar.gz

New:
----
  bmake-20181221.tar.gz

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ bmake.spec ++++++
--- /var/tmp/diff_new_pack.oxvmBi/_old  2019-09-13 14:58:54.561278738 +0200
+++ /var/tmp/diff_new_pack.oxvmBi/_new  2019-09-13 14:58:54.561278738 +0200
@@ -1,7 +1,7 @@
 #
 # spec file for package bmake
 #
-# Copyright (c) 2018 SUSE LINUX GmbH, Nuernberg, Germany.
+# Copyright (c) 2019 SUSE LINUX GmbH, Nuernberg, Germany.
 #
 # All modifications and additions to the file contributed by third parties
 # remain the property of their copyright owners, unless otherwise agreed
@@ -12,17 +12,17 @@
 # license that conforms to the Open Source Definition (Version 1.9)
 # published by the Open Source Initiative.
 
-# Please submit bugfixes or comments via http://bugs.opensuse.org/
+# Please submit bugfixes or comments via https://bugs.opensuse.org/
 #
 
 
 Name:           bmake
-Version:        20180512
+Version:        20181221
 Release:        0
 Summary:        The NetBSD make(1) tool
 License:        BSD-2-Clause AND BSD-3-Clause AND BSD-4-Clause
 Group:          Development/Tools/Building
-Url:            https://ftp.NetBSD.org/pub/NetBSD/misc/sjg/
+URL:            https://ftp.NetBSD.org/pub/NetBSD/misc/sjg/
 Source0:        
https://ftp.NetBSD.org/pub/NetBSD/misc/sjg/bmake-%{version}.tar.gz
 # PATCH-FEATURE-OPENSUSE allow-overriding-compiler-variables.patch -- Based on 
Linux.sys.mk which was previously shipped with this package
 # patch generated using `git diff master opensuse` from 
https://github.com/RichardsonAlex/bmake
@@ -61,7 +61,7 @@
   --sysconfdir="%{_sysconfdir}" \
   --with-default-sys-path="%{_datadir}/mk" \
   --install-prefix="%{_prefix}" \
-  --install-destdir="%{buildroot}" \
+  --install-destdir=%{buildroot} \
   op=install
 mv "%{buildroot}%{_mandir}/cat1" "%{buildroot}%{_mandir}/man1"
 
@@ -69,10 +69,9 @@
 ./boot-strap op=test
 
 %files
-%defattr(-,root,root)
 %doc ChangeLog README
 %{_bindir}/bmake
-%{_mandir}/man1/bmake.1%{ext_man}
+%{_mandir}/man1/bmake.1%{?ext_man}
 %{_datadir}/mk/
 
 %changelog

++++++ bmake-20180512.tar.gz -> bmake-20181221.tar.gz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/bmake/ChangeLog new/bmake/ChangeLog
--- old/bmake/ChangeLog 2018-05-12 20:20:29.000000000 +0200
+++ new/bmake/ChangeLog 2018-12-22 01:40:23.000000000 +0100
@@ -1,3 +1,37 @@
+2018-12-21  Simon J Gerraty  <[email protected]>
+
+       * VERSION: 20181221
+         Merge with NetBSD make, pick up
+         o parse.c: ParseVErrorInternal use .PARSEDIR
+           and apply if relative, and then use .PARSEFILE
+           for consistent result.
+
+2018-12-20  Simon J Gerraty  <[email protected]>
+
+       * VERSION: 20181220
+         Merge with NetBSD make, pick up
+         o parse.c: ParseVErrorInternal use .CURDIR if .PARSEDIR
+           is relative
+         o var.c: avoid SEGFAULT in .unexport-env
+           when MAKELEVEL is not set
+
+2018-12-16  Simon J Gerraty  <[email protected]>
+
+       * VERSION: 20181216
+         Merge with NetBSD make, pick up
+         o fix for unit-tests/varquote.mk on Debian
+
+2018-09-21  Simon J. Gerraty  <[email protected]>
+
+       * VERSION: 20180919
+         Merge with NetBSD make, pick up
+         o var.c: add :q
+         o dir.c: cleanup caching of stats
+
+2018-09-21  Simon J Gerraty  <[email protected]>
+
+       * Makefile.config.in: use += where it makes sense.
+
 2018-05-12  Simon J. Gerraty  <[email protected]>
 
        * VERSION: 20180512
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/bmake/FILES new/bmake/FILES
--- old/bmake/FILES     2017-08-13 02:35:02.000000000 +0200
+++ new/bmake/FILES     2018-09-21 23:54:20.000000000 +0200
@@ -163,6 +163,8 @@
 unit-tests/varcmd.mk
 unit-tests/varmisc.exp
 unit-tests/varmisc.mk
+unit-tests/varquote.exp
+unit-tests/varquote.mk
 unit-tests/varshell.exp
 unit-tests/varshell.mk
 util.c
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/bmake/Makefile.config.in new/bmake/Makefile.config.in
--- old/bmake/Makefile.config.in        2018-02-13 20:35:45.000000000 +0100
+++ new/bmake/Makefile.config.in        2018-09-22 00:41:16.000000000 +0200
@@ -1,6 +1,6 @@
 # things set by configure
 
-_MAKE_VERSION=@_MAKE_VERSION@
+_MAKE_VERSION?=@_MAKE_VERSION@
 
 prefix?= @prefix@
 srcdir= @srcdir@
@@ -11,9 +11,9 @@
 
 CPPFLAGS+= @CPPFLAGS@
 CFLAGS+= ${CPPFLAGS} @DEFS@
-LDFLAGS= @LDFLAGS@
-LIBOBJS= @LIBOBJS@
-LDADD= @LIBS@
+LDFLAGS+= @LDFLAGS@
+LIBOBJS+= @LIBOBJS@
+LDADD+= @LIBS@
 USE_META= @use_meta@
 FILEMON_H?= @filemon_h@
 BMAKE_PATH_MAX?= @bmake_path_max@
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/bmake/VERSION new/bmake/VERSION
--- old/bmake/VERSION   2018-05-12 20:20:29.000000000 +0200
+++ new/bmake/VERSION   2018-12-22 01:40:23.000000000 +0100
@@ -1,2 +1,2 @@
 # keep this compatible with sh and make
-_MAKE_VERSION=20180512
+_MAKE_VERSION=20181221
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/bmake/bmake.1 new/bmake/bmake.1
--- old/bmake/bmake.1   2018-05-18 20:53:35.000000000 +0200
+++ new/bmake/bmake.1   2018-12-22 19:58:23.000000000 +0100
@@ -1,4 +1,4 @@
-.\"    $NetBSD: make.1,v 1.272 2018/04/02 04:26:17 dholland Exp $
+.\"    $NetBSD: make.1,v 1.273 2018/05/27 01:14:51 christos Exp $
 .\"
 .\" Copyright (c) 1990, 1993
 .\"    The Regents of the University of California.  All rights reserved.
@@ -29,7 +29,7 @@
 .\"
 .\"    from: @(#)make.1        8.4 (Berkeley) 3/19/94
 .\"
-.Dd June 22, 2017
+.Dd May 26, 2018
 .Dt BMAKE 1
 .Os
 .Sh NAME
@@ -1227,8 +1227,15 @@
 .Ed
 .It Cm \&:Q
 Quotes every shell meta-character in the variable, so that it can be passed
+safely to the shell.
+.It Cm \&:q
+Quotes every shell meta-character in the variable, and also doubles
+.Sq $
+characters so that it can be passed
 safely through recursive invocations of
 .Nm .
+This is equivalent to: 
+.Sq \&:S/\e\&$/&&/g:Q .
 .It Cm \&:R
 Replaces each word in the variable with everything but its suffix.
 .It Cm \&:range[=count]
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/bmake/dir.c new/bmake/dir.c
--- old/bmake/dir.c     2017-04-18 02:58:47.000000000 +0200
+++ new/bmake/dir.c     2018-09-21 23:39:43.000000000 +0200
@@ -1,4 +1,4 @@
-/*     $NetBSD: dir.c,v 1.71 2017/04/16 21:14:47 riastradh Exp $       */
+/*     $NetBSD: dir.c,v 1.73 2018/07/12 18:03:31 christos Exp $        */
 
 /*
  * Copyright (c) 1988, 1989, 1990 The Regents of the University of California.
@@ -70,14 +70,14 @@
  */
 
 #ifndef MAKE_NATIVE
-static char rcsid[] = "$NetBSD: dir.c,v 1.71 2017/04/16 21:14:47 riastradh Exp 
$";
+static char rcsid[] = "$NetBSD: dir.c,v 1.73 2018/07/12 18:03:31 christos Exp 
$";
 #else
 #include <sys/cdefs.h>
 #ifndef lint
 #if 0
 static char sccsid[] = "@(#)dir.c      8.2 (Berkeley) 1/2/94";
 #else
-__RCSID("$NetBSD: dir.c,v 1.71 2017/04/16 21:14:47 riastradh Exp $");
+__RCSID("$NetBSD: dir.c,v 1.73 2018/07/12 18:03:31 christos Exp $");
 #endif
 #endif /* not lint */
 #endif
@@ -268,15 +268,6 @@
 };
 
 /* minimize changes below */
-static time_t
-Hash_GetTimeValue(Hash_Entry *entry)
-{
-    struct cache_st *cst;
-
-    cst = entry->clientPtr;
-    return cst->mtime;
-}
-
 #define CST_LSTAT 1
 #define CST_UPDATE 2
 
@@ -298,6 +289,10 @@
        memset(st, 0, sizeof(*st));
        st->st_mtime = cst->mtime;
        st->st_mode = cst->mode;
+        if (DEBUG(DIR)) {
+            fprintf(debug_file, "Using cached time %s for %s\n",
+               Targ_FmtTime(st->st_mtime), pathname);
+       }
        return 0;
     }
 
@@ -315,6 +310,10 @@
     cst = entry->clientPtr;
     cst->mtime = st->st_mtime;
     cst->mode = st->st_mode;
+    if (DEBUG(DIR)) {
+       fprintf(debug_file, "   Caching %s for %s\n",
+           Targ_FmtTime(st->st_mtime), pathname);
+    }
 
     return 0;
 }
@@ -995,14 +994,6 @@
     }
 
     if (cached_stat(file, &stb) == 0) {
-       /*
-        * Save the modification time so if it's needed, we don't have
-        * to fetch it again.
-        */
-       if (DEBUG(DIR)) {
-           fprintf(debug_file, "   Caching %s for %s\n", 
Targ_FmtTime(stb.st_mtime),
-                   file);
-       }
        nearmisses += 1;
        return (file);
     }
@@ -1134,7 +1125,6 @@
     Boolean      hasLastDot = FALSE;   /* true we should search dot last */
     Boolean      hasSlash;             /* true if 'name' contains a / */
     struct stat          stb;                  /* Buffer for stat, if 
necessary */
-    Hash_Entry   *entry;               /* Entry for mtimes table */
     const char   *trailing_dot = ".";
 
     /*
@@ -1395,24 +1385,14 @@
     }
 
     bigmisses += 1;
-    entry = Hash_FindEntry(&mtimes, name);
-    if (entry != NULL) {
-       if (DEBUG(DIR)) {
-           fprintf(debug_file, "   got it (in mtime cache)\n");
-       }
-       return(bmake_strdup(name));
-    } else if (cached_stat(name, &stb) == 0) {
-       if (DEBUG(DIR)) {
-           fprintf(debug_file, "   Caching %s for %s\n", 
Targ_FmtTime(stb.st_mtime),
-                   name);
-       }
+    if (cached_stat(name, &stb) == 0) {
        return (bmake_strdup(name));
-    } else {
-       if (DEBUG(DIR)) {
-           fprintf(debug_file, "   failed. Returning NULL\n");
-       }
-       return NULL;
     }
+
+    if (DEBUG(DIR)) {
+       fprintf(debug_file, "   failed. Returning NULL\n");
+    }
+    return NULL;
 #endif /* notdef */
 }
 
@@ -1518,7 +1498,6 @@
 {
     char          *fullName;  /* the full pathname of name */
     struct stat          stb;        /* buffer for finding the mod time */
-    Hash_Entry   *entry;
 
     if (gn->type & OP_ARCHV) {
        return Arch_MTime(gn);
@@ -1569,17 +1548,7 @@
        fullName = bmake_strdup(gn->name);
     }
 
-    if (!recheck)
-       entry = Hash_FindEntry(&mtimes, fullName);
-    else
-       entry = NULL;
-    if (entry != NULL) {
-       stb.st_mtime = Hash_GetTimeValue(entry);
-       if (DEBUG(DIR)) {
-           fprintf(debug_file, "Using cached time %s for %s\n",
-                   Targ_FmtTime(stb.st_mtime), fullName);
-       }
-    } else if (cached_stats(&mtimes, fullName, &stb, recheck ? CST_UPDATE : 0) 
< 0) {
+    if (cached_stats(&mtimes, fullName, &stb, recheck ? CST_UPDATE : 0) < 0) {
        if (gn->type & OP_MEMBER) {
            if (fullName != gn->path)
                free(fullName);
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/bmake/dirname.c new/bmake/dirname.c
--- old/bmake/dirname.c 2016-02-18 07:28:07.000000000 +0100
+++ new/bmake/dirname.c 2018-12-16 23:18:11.000000000 +0100
@@ -1,4 +1,4 @@
-/*     $NetBSD: dirname.c,v 1.13 2014/07/16 10:52:26 christos Exp $    */
+/*     $NetBSD: dirname.c,v 1.14 2018/09/27 00:45:34 kre Exp $ */
 
 /*-
  * Copyright (c) 1997, 2002 The NetBSD Foundation, Inc.
@@ -35,6 +35,11 @@
 #ifndef HAVE_DIRNAME
 
 #include <sys/cdefs.h>
+#if defined(LIBC_SCCS) && !defined(lint)
+__RCSID("$NetBSD: dirname.c,v 1.14 2018/09/27 00:45:34 kre Exp $");
+#endif /* !LIBC_SCCS && !lint */
+
+#include "namespace.h"
 #include <sys/param.h>
 #ifdef HAVE_LIBGEN_H
 #include <libgen.h>
@@ -92,7 +97,8 @@
 out:
        if (buf != NULL && buflen != 0) {
                buflen = MIN(len, buflen - 1);
-               memcpy(buf, path, buflen);
+               if (buf != path)
+                       memcpy(buf, path, buflen);
                buf[buflen] = '\0';
        }
        return len;
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/bmake/make.1 new/bmake/make.1
--- old/bmake/make.1    2018-04-06 00:57:47.000000000 +0200
+++ new/bmake/make.1    2018-09-21 23:39:43.000000000 +0200
@@ -1,4 +1,4 @@
-.\"    $NetBSD: make.1,v 1.272 2018/04/02 04:26:17 dholland Exp $
+.\"    $NetBSD: make.1,v 1.273 2018/05/27 01:14:51 christos Exp $
 .\"
 .\" Copyright (c) 1990, 1993
 .\"    The Regents of the University of California.  All rights reserved.
@@ -29,7 +29,7 @@
 .\"
 .\"    from: @(#)make.1        8.4 (Berkeley) 3/19/94
 .\"
-.Dd June 22, 2017
+.Dd May 26, 2018
 .Dt MAKE 1
 .Os
 .Sh NAME
@@ -1227,8 +1227,15 @@
 .Ed
 .It Cm \&:Q
 Quotes every shell meta-character in the variable, so that it can be passed
+safely to the shell.
+.It Cm \&:q
+Quotes every shell meta-character in the variable, and also doubles
+.Sq $
+characters so that it can be passed
 safely through recursive invocations of
 .Nm .
+This is equivalent to: 
+.Sq \&:S/\e\&$/&&/g:Q .
 .It Cm \&:R
 Replaces each word in the variable with everything but its suffix.
 .It Cm \&:range[=count]
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/bmake/mk/ChangeLog new/bmake/mk/ChangeLog
--- old/bmake/mk/ChangeLog      2018-05-12 20:20:29.000000000 +0200
+++ new/bmake/mk/ChangeLog      2018-09-21 23:25:18.000000000 +0200
@@ -1,3 +1,25 @@
+2018-09-19  Simon J Gerraty  <[email protected]>
+
+       * install-mk (MK_VERSION): 20180919
+
+       * dirdeps-options.mk: .undef cannot handle var that expands to
+         more than one var. 
+
+2018-07-08  Simon J Gerraty  <[email protected]>
+
+       * meta.stage.mk: allow wildcards in STAGE_FILES.* etc.
+
+2018-06-01  Simon J Gerraty  <[email protected]>
+
+       * meta.autodep.mk: export META_FILES to avoid command line limit
+       * gendirdeps.mk: if we have lots of .meta files put them in
+         an @list
+
+2018-05-28  Simon J Gerraty  <[email protected]>
+
+       * dirdeps-options.mk: use local.dirdeps-options.mk
+         not local.dirdeps-option.mk
+
 2018-04-20  Simon J Gerraty  <[email protected]>
 
        * install-mk (MK_VERSION): 20180420
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/bmake/mk/dirdeps-options.mk 
new/bmake/mk/dirdeps-options.mk
--- old/bmake/mk/dirdeps-options.mk     2018-05-12 20:20:29.000000000 +0200
+++ new/bmake/mk/dirdeps-options.mk     2018-09-21 23:25:18.000000000 +0200
@@ -1,4 +1,4 @@
-# $Id: dirdeps-options.mk,v 1.5 2018/04/18 15:53:57 sjg Exp $
+# $Id: dirdeps-options.mk,v 1.9 2018/09/20 00:07:19 sjg Exp $
 #
 #      @(#) Copyright (c) 2018, Simon J. Gerraty
 #
@@ -25,7 +25,7 @@
 # If a Makefile.depend.options file exists, it will be included by
 # dirdeps.mk and meta.autodep.mk
 #
-# We include local.dirdeps-option.mk which may also define DIRDEPS.*
+# We include local.dirdeps-options.mk which may also define DIRDEPS.*
 # for options.
 #
 # Thus a directory, that is affected by an option FOO would have
@@ -35,7 +35,7 @@
 # DIRDEPS.FOO.yes
 # DIRDEPS.FOO.no
 # to whatever applies for that dir, or it can rely on globals
-# set in local.dirdeps-option.mk
+# set in local.dirdeps-options.mk
 # Either way, we will .undef DIRDEPS.* when done.
 
 # This should have been set by Makefile.depend.options
@@ -43,7 +43,7 @@
 DIRDEPS_OPTIONS ?=
 
 # pickup any DIRDEPS.* we need
-.-include <local.dirdeps-option.mk>
+.-include <local.dirdeps-options.mk>
 
 .if ${.MAKE.LEVEL} == 0
 # :U below avoids potential errors when we :=
@@ -52,7 +52,10 @@
 .endfor
 DIRDEPS := ${DIRDEPS:O:u}
 # avoid cross contamination
-.undef ${DIRDEPS_OPTIONS:tu:@o@DIRDEPS.$o.yes DIRDEPS.$o.no@}
+.for o in ${DIRDEPS_OPTIONS:tu}
+.undef DIRDEPS.$o.yes
+.undef DIRDEPS.$o.no
+.endfor
 .else
 # whether options are enabled or not,
 # we want to filter out the relevant DIRDEPS.*
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/bmake/mk/dirdeps.mk new/bmake/mk/dirdeps.mk
--- old/bmake/mk/dirdeps.mk     2018-05-12 20:20:29.000000000 +0200
+++ new/bmake/mk/dirdeps.mk     2018-09-21 23:25:18.000000000 +0200
@@ -1,4 +1,4 @@
-# $Id: dirdeps.mk,v 1.95 2018/04/23 17:53:56 sjg Exp $
+# $Id: dirdeps.mk,v 1.96 2018/06/20 22:26:39 sjg Exp $
 
 # Copyright (c) 2010-2013, Juniper Networks, Inc.
 # All rights reserved.
@@ -731,6 +731,8 @@
 .info loading ${_m} for ${d:E}
 .endif
 .include <${_m}>
+.else
+.-include <local.dirdeps-missing.mk>
 .endif
 .endif
 .endif
@@ -746,7 +748,7 @@
 DEP_RELDIR := ${RELDIR}
 _DEP_RELDIR := ${RELDIR}
 # Since we are/should be included by .MAKE.DEPENDFILE
-# is is a final opportunity to add/hook global rules.
+# This is a final opportunity to add/hook global rules.
 .-include <local.dirdeps-build.mk>
 
 # pickup local dependencies
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/bmake/mk/gendirdeps.mk new/bmake/mk/gendirdeps.mk
--- old/bmake/mk/gendirdeps.mk  2018-04-06 00:57:47.000000000 +0200
+++ new/bmake/mk/gendirdeps.mk  2018-09-21 23:25:18.000000000 +0200
@@ -1,4 +1,4 @@
-# $Id: gendirdeps.mk,v 1.38 2018/03/10 00:53:52 sjg Exp $
+# $Id: gendirdeps.mk,v 1.39 2018/06/08 01:25:31 sjg Exp $
 
 # Copyright (c) 2010-2013, Juniper Networks, Inc.
 # All rights reserved.
@@ -171,11 +171,27 @@
 # we canonicalize them to keep things simple
 # if we are using a split-fs sandbox, it gets a little messier.
 _objtop := ${_OBJTOP:tA}
+
+# some people put *.meta in META_XTRAS to make sure we get here
+_meta_files := ${META_FILES:N\*.meta:O:u}
+# assume a big list
+_meta_files_arg= @meta.list
+.if empty(_meta_files) && ${META_FILES:M\*.meta} != ""
+# XXX this should be considered a bad idea, 
+# since we cannot ignore stale .meta
+x != cd ${_OBJDIR} && find . -name '*.meta' -print -o \( -type d ! -name . 
-prune \) | sed 's,^./,,' > meta.list; echo
+.elif ${_meta_files:[#]} > 500
+.export _meta_files
+x != echo; for m in $$_meta_files; do echo $$m; done > meta.list
+.else
+_meta_files_arg:= ${_meta_files}
+.endif
+
 dir_list != cd ${_OBJDIR} && \
        ${META2DEPS_CMD} MACHINE=${MACHINE} \
        SRCTOP=${SRCTOP} RELDIR=${RELDIR} CURDIR=${_CURDIR} \
        ${META2DEPS_ARGS} \
-       ${META_FILES:O:u} | ${META2DEPS_FILTER} ${_skip_gendirdeps} \
+       ${_meta_files_arg} | ${META2DEPS_FILTER} ${_skip_gendirdeps} \
        sed ${GENDIRDEPS_SEDCMDS}
 
 .if ${dir_list:M*ERROR\:*} != ""
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/bmake/mk/install-mk new/bmake/mk/install-mk
--- old/bmake/mk/install-mk     2018-05-12 20:20:29.000000000 +0200
+++ new/bmake/mk/install-mk     2018-09-21 23:25:18.000000000 +0200
@@ -55,7 +55,7 @@
 #       Simon J. Gerraty <[email protected]>
 
 # RCSid:
-#      $Id: install-mk,v 1.156 2018/04/22 04:42:47 sjg Exp $
+#      $Id: install-mk,v 1.160 2018/09/20 00:07:19 sjg Exp $
 #
 #      @(#) Copyright (c) 1994 Simon J. Gerraty
 #
@@ -70,7 +70,7 @@
 #      [email protected]
 #
 
-MK_VERSION=20180420
+MK_VERSION=20180919
 OWNER=
 GROUP=
 MODE=444
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/bmake/mk/meta.autodep.mk new/bmake/mk/meta.autodep.mk
--- old/bmake/mk/meta.autodep.mk        2018-04-15 20:32:51.000000000 +0200
+++ new/bmake/mk/meta.autodep.mk        2018-09-21 23:25:18.000000000 +0200
@@ -1,4 +1,4 @@
-# $Id: meta.autodep.mk,v 1.48 2018/04/15 06:30:04 sjg Exp $
+# $Id: meta.autodep.mk,v 1.50 2018/06/08 01:25:31 sjg Exp $
 
 #
 #      @(#) Copyright (c) 2010, Simon J. Gerraty
@@ -20,9 +20,11 @@
 
 .-include <local.autodep.mk>
 
+PICO?= .pico
+
 .if defined(SRCS)
 # it would be nice to be able to query .SUFFIXES
-OBJ_EXTENSIONS+= .o .po .lo .So
+OBJ_EXTENSIONS+= .o .po .lo ${PICO}
 
 # explicit dependencies help short-circuit .SUFFIX searches
 SRCS_DEP_FILTER+= N*.[hly]
@@ -178,7 +180,7 @@
        @case "${.MAKE.META.FILES:T:M*.po.*}" in \
        *.po.*) mv $@.${.MAKE.PID} $@;; \
        *) { cat $@.${.MAKE.PID}; \
-       sed 's,\.So:,.o:,;s,\.o:,.po:,' $@.${.MAKE.PID}; } | sort -u > $@; \
+       sed 's,\${PICO}:,.o:,;s,\.o:,.po:,' $@.${.MAKE.PID}; } | sort -u > $@; \
        rm -f $@.${.MAKE.PID};; \
        esac
 .else
@@ -243,7 +245,7 @@
 .elif ${OPTIMIZE_OBJECT_META_FILES:Uno:tl} == "no"
 META_FILES = ${.MAKE.META.FILES:T:N.depend*:O:u}
 .else
-# if we have 1000's of .o.meta, .So.meta etc we need only look at one set
+# if we have 1000's of .o.meta, ${PICO}.meta etc we need only look at one set
 # it is left as an exercise for the reader to work out what this does
 META_FILES = ${.MAKE.META.FILES:T:N.depend*:N*o.meta:O:u} \
        
${.MAKE.META.FILES:T:M*.${.MAKE.META.FILES:M*o.meta:R:E:O:u:[1]}.meta:O:u}
@@ -260,6 +262,9 @@
 .if !empty(GENDIRDEPS_FILTER)
 .export GENDIRDEPS_FILTER
 .endif
+# export to avoid blowing command line limit
+META_FILES := ${META_XTRAS:U:O:u} ${META_FILES:U:T:O:u:${META_FILE_FILTER:ts:}}
+.export META_FILES
 .endif
 
 # we might have .../ in MAKESYSPATH
@@ -270,8 +275,7 @@
        SKIP_GENDIRDEPS='${SKIP_GENDIRDEPS:O:u}' \
        DPADD='${FORCE_DPADD:O:u}' ${_gendirdeps_mutex} \
        MAKESYSPATH=${_makesyspath} \
-       ${.MAKE} -f gendirdeps.mk RELDIR=${RELDIR} _DEPENDFILE=${_DEPENDFILE} \
-       META_FILES='${META_XTRAS:O:u} 
${META_FILES:T:O:u:${META_FILE_FILTER:ts:}}')
+       ${.MAKE} -f gendirdeps.mk RELDIR=${RELDIR} _DEPENDFILE=${_DEPENDFILE})
        @test -s $@ && touch $@; :
 .endif
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/bmake/mk/meta.stage.mk new/bmake/mk/meta.stage.mk
--- old/bmake/mk/meta.stage.mk  2017-10-28 23:58:53.000000000 +0200
+++ new/bmake/mk/meta.stage.mk  2018-09-21 23:25:18.000000000 +0200
@@ -1,4 +1,4 @@
-# $Id: meta.stage.mk,v 1.55 2017/10/27 01:17:09 sjg Exp $
+# $Id: meta.stage.mk,v 1.56 2018/07/08 17:12:54 sjg Exp $
 #
 #      @(#) Copyright (c) 2011-2017, Simon J. Gerraty
 #
@@ -141,7 +141,7 @@
 
 .if !empty(STAGE_INCSDIR)
 .if !empty(STAGE_INCS)
-stage_incs: ${STAGE_INCS}
+stage_incs: ${STAGE_INCS:N*\**}
 .endif
 .if target(stage_incs) || !empty(.ALLTARGETS:Mstage_includes)
 STAGE_TARGETS += stage_incs
@@ -156,7 +156,7 @@
 
 .if !empty(STAGE_LIBDIR)
 .if !empty(STAGE_LIBS)
-stage_libs: ${STAGE_LIBS}
+stage_libs: ${STAGE_LIBS:N*\**}
 .endif
 .if target(stage_libs)
 STAGE_TARGETS += stage_libs
@@ -191,7 +191,7 @@
 # some makefiles need to populate multiple directories
 .for s in ${STAGE_SETS:O:u}
 .if !empty(STAGE_FILES.$s)
-stage_files.$s: ${STAGE_FILES.$s}
+stage_files.$s: ${STAGE_FILES.$s:N*\**}
 .endif
 .if target(stage_files.$s) || target(stage_files${s:S,^,.,:N._default})
 STAGE_TARGETS += stage_files
@@ -262,7 +262,7 @@
 # both operations happen together
 .for s in ${STAGE_AS_SETS:O:u}
 .if !empty(STAGE_AS.$s)
-stage_as.$s: ${STAGE_AS.$s}
+stage_as.$s: ${STAGE_AS.$s:N*\**}
 .endif
 .if target(stage_as.$s)
 STAGE_TARGETS += stage_as
@@ -277,7 +277,7 @@
 .endif
 
 .if !empty(STAGE_AS_AND_SYMLINK.$s)
-stage_as_and_symlink.$s: ${STAGE_AS_AND_SYMLINK.$s}
+stage_as_and_symlink.$s: ${STAGE_AS_AND_SYMLINK.$s:N*\**}
 .endif
 .if target(stage_as_and_symlink.$s)
 STAGE_TARGETS += stage_as_and_symlink
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/bmake/mk/mk-files.txt new/bmake/mk/mk-files.txt
--- old/bmake/mk/mk-files.txt   2014-11-06 02:48:16.000000000 +0100
+++ new/bmake/mk/mk-files.txt   2018-12-16 23:18:11.000000000 +0100
@@ -25,7 +25,8 @@
 
 Since then I've added a lot of features to NetBSD's make and hence to
 bmake which is kept closely in sync.  The mk-files however have 
-diverged quite a bit, though ideas are still picked up from NetBSD.
+diverged quite a bit, though ideas are still picked up from NetBSD
+and FreeBSD.
 
 Basics
 ------
@@ -399,6 +400,20 @@
 This precludes the use of suffix rules to drive ``make depend``, so 
 dep.mk_ handles that if specifically requested.
 
+options.mk
+----------
+
+Inspired by FreeBSD's ``bsd.own.mk`` more flexible.
+FreeBSD now have similar functionality in ``bsd.mkopt.mk``.
+
+It allows users to express their intent with respect to options
+``MK_*`` by setting ``WITH_*`` or ``WITHOUT_*``.
+
+Note: ``WITHOUT_*`` wins if both are set, and makefiles can set
+``NO_*`` to say they cannot handle that option, or even ``MK_*`` if
+they really need to.
+
+
 own.mk
 ------
 
@@ -407,6 +422,13 @@
 
 It includes ``${MAKECONF}`` if it is defined and exists.
 
+ldorder.mk
+----------
+
+Leverages ``bmake`` to compute optimal link order for libraries.
+This works nicely and makes refactoring a breeze - so long as you
+have not (or few) cicular dependencies between libraries.
+
 man.mk
 ------
 
@@ -477,5 +499,5 @@
 .. _mk.tar.gz: http://www.crufty.net/ftp/pub/sjg/mk.tar.gz
 
 :Author: [email protected]
-:Revision: $Id: mk-files.txt,v 1.16 2014/09/05 04:41:16 sjg Exp $
+:Revision: $Id: mk-files.txt,v 1.18 2018/12/08 07:27:15 sjg Exp $
 :Copyright: Crufty.NET
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/bmake/parse.c new/bmake/parse.c
--- old/bmake/parse.c   2018-04-06 00:57:47.000000000 +0200
+++ new/bmake/parse.c   2018-12-22 01:40:23.000000000 +0100
@@ -1,4 +1,4 @@
-/*     $NetBSD: parse.c,v 1.229 2018/04/05 16:31:54 christos Exp $     */
+/*     $NetBSD: parse.c,v 1.231 2018/12/22 00:36:32 sjg Exp $  */
 
 /*
  * Copyright (c) 1988, 1989, 1990, 1993
@@ -69,14 +69,14 @@
  */
 
 #ifndef MAKE_NATIVE
-static char rcsid[] = "$NetBSD: parse.c,v 1.229 2018/04/05 16:31:54 christos 
Exp $";
+static char rcsid[] = "$NetBSD: parse.c,v 1.231 2018/12/22 00:36:32 sjg Exp $";
 #else
 #include <sys/cdefs.h>
 #ifndef lint
 #if 0
 static char sccsid[] = "@(#)parse.c    8.3 (Berkeley) 3/19/94";
 #else
-__RCSID("$NetBSD: parse.c,v 1.229 2018/04/05 16:31:54 christos Exp $");
+__RCSID("$NetBSD: parse.c,v 1.231 2018/12/22 00:36:32 sjg Exp $");
 #endif
 #endif /* not lint */
 #endif
@@ -691,21 +691,32 @@
        if (cfname != NULL) {
                (void)fprintf(f, "\"");
                if (*cfname != '/' && strcmp(cfname, "(stdin)") != 0) {
-                       char *cp;
-                       const char *dir;
+                       char *cp, *cp2;
+                       const char *dir, *fname;
 
                        /*
                         * Nothing is more annoying than not knowing
-                        * which Makefile is the culprit.
+                        * which Makefile is the culprit; we try ${.PARSEDIR}
+                        * and apply realpath(3) if not absolute.
                         */
                        dir = Var_Value(".PARSEDIR", VAR_GLOBAL, &cp);
-                       if (dir == NULL || *dir == '\0' ||
-                           (*dir == '.' && dir[1] == '\0'))
-                               dir = Var_Value(".CURDIR", VAR_GLOBAL, &cp);
                        if (dir == NULL)
                                dir = ".";
-
-                       (void)fprintf(f, "%s/%s", dir, cfname);
+                       if (*dir != '/') {
+                               dir = cp2 = realpath(dir, NULL);
+                               free(cp);
+                               cp = cp2; /* cp2 set to NULL by Var_Value */
+                       }
+                       fname = Var_Value(".PARSEFILE", VAR_GLOBAL, &cp2);
+                       if (fname == NULL) {
+                               if ((fname = strrchr(cfname, '/')))
+                                       fname++;
+                               else
+                                       fname = cfname;
+                       }
+                       (void)fprintf(f, "%s/%s", dir, fname);
+                       free(cp2);
+                       free(cp);
                } else
                        (void)fprintf(f, "%s", cfname);
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/bmake/unit-tests/Makefile.in 
new/bmake/unit-tests/Makefile.in
--- old/bmake/unit-tests/Makefile.in    2015-12-07 05:06:29.000000000 +0100
+++ new/bmake/unit-tests/Makefile.in    2018-09-21 23:39:43.000000000 +0200
@@ -1,6 +1,6 @@
-# $Id: Makefile.in,v 1.48 2015/12/07 04:06:29 sjg Exp $
+# $Id: Makefile.in,v 1.49 2018/09/21 21:39:05 sjg Exp $
 #
-# $NetBSD: Makefile,v 1.52 2015/05/05 21:51:09 sjg Exp $
+# $NetBSD: Makefile,v 1.53 2018/05/24 00:25:44 christos Exp $
 #
 # Unit tests for make(1)
 # The main targets are:
@@ -54,6 +54,7 @@
        unexport-env \
        varcmd \
        varmisc \
+       varquote \
        varshell
 
 # these tests were broken by referting POSIX chanegs
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/bmake/unit-tests/varquote.exp 
new/bmake/unit-tests/varquote.exp
--- old/bmake/unit-tests/varquote.exp   1970-01-01 01:00:00.000000000 +0100
+++ new/bmake/unit-tests/varquote.exp   2018-09-21 23:33:57.000000000 +0200
@@ -0,0 +1,3 @@
+-fdebug-prefix-map=$NETBSDSRCDIR=/usr/src 
-fdebug-regex-map=/usr/src/(.*)/obj$=/usr/obj/\1
+-fdebug-prefix-map=$NETBSDSRCDIR=/usr/src 
-fdebug-regex-map=/usr/src/(.*)/obj$=/usr/obj/\1
+exit status 0
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/bmake/unit-tests/varquote.mk 
new/bmake/unit-tests/varquote.mk
--- old/bmake/unit-tests/varquote.mk    1970-01-01 01:00:00.000000000 +0100
+++ new/bmake/unit-tests/varquote.mk    2018-12-16 23:18:11.000000000 +0100
@@ -0,0 +1,14 @@
+# $NetBSD: varquote.mk,v 1.4 2018/12/16 18:53:34 christos Exp $
+#
+# Test VAR:q modifier
+
+.if !defined(REPROFLAGS)
+REPROFLAGS+=    -fdebug-prefix-map=\$$NETBSDSRCDIR=/usr/src
+REPROFLAGS+=    -fdebug-regex-map='/usr/src/(.*)/obj$$=/usr/obj/\1'
+all:
+       @${MAKE} -f ${MAKEFILE} REPROFLAGS=${REPROFLAGS:S/\$/&&/g:Q}
+       @${MAKE} -f ${MAKEFILE} REPROFLAGS=${REPROFLAGS:q}
+.else
+all:
+       @printf "%s %s\n" ${REPROFLAGS}
+.endif
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/bmake/var.c new/bmake/var.c
--- old/bmake/var.c     2018-02-18 18:26:04.000000000 +0100
+++ new/bmake/var.c     2018-12-21 07:53:52.000000000 +0100
@@ -1,4 +1,4 @@
-/*     $NetBSD: var.c,v 1.218 2018/02/18 00:52:42 sjg Exp $    */
+/*     $NetBSD: var.c,v 1.221 2018/12/21 05:50:19 sjg Exp $    */
 
 /*
  * Copyright (c) 1988, 1989, 1990, 1993
@@ -69,14 +69,14 @@
  */
 
 #ifndef MAKE_NATIVE
-static char rcsid[] = "$NetBSD: var.c,v 1.218 2018/02/18 00:52:42 sjg Exp $";
+static char rcsid[] = "$NetBSD: var.c,v 1.221 2018/12/21 05:50:19 sjg Exp $";
 #else
 #include <sys/cdefs.h>
 #ifndef lint
 #if 0
 static char sccsid[] = "@(#)var.c      8.3 (Berkeley) 3/19/94";
 #else
-__RCSID("$NetBSD: var.c,v 1.218 2018/02/18 00:52:42 sjg Exp $");
+__RCSID("$NetBSD: var.c,v 1.221 2018/12/21 05:50:19 sjg Exp $");
 #endif
 #endif /* not lint */
 #endif
@@ -324,7 +324,7 @@
 static char *VarGetPattern(GNode *, Var_Parse_State *,
                           int, const char **, int, int *, int *,
                           VarPattern *);
-static char *VarQuote(char *);
+static char *VarQuote(char *, Boolean);
 static char *VarHash(char *);
 static char *VarModify(GNode *, Var_Parse_State *,
     const char *,
@@ -835,7 +835,8 @@
        environ = savedEnv = newenv;
        newenv[0] = NULL;
        newenv[1] = NULL;
-       setenv(MAKE_LEVEL_ENV, cp, 1);
+       if (cp && *cp)
+           setenv(MAKE_LEVEL_ENV, cp, 1);
     } else {
        for (; *str != '\n' && isspace((unsigned char) *str); str++)
            continue;
@@ -2315,6 +2316,7 @@
  *-----------------------------------------------------------------------
  * VarQuote --
  *     Quote shell meta-characters and space characters in the string
+ *     if quoteDollar is set, also quote and double any '$' characters.
  *
  * Results:
  *     The quoted string
@@ -2325,7 +2327,7 @@
  *-----------------------------------------------------------------------
  */
 static char *
-VarQuote(char *str)
+VarQuote(char *str, Boolean quoteDollar)
 {
 
     Buffer       buf;
@@ -2346,6 +2348,8 @@
        if (isspace((unsigned char)*str) || ismeta((unsigned char)*str))
            Buf_AddByte(&buf, '\\');
        Buf_AddByte(&buf, *str);
+       if (quoteDollar && *str == '$')
+           Buf_AddBytes(&buf, 2, "\\$");
     }
 
     str = Buf_Destroy(&buf, FALSE);
@@ -3485,9 +3489,10 @@
                break;
            }
 #endif
+       case 'q':
        case 'Q':
            if (tstr[1] == endc || tstr[1] == ':') {
-               newStr = VarQuote(nstr);
+               newStr = VarQuote(nstr, modifier == 'q');
                cp = tstr + 1;
                termc = *cp;
                break;


Reply via email to