Allow standalone debug for non-default ${PROG} targets

This allows WITH_DEBUG_FILES to produce standalone debug for the ELF
runtime linker.

We previously disabled standalone debug files for bsd.prog.mk consumers
that included a non-default ${PROG} target, but this is not required.

Consumers that do not support standalone debug are still handled by
disabling it for statically linked binaries, and for those that specify
a non-default binary format.

Sponsored by:	DARPA, AFRL
This commit is contained in:
Ed Maste 2014-09-02 19:05:34 +00:00
parent a272a81370
commit 6e52173261

View File

@ -29,9 +29,7 @@ CTFFLAGS+= -g
PROG= ${PROG_CXX}
.endif
.if defined(PROG) && target(${PROG})
MK_DEBUG_FILES= no
.elif !empty(LDFLAGS:M-Wl,*--oformat,*) || !empty(LDFLAGS:M-static)
.if !empty(LDFLAGS:M-Wl,*--oformat,*) || !empty(LDFLAGS:M-static)
MK_DEBUG_FILES= no
.endif