Author: kan
Date: Tue Oct 20 19:05:43 2009
New Revision: 198304
URL: http://svn.freebsd.org/changeset/base/198304

Log:
  MFC Revision 197277:
  
  Make libc.a provide __stack_chk_fail_local weak alias. This is
  needed to satisfy static libraries that are compiled with -fpic
  and linked into static binary afterwards. Several libraries in
  gcc are examples of such static libs.
  
  Approved by: re (kib)

Modified:
  stable/8/lib/libc/   (props changed)
  stable/8/lib/libc/gen/   (props changed)
  stable/8/lib/libc/stdio/asprintf.c   (props changed)
  stable/8/lib/libc/stdtime/   (props changed)
  stable/8/lib/libc/string/ffsll.c   (props changed)
  stable/8/lib/libc/string/flsll.c   (props changed)
  stable/8/lib/libc/string/wcpcpy.c   (props changed)
  stable/8/lib/libc/string/wcpncpy.c   (props changed)
  stable/8/lib/libc/sys/stack_protector.c

Modified: stable/8/lib/libc/sys/stack_protector.c
==============================================================================
--- stable/8/lib/libc/sys/stack_protector.c     Tue Oct 20 18:58:28 2009        
(r198303)
+++ stable/8/lib/libc/sys/stack_protector.c     Tue Oct 20 19:05:43 2009        
(r198304)
@@ -108,4 +108,8 @@ __chk_fail(void)
        __fail("buffer overflow detected; terminated");
 }
 
+#ifdef PIC
 __sym_compat(__stack_chk_fail_local, __stack_chk_fail, FBSD_1.0);
+#else
+__weak_reference(__stack_chk_fail, __stack_chk_fail_local);
+#endif
_______________________________________________
svn-src-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"

Reply via email to