fix WIN32CROSS build
This commit is contained in:
parent
8fc0b40b18
commit
53a1b20433
@ -14,12 +14,27 @@ BIN = showimage
|
||||
CFLAGS += -DUSE_SDL
|
||||
endif
|
||||
|
||||
ifdef WIN32CROSS
|
||||
CC = $(shell which i686-w64-mingw32-gcc || which mingw32-gcc)
|
||||
PKGCONFIG_PATH = $(shell if [ -d ../../3rdparty/usr ] ; then echo "PKG_CONFIG_LIBDIR=$${PWD}/../../3rdparty/usr/lib/pkgconfig" ; fi )
|
||||
PKGCONFIG = $(PKGCONFIG_PATH) $(shell which i686-w64-mingw32-pkg-config || which mingw32-pkg-config || which pkg-config)
|
||||
SDLCONFIG = $(shell which ../../3rdparty/usr/bin/sdl-config || which /usr/local/cross-tools/i386-mingw32/bin/sdl-config)
|
||||
BIN := $(BIN).exe
|
||||
else
|
||||
PKGCONFIG = pkg-config
|
||||
endif
|
||||
|
||||
CFLAGS += $(shell $(SDLCONFIG) --cflags)
|
||||
|
||||
LDLIBS = $(shell $(SDLCONFIG) --libs)
|
||||
LDLIBS += $(shell pkg-config $(SDLIMAGE) --libs-only-l)
|
||||
|
||||
LDFLAGS = $(shell pkg-config $(SDLIMAGE) --libs-only-L)
|
||||
ifdef WIN32CROSS
|
||||
LDLIBS += -lSDL_image
|
||||
else
|
||||
LDLIBS += $(shell $(PKGCONFIG) $(SDLIMAGE) --libs-only-l)
|
||||
|
||||
LDFLAGS = $(shell $(PKGCONFIG) $(SDLIMAGE) --libs-only-L)
|
||||
endif
|
||||
|
||||
.PHONY: all clean
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user