Fix it more

This commit is contained in:
Tim Angus 2013-03-22 14:47:37 +00:00
parent 6155816672
commit 02a625a1b3
2 changed files with 12 additions and 9 deletions

View file

@ -480,22 +480,24 @@ ifeq ($(PLATFORM),mingw32)
ifeq ($(CROSS_COMPILING),1) ifeq ($(CROSS_COMPILING),1)
# If CC is already set to something generic, we probably want to use # If CC is already set to something generic, we probably want to use
# something more specific # something more specific
ifneq ($(findstring $(CC),cc gcc),) ifneq ($(findstring $(strip $(CC)),cc gcc),)
CC= CC=
endif endif
# We need to figure out the correct compiler # We need to figure out the correct gcc and windres
ifeq ($(CC),) ifeq ($(ARCH),x86_64)
ifeq ($(ARCH),x86_64) MINGW_PREFIXES=amd64-mingw32msvc x86_64-w64-mingw32
MINGW_PREFIXES=amd64-mingw32msvc x86_64-w64-mingw32 endif
endif ifeq ($(ARCH),x86)
ifeq ($(ARCH),x86) MINGW_PREFIXES=i586-mingw32msvc i686-w64-mingw32
MINGW_PREFIXES=i586-mingw32msvc i686-w64-mingw32 endif
endif
ifndef CC
CC=$(strip $(foreach MINGW_PREFIX, $(MINGW_PREFIXES), \ CC=$(strip $(foreach MINGW_PREFIX, $(MINGW_PREFIXES), \
$(call bin_path, $(MINGW_PREFIX)-gcc))) $(call bin_path, $(MINGW_PREFIX)-gcc)))
endif
ifndef WINDRES
WINDRES=$(strip $(foreach MINGW_PREFIX, $(MINGW_PREFIXES), \ WINDRES=$(strip $(foreach MINGW_PREFIX, $(MINGW_PREFIXES), \
$(call bin_path, $(MINGW_PREFIX)-windres))) $(call bin_path, $(MINGW_PREFIX)-windres)))
endif endif

View file

@ -6,6 +6,7 @@ failed=0;
if [ "$CC" = "i686-w64-mingw32-gcc" ]; then if [ "$CC" = "i686-w64-mingw32-gcc" ]; then
export PLATFORM=mingw32 export PLATFORM=mingw32
export ARCH=x86 export ARCH=x86
export CC=
haveExternalLibs=0 haveExternalLibs=0
else else
haveExternalLibs=1 haveExternalLibs=1