Karsten Hopp f4041c
To: vim_dev@googlegroups.com
Karsten Hopp f4041c
Subject: Patch 7.4.751
Karsten Hopp f4041c
Fcc: outbox
Karsten Hopp f4041c
From: Bram Moolenaar <Bram@moolenaar.net>
Karsten Hopp f4041c
Mime-Version: 1.0
Karsten Hopp f4041c
Content-Type: text/plain; charset=UTF-8
Karsten Hopp f4041c
Content-Transfer-Encoding: 8bit
Karsten Hopp f4041c
------------
Karsten Hopp f4041c
Karsten Hopp f4041c
Patch 7.4.751
Karsten Hopp f4041c
Problem:    It is not obvious how to enable the address sanitizer.
Karsten Hopp f4041c
Solution:   Add commented-out flags in the Makefile. (Dominique Pelle)
Karsten Hopp f4041c
            Also add missing test targets.
Karsten Hopp f4041c
Files:      src/Makefile
Karsten Hopp f4041c
Karsten Hopp f4041c
Karsten Hopp f4041c
*** ../vim-7.4.750/src/Makefile	2014-12-08 04:16:26.257702950 +0100
Karsten Hopp f4041c
--- src/Makefile	2015-06-21 13:43:37.873649912 +0200
Karsten Hopp f4041c
***************
Karsten Hopp f4041c
*** 616,621 ****
Karsten Hopp f4041c
--- 616,629 ----
Karsten Hopp f4041c
  #PROFILE_LIBS = -pg
Karsten Hopp f4041c
  #PROFILE_LIBS = -pg -lc
Karsten Hopp f4041c
  
Karsten Hopp f4041c
+ # Uncomment one of the next two lines to compile Vim with the
Karsten Hopp f4041c
+ # address sanitizer or with the undefined sanitizer.  Works with gcc and
Karsten Hopp f4041c
+ # clang.  May make Vim twice as slow.  Errors reported on stderr.
Karsten Hopp f4041c
+ # More at: https://code.google.com/p/address-sanitizer/
Karsten Hopp f4041c
+ #SANITIZER_CFLAGS = -g -O0 -fsanitize=address -fno-omit-frame-pointer
Karsten Hopp f4041c
+ #SANITIZER_CFLAGS = -g -O0 -fsanitize=undefined -fno-omit-frame-pointer
Karsten Hopp f4041c
+ SANITIZER_LIBS = $(SANITIZER_CFLAGS)
Karsten Hopp f4041c
+ 
Karsten Hopp f4041c
  # MEMORY LEAK DETECTION
Karsten Hopp f4041c
  # Requires installing the ccmalloc library.
Karsten Hopp f4041c
  # Configuration is in the .ccmalloc or ~/.ccmalloc file.
Karsten Hopp f4041c
***************
Karsten Hopp f4041c
*** 1342,1348 ****
Karsten Hopp f4041c
  PRE_DEFS = -Iproto $(DEFS) $(GUI_DEFS) $(GUI_IPATH) $(CPPFLAGS) $(EXTRA_IPATHS)
Karsten Hopp f4041c
  POST_DEFS = $(X_CFLAGS) $(MZSCHEME_CFLAGS) $(TCL_CFLAGS) $(EXTRA_DEFS)
Karsten Hopp f4041c
  
Karsten Hopp f4041c
! ALL_CFLAGS = $(PRE_DEFS) $(CFLAGS) $(PROFILE_CFLAGS) $(LEAK_CFLAGS) $(POST_DEFS)
Karsten Hopp f4041c
  
Karsten Hopp f4041c
  # Exclude $CFLAGS for osdef.sh, for Mac 10.4 some flags don't work together
Karsten Hopp f4041c
  # with "-E".
Karsten Hopp f4041c
--- 1350,1356 ----
Karsten Hopp f4041c
  PRE_DEFS = -Iproto $(DEFS) $(GUI_DEFS) $(GUI_IPATH) $(CPPFLAGS) $(EXTRA_IPATHS)
Karsten Hopp f4041c
  POST_DEFS = $(X_CFLAGS) $(MZSCHEME_CFLAGS) $(TCL_CFLAGS) $(EXTRA_DEFS)
Karsten Hopp f4041c
  
Karsten Hopp f4041c
! ALL_CFLAGS = $(PRE_DEFS) $(CFLAGS) $(PROFILE_CFLAGS) $(SANITIZER_CFLAGS) $(LEAK_CFLAGS) $(POST_DEFS)
Karsten Hopp f4041c
  
Karsten Hopp f4041c
  # Exclude $CFLAGS for osdef.sh, for Mac 10.4 some flags don't work together
Karsten Hopp f4041c
  # with "-E".
Karsten Hopp f4041c
***************
Karsten Hopp f4041c
*** 1374,1379 ****
Karsten Hopp f4041c
--- 1382,1388 ----
Karsten Hopp f4041c
  	   $(TCL_LIBS) \
Karsten Hopp f4041c
  	   $(RUBY_LIBS) \
Karsten Hopp f4041c
  	   $(PROFILE_LIBS) \
Karsten Hopp f4041c
+ 	   $(SANITIZER_LIBS) \
Karsten Hopp f4041c
  	   $(LEAK_LIBS)
Karsten Hopp f4041c
  
Karsten Hopp f4041c
  # abbreviations
Karsten Hopp f4041c
***************
Karsten Hopp f4041c
*** 1891,1910 ****
Karsten Hopp f4041c
--- 1900,1928 ----
Karsten Hopp f4041c
  
Karsten Hopp f4041c
  # Run individual test, assuming that Vim was already compiled.
Karsten Hopp f4041c
  test1 \
Karsten Hopp f4041c
+ 	test_argument_0count \
Karsten Hopp f4041c
  	test_argument_count \
Karsten Hopp f4041c
  	test_autoformat_join \
Karsten Hopp f4041c
  	test_breakindent \
Karsten Hopp f4041c
  	test_changelist \
Karsten Hopp f4041c
  	test_close_count \
Karsten Hopp f4041c
  	test_command_count \
Karsten Hopp f4041c
+ 	test_erasebackword \
Karsten Hopp f4041c
  	test_eval \
Karsten Hopp f4041c
  	test_insertcount \
Karsten Hopp f4041c
+ 	test_listchars \
Karsten Hopp f4041c
  	test_listlbr \
Karsten Hopp f4041c
  	test_listlbr_utf8 \
Karsten Hopp f4041c
  	test_mapping \
Karsten Hopp f4041c
+ 	test_marks \
Karsten Hopp f4041c
+ 	test_nested_function \
Karsten Hopp f4041c
  	test_options \
Karsten Hopp f4041c
+ 	test_perl \
Karsten Hopp f4041c
  	test_qf_title \
Karsten Hopp f4041c
+ 	test_ruby \
Karsten Hopp f4041c
+ 	test_set \
Karsten Hopp f4041c
  	test_signs \
Karsten Hopp f4041c
+ 	test_textobjects \
Karsten Hopp f4041c
  	test_utf8 \
Karsten Hopp f4041c
  	test_writefile \
Karsten Hopp f4041c
  	test2 test3 test4 test5 test6 test7 test8 test9 \
Karsten Hopp f4041c
*** ../vim-7.4.750/src/version.c	2015-06-21 13:41:02.815278555 +0200
Karsten Hopp f4041c
--- src/version.c	2015-06-21 13:43:52.321498196 +0200
Karsten Hopp f4041c
***************
Karsten Hopp f4041c
*** 743,744 ****
Karsten Hopp f4041c
--- 743,746 ----
Karsten Hopp f4041c
  {   /* Add new patch number below this line */
Karsten Hopp f4041c
+ /**/
Karsten Hopp f4041c
+     751,
Karsten Hopp f4041c
  /**/
Karsten Hopp f4041c
Karsten Hopp f4041c
-- 
Karsten Hopp f4041c
hundred-and-one symptoms of being an internet addict:
Karsten Hopp f4041c
131. You challenge authority and society by portnuking people
Karsten Hopp f4041c
Karsten Hopp f4041c
 /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net   \\\
Karsten Hopp f4041c
///        sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
Karsten Hopp f4041c
\\\  an exciting new programming language -- http://www.Zimbu.org        ///
Karsten Hopp f4041c
 \\\            help me help AIDS victims -- http://ICCF-Holland.org    ///