Index: share/mk/bsd.lib.mk =================================================================== --- share/mk/bsd.lib.mk +++ share/mk/bsd.lib.mk @@ -114,11 +114,11 @@ .if ${MK_DEBUG_FILES} != "no" && empty(DEBUG_FLAGS:M-g) && \ empty(DEBUG_FLAGS:M-gdwarf*) .if !${COMPILER_FEATURES:Mcompressed-debug} -CFLAGS+= ${DEBUG_FILES_CFLAGS:N-gz*} -CXXFLAGS+= ${DEBUG_FILES_CFLAGS:N-gz*} +SHARED_CFLAGS+= ${DEBUG_FILES_CFLAGS:N-gz*} +SHARED_CXXFLAGS+= ${DEBUG_FILES_CFLAGS:N-gz*} .else -CFLAGS+= ${DEBUG_FILES_CFLAGS} -CXXFLAGS+= ${DEBUG_FILES_CFLAGS} +SHARED_CFLAGS+= ${DEBUG_FILES_CFLAGS} +SHARED_CXXFLAGS+= ${DEBUG_FILES_CFLAGS} .endif CTFFLAGS+= -g .endif