3rdparty: build and install Win32/atari/native files in specific directories

This commit is contained in:
Thomas Bernard
2019-03-18 10:52:35 +01:00
parent 9b2f256b63
commit da7b5d0b95
3 changed files with 83 additions and 59 deletions

View File

@@ -14,21 +14,25 @@ BIN = showimage
CFLAGS += -DUSE_SDL
endif
PKGCONFIG_PATH = $(shell if [ -d ../../3rdparty/usr ] ; then echo "PKG_CONFIG_LIBDIR=$${PWD}/../../3rdparty/usr/lib/pkgconfig" ; fi )
PLATFORM =
3RDPARTYDIR = ../../3rdparty/usr$(PLATFORM)
PKGCONFIG_PATH = $(shell if [ -d $(3RDPARTYDIR) ] ; then echo "PKG_CONFIG_LIBDIR=$${PWD}/$(3RDPARTYDIR)/lib/pkgconfig" ; fi )
ifdef WIN32CROSS
PLATFORM = -win32
CC = $(shell which i686-w64-mingw32-gcc || which mingw32-gcc)
PKGCONFIG = $(PKGCONFIG_PATH) $(shell which i686-w64-mingw32-pkg-config || which mingw32-pkg-config || which pkg-config)
SDLCONFIG = $(shell which ../../3rdparty/usr/bin/$(SDLCONFIGNAME) || which /usr/local/cross-tools/i386-mingw32/bin/$(SDLCONFIGNAME))
SDLCONFIG = $(shell which $(3RDPARTYDIR)/bin/$(SDLCONFIGNAME) || which /usr/local/cross-tools/i386-mingw32/bin/$(SDLCONFIGNAME))
BIN := $(BIN).exe
else
ifdef ATARICROSS
PLATFORM = -atari
ARCH ?= m68k
CC = $(shell which $(ARCH)-atari-mint-gcc)
BIN := $(BIN).ttp
endif
PKGCONFIG = $(PKGCONFIG_PATH) pkg-config
SDLCONFIG = $(shell which ../../3rdparty/usr/bin/$(SDLCONFIGNAME) || which $(SDLCONFIGNAME))
SDLCONFIG = $(shell which $(3RDPARTYDIR)/bin/$(SDLCONFIGNAME) || which $(SDLCONFIGNAME))
endif
CFLAGS += $(shell $(SDLCONFIG) --cflags)