From e432526cab0fe8fe09c53b295d9ceaf68b886a8c Mon Sep 17 00:00:00 2001 From: bapt Date: Sun, 21 Jun 2015 22:27:52 +0000 Subject: [PATCH] Simplify symlinks on include files by using bmake's multivariable .for loops --- share/mk/bsd.incs.mk | 13 ++++--------- 1 file changed, 4 insertions(+), 9 deletions(-) diff --git a/share/mk/bsd.incs.mk b/share/mk/bsd.incs.mk index 76372567ba7a..e1e0a4a98009 100644 --- a/share/mk/bsd.incs.mk +++ b/share/mk/bsd.incs.mk @@ -77,15 +77,10 @@ _${group}INS: ${_${group}INCS} .if defined(INCSLINKS) && !empty(INCSLINKS) installincludes: - @set ${INCSLINKS}; \ - while test $$# -ge 2; do \ - l=$$1; \ - shift; \ - t=${DESTDIR}$$1; \ - shift; \ - ${ECHO} $$t -\> $$l; \ - ${INSTALL_SYMLINK} $$l $$t; \ - done; true +.for s t in ${INCSLINKS} + @${ECHO} "$t -> $s" ; \ + ${INSTALL_SYMLINK} $s ${DESTDIR}$t +.endfor .endif .endif # !target(installincludes)