pkgsrc-Changes archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

$ in make's := operator (was: CVS commit: pkgsrc/mk)



Date: Tue, 30 Nov 2021 09:06:37 +0000
From: Jonathan Perkin <jperkin%netbsd.org@localhost>
To: pkgsrc-changes%NetBSD.org@localhost
Subject: CVS commit: pkgsrc/mk
X-Mailer: log_accum

Module Name:    pkgsrc
Committed By:   jperkin
Date:           Tue Nov 30 09:06:37 UTC 2021

Modified Files:
        pkgsrc/mk: bsd.prefs.mk

Log Message:
mk: Don't expand OPSYS_VERSION early.

The goal of this line was to not evaluate the command from line 92 more
than once.

Something about NetBSD make(1), at least on 9_STABLE, doesn't like doing this,
resulting in literal "$$3" being passed to awk instead of being escaped down
to "$3".  The same construct works fine with pkgsrc bmake(1).

For some reason, .MAKE.SAVE_DOLLARS defaults to true in
pkgsrc/devel/bmake (for backwards compatibility) and to false in NetBSD
as well as Simon's bmake distribution.

https://github.com/NetBSD/src/commit/0dd5f1a106a216266916b5923405d371213696b7
(2016-02-20)

https://github.com/NetBSD/pkgsrc/commit/0bbbec9ad267d59e31d6524638e82ce10f0da3cc#diff-4cf6183cce5af03aba93f796745a61a235d8b382355e4a2b1d07c6fc2ce5c92dR990
(2020-05-24)

The differing default value is definitely a pitfall. There's nothing
pkglint can warn about, and changing the default value would affect all
packages that use devel/bmake, so that's not trivial either.

Why does a version number of an operating system contain a '$' at all?

Roland



Home | Main Index | Thread Index | Old Index