depsrc-use.mk revision 1.3 1 # $NetBSD: depsrc-use.mk,v 1.3 2020/08/22 07:49:44 rillig Exp $
2 #
3 # Tests for the special source .USE in dependency declarations,
4 # which allows to append common commands to other targets.
5
6 all: action directly
7
8 first: .USE
9 @echo first # Using ${.TARGET} here would expand to "action"
10
11 second: .USE
12 @echo second
13
14 # It's possible but uncommon to have a .USE target with no commands.
15 # This may happen as the result of expanding a .for loop.
16 empty: .USE
17
18 # It's possible but uncommon to directly make a .USEBEFORE target.
19 directly: .USE
20 @echo directly
21
22 action: first second empty
23