Bug 807066 - Port changes to CL_INCLUDES_PREFIX and cl.py to comm-central r=callek

This commit is contained in:
Ian Neal 2012-11-10 09:38:02 +00:00
Родитель e9a1c6eb00
Коммит 6f468bd076
2 изменённых файлов: 16 добавлений и 7 удалений

Просмотреть файл

@ -115,6 +115,11 @@ FINAL_LINK_COMP_NAMES = $(MOZDEPTH)/config/final-link-comp-names
MOZ_UNICHARUTIL_LIBS = $(LIBXUL_DIST)/lib/$(LIB_PREFIX)unicharutil_s.$(LIB_SUFFIX)
MOZ_WIDGET_SUPPORT_LIBS = $(DIST)/lib/$(LIB_PREFIX)widgetsupport_s.$(LIB_SUFFIX)
ifdef _MSC_VER
CC_WRAPPER ?= $(PYTHON) -O $(topsrcdir)/mozilla/build/cl.py
CXX_WRAPPER ?= $(PYTHON) -O $(topsrcdir)/mozilla/build/cl.py
endif # _MSC_VER
CC := $(CC_WRAPPER) $(CC)
CXX := $(CXX_WRAPPER) $(CXX)
MKDIR ?= mkdir
@ -719,6 +724,8 @@ ifndef MOZ_SYSTEM_PLY
PLY_INCLUDE = -I$(MOZILLA_DIR)/other-licenses/ply
endif
export CL_INCLUDES_PREFIX
# autoconf.mk sets OBJ_SUFFIX to an error to avoid use before including
# this file
OBJ_SUFFIX := $(_OBJ_SUFFIX)

Просмотреть файл

@ -6113,10 +6113,15 @@ else
_DEFINES_CFLAGS='$(ACDEFINES) -D_COMM_CONFIG_H_ -DMOZILLA_CLIENT'
_DEFINES_CXXFLAGS='$(ACDEFINES) -D_COMM_CONFIG_H_ -DMOZILLA_CLIENT'
else
_topsrcdirwin=`cd \`dirname $0\`; pwd -W`
dnl cl.py provides dependency generation for MSVC
CC_WRAPPER="$PYTHON -O $_topsrcdirwin/mozilla/build/cl.py"
CXX_WRAPPER="$PYTHON -O $_topsrcdirwin/mozilla/build/cl.py"
echo '#include <stdio.h>' > dummy-hello.c
changequote(,)
CL_INCLUDES_PREFIX=`${CC} -showIncludes -c -Fonul dummy-hello.c 2>&1 | sed -ne 's/^\([^:]*:[^:]*:\).*stdio.h$/\1/p'`
changequote([,])
if test -z "$CL_INCLUDES_PREFIX"; then
AC_MSG_ERROR([Cannot find cl -showIncludes prefix.])
fi
AC_SUBST(CL_INCLUDES_PREFIX)
rm -f dummy-hello.c
COMPILER_DEPEND=1
fi
fi
@ -6125,9 +6130,6 @@ MDDEPDIR='.deps'
AC_SUBST(MOZ_AUTO_DEPS)
AC_SUBST(COMPILER_DEPEND)
AC_SUBST(MDDEPDIR)
AC_SUBST(CC_WRAPPER)
AC_SUBST(CXX_WRAPPER)
dnl ========================================================
dnl =