Git fork

mingw: activate alloca

Both MSVC and MINGW have alloca(3) definitions in malloc.h, so by moving
win32-compat alloca.h from compat/vcbuild/include/ to compat/win32/ ,
which is included by both MSVC and MINGW CFLAGS, we can make alloca()
work on both those Windows environments.

In MINGW, malloc.h has explicit check for GNUC and if it is so, defines
alloca to __builtin_alloca, so it looks like we don't need to add any
code to here-shipped alloca.h to get optimum performance.

Compile-tested on Windows in MSysGit.

Signed-off-by: Kirill Smelkov <kirr@mns.spb.ru>
Acked-by: Erik Faye-Lund <kusmabite@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

authored by

Kirill Smelkov and committed by
Junio C Hamano
22f4c27e 7195fbfa

+1
compat/vcbuild/include/alloca.h compat/win32/alloca.h
+1
config.mak.uname
··· 480 480 endif 481 481 ifneq (,$(findstring MINGW,$(uname_S))) 482 482 pathsep = ; 483 + HAVE_ALLOCA_H = YesPlease 483 484 NO_PREAD = YesPlease 484 485 NEEDS_CRYPTO_WITH_SSL = YesPlease 485 486 NO_LIBGEN_H = YesPlease