06b9b3e0ad
Quite a lot of churn on style, but lots of good work refactoring complicated functions and lots more unit-tests. Thanks mostly to rillig at NetBSD Some interesting entries from ChangeLog o .MAKE.{UID,GID} represent uid and gid running make. o allow env var MAKE_OBJDIR_CHECK_WRITABLE=no to skip writable checks in InitObjdir. Explicit .OBJDIR target always allows read-only directory. o add more unit tests for META MODE Merge commit '8e11a9b4250be3c3379c45fa820bff78d99d5946' into main Change-Id: I464fd4c013067f0915671c1ccc96d2d8090b2b9c
36 lines
939 B
Makefile
36 lines
939 B
Makefile
# $NetBSD: deptgt-suffixes.mk,v 1.4 2020/11/21 21:54:42 rillig Exp $
|
|
#
|
|
# Tests for the special target .SUFFIXES in dependency declarations.
|
|
#
|
|
# See also:
|
|
# varname-dot-includes.mk
|
|
# varname-dot-libs.mk
|
|
|
|
.MAKEFLAGS: -dg1
|
|
|
|
.MAIN: all
|
|
|
|
.SUFFIXES: .custom-null
|
|
|
|
# TODO: What is the effect of this? How is it useful?
|
|
.NULL: .custom-null
|
|
.PATH.custom-null: . ..
|
|
|
|
# The order in which the suffixes are listed doesn't matter.
|
|
# Here, they are listed from source to target, just like in the transformation
|
|
# rule below it.
|
|
.SUFFIXES: .src-left .tgt-right
|
|
deptgt-suffixes.src-left:
|
|
: Making ${.TARGET} out of nothing.
|
|
.src-left.tgt-right:
|
|
: Making ${.TARGET} from ${.IMPSRC}.
|
|
all: deptgt-suffixes.tgt-right
|
|
|
|
# Here, the target is listed earlier than the source.
|
|
.SUFFIXES: .tgt-left .src-right
|
|
deptgt-suffixes.src-right:
|
|
: Making ${.TARGET} out of nothing.
|
|
.src-right.tgt-left:
|
|
: Making ${.TARGET} from ${.IMPSRC}.
|
|
all: deptgt-suffixes.tgt-left
|