Bug 581909 - Don't pass -safeseh to ml64 because the behaviour is buggy. r=dwitte

This commit is contained in:
Neil 2010-08-03 14:05:54 -07:00
parent 0173995e4a
commit 82f628bc0b
2 changed files with 47 additions and 4 deletions

View File

@ -1,4 +1,4 @@
Patch libffi to fix bug 550602, bug 528129, bug 538216, bug 556902, and bug 538002. Patch libffi to fix bug 550602, bug 528129, bug 538216, bug 556902, bug 538002, and bug 581909.
diff --git a/js/src/ctypes/libffi/Makefile.in b/js/src/ctypes/libffi/Makefile.in diff --git a/js/src/ctypes/libffi/Makefile.in b/js/src/ctypes/libffi/Makefile.in
--- a/js/src/ctypes/libffi/Makefile.in --- a/js/src/ctypes/libffi/Makefile.in
@ -129,7 +129,7 @@ diff --git a/js/src/ctypes/libffi/configure b/js/src/ctypes/libffi/configure
diff --git a/js/src/ctypes/libffi/msvcc.sh b/js/src/ctypes/libffi/msvcc.sh diff --git a/js/src/ctypes/libffi/msvcc.sh b/js/src/ctypes/libffi/msvcc.sh
--- a/js/src/ctypes/libffi/msvcc.sh --- a/js/src/ctypes/libffi/msvcc.sh
+++ b/js/src/ctypes/libffi/msvcc.sh +++ b/js/src/ctypes/libffi/msvcc.sh
@@ -37,17 +37,17 @@ @@ -37,20 +37,21 @@
# #
# ***** END LICENSE BLOCK ***** # ***** END LICENSE BLOCK *****
@ -143,12 +143,34 @@ diff --git a/js/src/ctypes/libffi/msvcc.sh b/js/src/ctypes/libffi/msvcc.sh
md=-MD md=-MD
cl="cl" cl="cl"
ml="ml" ml="ml"
+safeseh="-safeseh"
output= output=
while [ $# -gt 0 ] while [ $# -gt 0 ]
do do
case $1 case $1
@@ -103,17 +103,18 @@ do in
-fexceptions)
# Don't enable exceptions for now.
@@ -58,16 +59,17 @@ do
shift 1
;;
-m32)
shift 1
;;
-m64)
cl="cl" # "$MSVC/x86_amd64/cl"
ml="ml64" # "$MSVC/x86_amd64/ml64"
+ safeseh=
shift 1
;;
-O*)
args="$args $1"
shift 1
;;
-g)
# Can't specify -RTC1 or -Zi in opt. -Gy is ok. Use -OPT:REF?
@@ -103,17 +105,18 @@ do
includes="$includes $1" includes="$includes $1"
shift 1 shift 1
;; ;;
@ -168,6 +190,25 @@ diff --git a/js/src/ctypes/libffi/msvcc.sh b/js/src/ctypes/libffi/msvcc.sh
;; ;;
-W*) -W*)
# TODO map specific warnings # TODO map specific warnings
@@ -158,17 +161,17 @@ done
if [ -n "$assembly" ]; then
if [ -z "$outdir" ]; then
outdir="."
fi
ppsrc="$outdir/$(basename $src|sed 's/.S$/.asm/g')"
echo "$cl -nologo -EP $includes $defines $src > $ppsrc"
"$cl" -nologo -EP $includes $defines $src > $ppsrc || exit $?
output="$(echo $output | sed 's%/F[dpa][^ ]*%%g')"
- args="-nologo -safeseh $single $output $ppsrc"
+ args="-nologo $safeseh $single $output $ppsrc"
echo "$ml $args"
eval "\"$ml\" $args"
result=$?
# required to fix ml64 broken output?
#mv *.obj $outdir
else
diff --git a/js/src/ctypes/libffi/src/powerpc/ffi_darwin.c b/js/src/ctypes/libffi/src/powerpc/ffi_darwin.c diff --git a/js/src/ctypes/libffi/src/powerpc/ffi_darwin.c b/js/src/ctypes/libffi/src/powerpc/ffi_darwin.c
--- a/js/src/ctypes/libffi/src/powerpc/ffi_darwin.c --- a/js/src/ctypes/libffi/src/powerpc/ffi_darwin.c
+++ b/js/src/ctypes/libffi/src/powerpc/ffi_darwin.c +++ b/js/src/ctypes/libffi/src/powerpc/ffi_darwin.c

View File

@ -46,6 +46,7 @@ args="-nologo"
md=-MD md=-MD
cl="cl" cl="cl"
ml="ml" ml="ml"
safeseh="-safeseh"
output= output=
while [ $# -gt 0 ] while [ $# -gt 0 ]
@ -63,6 +64,7 @@ do
-m64) -m64)
cl="cl" # "$MSVC/x86_amd64/cl" cl="cl" # "$MSVC/x86_amd64/cl"
ml="ml64" # "$MSVC/x86_amd64/ml64" ml="ml64" # "$MSVC/x86_amd64/ml64"
safeseh=
shift 1 shift 1
;; ;;
-O*) -O*)
@ -164,7 +166,7 @@ if [ -n "$assembly" ]; then
echo "$cl -nologo -EP $includes $defines $src > $ppsrc" echo "$cl -nologo -EP $includes $defines $src > $ppsrc"
"$cl" -nologo -EP $includes $defines $src > $ppsrc || exit $? "$cl" -nologo -EP $includes $defines $src > $ppsrc || exit $?
output="$(echo $output | sed 's%/F[dpa][^ ]*%%g')" output="$(echo $output | sed 's%/F[dpa][^ ]*%%g')"
args="-nologo -safeseh $single $output $ppsrc" args="-nologo $safeseh $single $output $ppsrc"
echo "$ml $args" echo "$ml $args"
eval "\"$ml\" $args" eval "\"$ml\" $args"