Skip to content

Commit 4917e1e

Browse files
pcloudsgitster
authored andcommitted
Makefile: promote wildmatch to be the default fnmatch implementation
This makes git use wildmatch by default for all fnmatch() calls. Users who want to use system fnmatch (or compat fnmatch) need to set NO_WILDMATCH flag. wildmatch is a drop-in fnmatch replacement with more features. Using wildmatch gives us a consistent behavior across platforms. The tentative plan is make it default with an opt-out for about 2 cycles, then remove NO_WILDMATCH and compat/fnmatch. Signed-off-by: Nguyễn Thái Ngọc Duy <[email protected]> Signed-off-by: Junio C Hamano <[email protected]>
1 parent edca415 commit 4917e1e

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

Makefile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -106,7 +106,7 @@ all::
106106
# Define NO_FNMATCH_CASEFOLD if your fnmatch function doesn't have the
107107
# FNM_CASEFOLD GNU extension.
108108
#
109-
# Define USE_WILDMATCH if you want to use Git's wildmatch
109+
# Define NO_WILDMATCH if you do not want to use Git's wildmatch
110110
# implementation as fnmatch
111111
#
112112
# Define NO_GECOS_IN_PWENT if you don't have pw_gecos in struct passwd
@@ -1261,7 +1261,7 @@ ifdef NO_FNMATCH_CASEFOLD
12611261
COMPAT_OBJS += compat/fnmatch/fnmatch.o
12621262
endif
12631263
endif
1264-
ifdef USE_WILDMATCH
1264+
ifndef NO_WILDMATCH
12651265
COMPAT_CFLAGS += -DUSE_WILDMATCH
12661266
endif
12671267
ifdef NO_SETENV

0 commit comments

Comments
 (0)