To: vim-dev@vim.org
Subject: Patch 7.2.316
Fcc: outbox
From: Bram Moolenaar <Bram@moolenaar.net>
Mime-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
------------
Patch 7.2.316
Problem: May get multiple _FORTIFY_SOURCE arguments. (Tony Mechelynck)
Solution: First remove all these arguments and then add the one we want.
(Dominique Pelle)
Files: src/auto/configure, src/configure.in
*** ../vim-7.2.315/src/auto/configure 2009-12-02 17:59:08.000000000 +0100
--- src/auto/configure 2009-12-16 17:05:59.000000000 +0100
***************
*** 17185,17194 ****
{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }
fi
! { $as_echo "$as_me:$LINENO: checking whether we need -D_FORTIFY_SOURCE=1" >&5
$as_echo_n "checking whether we need -D_FORTIFY_SOURCE=1... " >&6; }
if test "$gccmajor" -gt "3"; then
! CFLAGS=`echo "$CFLAGS -D_FORTIFY_SOURCE=1" | sed -e 's/-Wp,-D_FORTIFY_SOURCE=2//g' -e 's/-D_FORTIFY_SOURCE=2//g'`
{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }
else
--- 17185,17194 ----
{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }
fi
! { $as_echo "$as_me:$LINENO: checking whether we need -D_FORTIFY_SOURCE=1" >&5
$as_echo_n "checking whether we need -D_FORTIFY_SOURCE=1... " >&6; }
if test "$gccmajor" -gt "3"; then
! CFLAGS=`echo "$CFLAGS" | sed -e 's/-Wp,-D_FORTIFY_SOURCE=.//g' -e 's/-D_FORTIFY_SOURCE=.//g' -e 's/$/ -D_FORTIFY_SOURCE=1/'`
{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }
else
*** ../vim-7.2.315/src/configure.in 2009-12-02 17:59:08.000000000 +0100
--- src/configure.in 2009-12-16 17:05:55.000000000 +0100
***************
*** 3241,3249 ****
fi
dnl -D_FORTIFY_SOURCE=2 crashes Vim on strcpy(buf, "000") when buf is
dnl declared as char x[1] but actually longer. Introduced in gcc 4.0.
AC_MSG_CHECKING(whether we need -D_FORTIFY_SOURCE=1)
if test "$gccmajor" -gt "3"; then
! CFLAGS=`echo "$CFLAGS -D_FORTIFY_SOURCE=1" | sed -e 's/-Wp,-D_FORTIFY_SOURCE=2//g' -e 's/-D_FORTIFY_SOURCE=2//g'`
AC_MSG_RESULT(yes)
else
AC_MSG_RESULT(no)
--- 3241,3250 ----
fi
dnl -D_FORTIFY_SOURCE=2 crashes Vim on strcpy(buf, "000") when buf is
dnl declared as char x[1] but actually longer. Introduced in gcc 4.0.
+ dnl Also remove duplicate _FORTIFY_SOURCE arguments.
AC_MSG_CHECKING(whether we need -D_FORTIFY_SOURCE=1)
if test "$gccmajor" -gt "3"; then
! CFLAGS=`echo "$CFLAGS" | sed -e 's/-Wp,-D_FORTIFY_SOURCE=.//g' -e 's/-D_FORTIFY_SOURCE=.//g' -e 's/$/ -D_FORTIFY_SOURCE=1/'`
AC_MSG_RESULT(yes)
else
AC_MSG_RESULT(no)
*** ../vim-7.2.315/src/version.c 2009-12-02 17:59:08.000000000 +0100
--- src/version.c 2009-12-16 17:12:25.000000000 +0100
***************
*** 683,684 ****
--- 683,686 ----
{ /* Add new patch number below this line */
+ /**/
+ 316,
/**/
--
Have you heard about the new Beowulf cluster? It's so fast, it executes
an infinite loop in 6 seconds.
/// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\
/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
\\\ download, build and distribute -- http://www.A-A-P.org ///
\\\ help me help AIDS victims -- http://ICCF-Holland.org ///