Fix parallel build race with DEBUG_FLAGS

Reported by: Jan Beich on freebsd-current
Tested by: markj
This commit is contained in:
Ed Maste 2013-02-20 20:42:56 +00:00
parent 1f0ed3c00e
commit 0d1fce25cb
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=247054

View File

@ -113,12 +113,20 @@ PO_FLAG=-pg
all: objwarn
.if defined(SHLIB_NAME)
.if defined(DEBUG_FLAGS)
SHLIB_NAME_FULL=${SHLIB_NAME}.debug
.else
SHLIB_NAME_FULL=${SHLIB_NAME}
.endif
.endif
.include <bsd.symver.mk>
# Allow libraries to specify their own version map or have it
# automatically generated (see bsd.symver.mk above).
.if ${MK_SYMVER} == "yes" && !empty(VERSION_MAP)
${SHLIB_NAME}: ${VERSION_MAP}
${SHLIB_NAME_FULL}: ${VERSION_MAP}
LDFLAGS+= -Wl,--version-script=${VERSION_MAP}
.endif
@ -165,12 +173,6 @@ SOBJS+= ${OBJS:.o=.So}
.if defined(SHLIB_NAME)
_LIBS+= ${SHLIB_NAME}
.if defined(DEBUG_FLAGS)
SHLIB_NAME_FULL=${SHLIB_NAME}.debug
.else
SHLIB_NAME_FULL=${SHLIB_NAME}
.endif
SOLINKOPTS= -shared -Wl,-x
.if !defined(ALLOW_SHARED_TEXTREL)
SOLINKOPTS+= -Wl,--fatal-warnings -Wl,--warn-shared-textrel