Mercurial > vim
comparison src/Makefile @ 6862:db53fd1a7d5c v7.4.751
patch 7.4.751
Problem: It is not obvious how to enable the address sanitizer.
Solution: Add commented-out flags in the Makefile. (Dominique Pelle)
Also add missing test targets.
author | Bram Moolenaar <bram@vim.org> |
---|---|
date | Sun, 21 Jun 2015 13:44:13 +0200 |
parents | de877dab1c31 |
children | 47680d36e484 |
comparison
equal
deleted
inserted
replaced
6861:bad08ecef761 | 6862:db53fd1a7d5c |
---|---|
614 # Need to recompile everything after changing this: "make clean" "make". | 614 # Need to recompile everything after changing this: "make clean" "make". |
615 #PROFILE_CFLAGS = -pg -g -DWE_ARE_PROFILING | 615 #PROFILE_CFLAGS = -pg -g -DWE_ARE_PROFILING |
616 #PROFILE_LIBS = -pg | 616 #PROFILE_LIBS = -pg |
617 #PROFILE_LIBS = -pg -lc | 617 #PROFILE_LIBS = -pg -lc |
618 | 618 |
619 # Uncomment one of the next two lines to compile Vim with the | |
620 # address sanitizer or with the undefined sanitizer. Works with gcc and | |
621 # clang. May make Vim twice as slow. Errors reported on stderr. | |
622 # More at: https://code.google.com/p/address-sanitizer/ | |
623 #SANITIZER_CFLAGS = -g -O0 -fsanitize=address -fno-omit-frame-pointer | |
624 #SANITIZER_CFLAGS = -g -O0 -fsanitize=undefined -fno-omit-frame-pointer | |
625 SANITIZER_LIBS = $(SANITIZER_CFLAGS) | |
626 | |
619 # MEMORY LEAK DETECTION | 627 # MEMORY LEAK DETECTION |
620 # Requires installing the ccmalloc library. | 628 # Requires installing the ccmalloc library. |
621 # Configuration is in the .ccmalloc or ~/.ccmalloc file. | 629 # Configuration is in the .ccmalloc or ~/.ccmalloc file. |
622 # Doesn't work very well, since memory linked to from global variables | 630 # Doesn't work very well, since memory linked to from global variables |
623 # (in libraries) is also marked as leaked memory. | 631 # (in libraries) is also marked as leaked memory. |
1340 .SUFFIXES: .c .o .pro | 1348 .SUFFIXES: .c .o .pro |
1341 | 1349 |
1342 PRE_DEFS = -Iproto $(DEFS) $(GUI_DEFS) $(GUI_IPATH) $(CPPFLAGS) $(EXTRA_IPATHS) | 1350 PRE_DEFS = -Iproto $(DEFS) $(GUI_DEFS) $(GUI_IPATH) $(CPPFLAGS) $(EXTRA_IPATHS) |
1343 POST_DEFS = $(X_CFLAGS) $(MZSCHEME_CFLAGS) $(TCL_CFLAGS) $(EXTRA_DEFS) | 1351 POST_DEFS = $(X_CFLAGS) $(MZSCHEME_CFLAGS) $(TCL_CFLAGS) $(EXTRA_DEFS) |
1344 | 1352 |
1345 ALL_CFLAGS = $(PRE_DEFS) $(CFLAGS) $(PROFILE_CFLAGS) $(LEAK_CFLAGS) $(POST_DEFS) | 1353 ALL_CFLAGS = $(PRE_DEFS) $(CFLAGS) $(PROFILE_CFLAGS) $(SANITIZER_CFLAGS) $(LEAK_CFLAGS) $(POST_DEFS) |
1346 | 1354 |
1347 # Exclude $CFLAGS for osdef.sh, for Mac 10.4 some flags don't work together | 1355 # Exclude $CFLAGS for osdef.sh, for Mac 10.4 some flags don't work together |
1348 # with "-E". | 1356 # with "-E". |
1349 OSDEF_CFLAGS = $(PRE_DEFS) $(POST_DEFS) | 1357 OSDEF_CFLAGS = $(PRE_DEFS) $(POST_DEFS) |
1350 | 1358 |
1372 $(PYTHON_LIBS) \ | 1380 $(PYTHON_LIBS) \ |
1373 $(PYTHON3_LIBS) \ | 1381 $(PYTHON3_LIBS) \ |
1374 $(TCL_LIBS) \ | 1382 $(TCL_LIBS) \ |
1375 $(RUBY_LIBS) \ | 1383 $(RUBY_LIBS) \ |
1376 $(PROFILE_LIBS) \ | 1384 $(PROFILE_LIBS) \ |
1385 $(SANITIZER_LIBS) \ | |
1377 $(LEAK_LIBS) | 1386 $(LEAK_LIBS) |
1378 | 1387 |
1379 # abbreviations | 1388 # abbreviations |
1380 DEST_BIN = $(DESTDIR)$(BINDIR) | 1389 DEST_BIN = $(DESTDIR)$(BINDIR) |
1381 DEST_VIM = $(DESTDIR)$(VIMLOC) | 1390 DEST_VIM = $(DESTDIR)$(VIMLOC) |
1889 ./$$t || exit 1; echo $$t passed; \ | 1898 ./$$t || exit 1; echo $$t passed; \ |
1890 done | 1899 done |
1891 | 1900 |
1892 # Run individual test, assuming that Vim was already compiled. | 1901 # Run individual test, assuming that Vim was already compiled. |
1893 test1 \ | 1902 test1 \ |
1903 test_argument_0count \ | |
1894 test_argument_count \ | 1904 test_argument_count \ |
1895 test_autoformat_join \ | 1905 test_autoformat_join \ |
1896 test_breakindent \ | 1906 test_breakindent \ |
1897 test_changelist \ | 1907 test_changelist \ |
1898 test_close_count \ | 1908 test_close_count \ |
1899 test_command_count \ | 1909 test_command_count \ |
1910 test_erasebackword \ | |
1900 test_eval \ | 1911 test_eval \ |
1901 test_insertcount \ | 1912 test_insertcount \ |
1913 test_listchars \ | |
1902 test_listlbr \ | 1914 test_listlbr \ |
1903 test_listlbr_utf8 \ | 1915 test_listlbr_utf8 \ |
1904 test_mapping \ | 1916 test_mapping \ |
1917 test_marks \ | |
1918 test_nested_function \ | |
1905 test_options \ | 1919 test_options \ |
1920 test_perl \ | |
1906 test_qf_title \ | 1921 test_qf_title \ |
1922 test_ruby \ | |
1923 test_set \ | |
1907 test_signs \ | 1924 test_signs \ |
1925 test_textobjects \ | |
1908 test_utf8 \ | 1926 test_utf8 \ |
1909 test_writefile \ | 1927 test_writefile \ |
1910 test2 test3 test4 test5 test6 test7 test8 test9 \ | 1928 test2 test3 test4 test5 test6 test7 test8 test9 \ |
1911 test10 test11 test12 test13 test14 test15 test16 test17 test18 test19 \ | 1929 test10 test11 test12 test13 test14 test15 test16 test17 test18 test19 \ |
1912 test20 test21 test22 test23 test24 test25 test26 test27 test28 test29 \ | 1930 test20 test21 test22 test23 test24 test25 test26 test27 test28 test29 \ |