Bug 1322735 - Enable frame pointers on 32-bit windows builds. r?glandium
This universally disables FPO on win32.
MozReview-Commit-ID: AT9ozxGN0C5
--- a/build/autoconf/frameptr.m4
+++ b/build/autoconf/frameptr.m4
@@ -24,19 +24,21 @@ AC_DEFUN([MOZ_SET_FRAMEPTR_FLAGS], [
dnl Oy (Frame-Pointer Omission) is only support on x86 compilers
*-mingw32*)
MOZ_ENABLE_FRAME_PTR="-Oy-"
MOZ_DISABLE_FRAME_PTR="-Oy"
;;
esac
fi
- # if we are debugging, profiling or using sanitizers, we want a frame pointer.
+ # If we are debugging, profiling, using sanitizers, or on win32 we want a
+ # frame pointer.
if test -z "$MOZ_OPTIMIZE" -o \
-n "$MOZ_PROFILING" -o \
-n "$MOZ_DEBUG" -o \
-n "$MOZ_MSAN" -o \
- -n "$MOZ_ASAN"; then
+ -n "$MOZ_ASAN" -o \
+ "$OS_ARCH:$CPU_ARCH" = "WINNT:x86"; then
MOZ_FRAMEPTR_FLAGS="$MOZ_ENABLE_FRAME_PTR"
else
MOZ_FRAMEPTR_FLAGS="$MOZ_DISABLE_FRAME_PTR"
fi
])