]> granicus.if.org Git - vim/commitdiff
patch 8.2.1583: MS-Windows: cannot easily measure code coverage v8.2.1583
authorBram Moolenaar <Bram@vim.org>
Thu, 3 Sep 2020 17:50:05 +0000 (19:50 +0200)
committerBram Moolenaar <Bram@vim.org>
Thu, 3 Sep 2020 17:50:05 +0000 (19:50 +0200)
Problem:    MS-Windows: cannot easily measure code coverage.
Solution:   Add the COVERAGE option. (Ken Takata, closes #6842)

src/Make_cyg_ming.mak
src/version.c

index db0513f43247c63ba588dcfa504a1e66f6c7e8be..5fc08331daddc92c4487674598ba567e7552a7ba 100644 (file)
@@ -38,6 +38,9 @@ DEBUG=no
 # set to yes to create a mapfile
 #MAP=yes
 
+# set to yes to measure code coverage
+COVERAGE=no
+
 # set to SIZE for size, SPEED for speed, MAXSPEED for maximum optimization
 OPTIMIZE=MAXSPEED
 
@@ -700,6 +703,11 @@ CFLAGS += -O2
 LFLAGS += -s
 endif
 
+ifeq ($(COVERAGE),yes)
+CFLAGS += --coverage
+LFLAGS += --coverage
+endif
+
 LIB = -lkernel32 -luser32 -lgdi32 -ladvapi32 -lcomdlg32 -lcomctl32 -lnetapi32 -lversion
 GUIOBJ =  $(OUTDIR)/gui.o $(OUTDIR)/gui_w32.o $(OUTDIR)/gui_beval.o
 CUIOBJ = $(OUTDIR)/iscygpty.o
@@ -938,6 +946,9 @@ EXELFLAGS += -municode
  ifneq ($(DEBUG),yes)
 EXELFLAGS += -s
  endif
+ ifeq ($(COVERAGE),yes)
+EXELFLAGS += --coverage
+ endif
 DEFINES += $(DEF_GUI) -DVIMDLL
 OBJ += $(GUIOBJ) $(CUIOBJ)
 OUTDIR = dobj$(DEBUG_SUFFIX)$(MZSCHEME_SUFFIX)$(ARCH)
index 9c5f37097df93476eea972315e9e46267c58d249..de956a642d4685f882d2550658ff61ce857d7420 100644 (file)
@@ -754,6 +754,8 @@ static char *(features[]) =
 
 static int included_patches[] =
 {   /* Add new patch number below this line */
+/**/
+    1583,
 /**/
     1582,
 /**/