If PROGNAME is set, we need to use stage_as rather than stage_files

to control the name in the stage tree.
This commit is contained in:
Simon J. Gerraty 2013-01-23 00:47:43 +00:00
parent bd64a3c9dc
commit 0dfb7ef6ae

View file

@ -241,12 +241,24 @@ stage_files stage_as:
.else
# normally only libs and includes are staged
.if ${MK_STAGING_PROG:Uno} != "no"
STAGE_SETS+= prog
STAGE_DIR.prog= ${STAGE_OBJTOP}${BINDIR}
STAGE_SYMLINKS_DIR.prog= ${STAGE_OBJTOP}
.if defined(PROGNAME)
STAGE_AS_SETS+= prog
STAGE_AS_${PROG}= ${PROGNAME}
stage_as.prog: ${PROG}
.if !empty(PROG)
all: stage_as
.endif
.else
STAGE_SETS+= prog
stage_files.prog: ${PROG}
.if !empty(PROG)
all: stage_files
stage_files.prog: ${PROG}
.endif
.endif
.if !empty(SYMLINKS)
all: stage_symlinks
STAGE_SYMLINKS.prog= ${SYMLINKS}