mirror of
https://github.com/libsdl-org/SDL.git
synced 2024-11-27 05:43:29 +08:00
cmake: check for alloca() in stdlib.h and malloc.h, too (bug #5316)
This commit is contained in:
parent
fc795f89d3
commit
665cfa4981
@ -848,7 +848,12 @@ if(LIBC)
|
||||
|
||||
if(NOT APPLE)
|
||||
check_include_file(alloca.h HAVE_ALLOCA_H)
|
||||
check_symbol_exists(alloca "alloca.h" HAVE_ALLOCA)
|
||||
check_symbol_exists(alloca "alloca.h" HAVE_ALLOCA1)
|
||||
check_symbol_exists(alloca "stdlib.h" HAVE_ALLOCA2)
|
||||
check_symbol_exists(alloca "malloc.h" HAVE_ALLOCA3)
|
||||
if(HAVE_ALLOCA1 OR HAVE_ALLOCA2 OR HAVE_ALLOCA3)
|
||||
set(HAVE_ALLOCA 1)
|
||||
endif()
|
||||
else()
|
||||
set(HAVE_ALLOCA_H 1)
|
||||
set(HAVE_ALLOCA 1)
|
||||
|
Loading…
Reference in New Issue
Block a user