summaryrefslogtreecommitdiffstats
path: root/share/mk/bsd.incs.mk
diff options
context:
space:
mode:
authorbapt <bapt@FreeBSD.org>2015-06-15 10:56:01 +0000
committerbapt <bapt@FreeBSD.org>2015-06-15 10:56:01 +0000
commit35a6f0a11cfe0d26a30bdbedec91a5d1f245d073 (patch)
tree38be19927629e894dac83d7490eda1567d530cb9 /share/mk/bsd.incs.mk
parent03d84058c3a2a1f69cd43d180104c0cee5dc3920 (diff)
parent1f7642cc6f9e7a88f2e1524cbafc9b64fcff56f8 (diff)
downloadFreeBSD-src-35a6f0a11cfe0d26a30bdbedec91a5d1f245d073.zip
FreeBSD-src-35a6f0a11cfe0d26a30bdbedec91a5d1f245d073.tar.gz
Merge from head
Diffstat (limited to 'share/mk/bsd.incs.mk')
-rw-r--r--share/mk/bsd.incs.mk23
1 files changed, 22 insertions, 1 deletions
diff --git a/share/mk/bsd.incs.mk b/share/mk/bsd.incs.mk
index f0c9c42..24312b7 100644
--- a/share/mk/bsd.incs.mk
+++ b/share/mk/bsd.incs.mk
@@ -31,12 +31,15 @@ ${group}OWN?= ${BINOWN}
${group}GRP?= ${BINGRP}
${group}MODE?= ${NOBINMODE}
${group}DIR?= ${INCLUDEDIR}${PRIVATELIB:D/private/${LIB}}
+STAGE_SETS+= ${group}
+STAGE_DIR.${group}= ${STAGE_OBJTOP}${${group}DIR}
+STAGE_SYMLINKS_DIR.${group}= ${STAGE_OBJTOP}
_${group}INCS=
.for header in ${${group}}
.if defined(${group}OWN_${header:T}) || defined(${group}GRP_${header:T}) || \
defined(${group}MODE_${header:T}) || defined(${group}DIR_${header:T}) || \
- defined(${group}NAME_${header:T})
+ defined(${group}NAME_${header:T}) || defined(${group}NAME)
${group}OWN_${header:T}?= ${${group}OWN}
${group}GRP_${header:T}?= ${${group}GRP}
${group}MODE_${header:T}?= ${${group}MODE}
@@ -46,6 +49,11 @@ ${group}NAME_${header:T}?= ${${group}NAME}
.else
${group}NAME_${header:T}?= ${header:T}
.endif
+STAGE_AS_SETS+= ${group}
+STAGE_AS_${header:T}= ${${group}NAME_${header:T}}
+stage_as.${group}: ${header}
+stage_includes: stage_as.${group}
+
installincludes: _${group}INS_${header:T}
_${group}INS_${header:T}: ${header}
${INSTALL} -C -o ${${group}OWN_${.ALLSRC:T}} \
@@ -57,6 +65,9 @@ _${group}INCS+= ${header}
.endif
.endfor
.if !empty(_${group}INCS)
+stage_files.${group}: ${_${group}INCS}
+stage_includes: stage_files.${group}
+
installincludes: _${group}INS
_${group}INS: ${_${group}INCS}
.if defined(${group}NAME)
@@ -88,4 +99,14 @@ installincludes:
realinstall: installincludes
.ORDER: beforeinstall installincludes
+.if ${MK_STAGING} != "no" && !defined(_SKIP_BUILD)
+.if !defined(NO_STAGE_INCLUDES)
+staging: stage_includes
+.if !empty(INCSLINKS)
+staging: stage_symlinks
+STAGE_SYMLINKS.INCS= ${INCSLINKS}
+.endif
+.endif
+.endif
+
.endif # ${MK_TOOLCHAIN} != "no"
OpenPOWER on IntegriCloud