diff --git a/parser/htmlparser/public/Makefile.in b/parser/htmlparser/public/Makefile.in
index e2e9ef388966..432eccbf4724 100644
--- a/parser/htmlparser/public/Makefile.in
+++ b/parser/htmlparser/public/Makefile.in
@@ -73,7 +73,7 @@ SDK_HEADERS = \
nsParserDataListener.h \
$(NULL)
-ifneq ($(MOZ_DEBUG)$(MOZ_PERF_METRICS),)
+ifdef MOZ_DEBUG
EXPORTS += \
nsILoggingSink.h \
$(NULL)
diff --git a/parser/htmlparser/src/Makefile.in b/parser/htmlparser/src/Makefile.in
index 2d8b92d3ed93..352e8387315f 100644
--- a/parser/htmlparser/src/Makefile.in
+++ b/parser/htmlparser/src/Makefile.in
@@ -82,7 +82,7 @@ CPPSRCS += \
$(NULL)
endif
-ifneq ($(MOZ_DEBUG)$(MOZ_PERF_METRICS),)
+ifdef MOZ_DEBUG
CPPSRCS += \
nsLoggingSink.cpp \
$(NULL)