1# $NetBSD: varname-dot-make-jobs.mk,v 1.3 2022/01/26 22:47:03 rillig Exp $ 2# 3# Tests for the special .MAKE.JOBS variable, which is defined in jobs mode 4# only. There it contains the number of jobs that may run in parallel. 5 6.MAIN: all 7 8echo: .PHONY 9 @echo ${.MAKE.JOBS:Uundefined} 10 11all: 12 @${MAKE} -r -f ${MAKEFILE} echo 13 @${MAKE} -r -f ${MAKEFILE} echo -j1 14 @${MAKE} -r -f ${MAKEFILE} echo -j5 15 @${MAKE} -r -f ${MAKEFILE} echo -j20 16 @${MAKE} -r -f ${MAKEFILE} echo -j00000000000000000000000000000001 17 18# expect: undefined 19# expect: 1 20# expect: 5 21# expect: 20 22# The value of .MAKE.JOBS is the exact text given in the command line, not the 23# canonical number. This doesn't have practical consequences though. 24# expect: 00000000000000000000000000000001 25