aboutsummaryrefslogtreecommitdiffstats
path: root/emulator/opengl/sdl.mk
blob: 658e2d449dc9c03b2b713a0b22702dac7a4dc25f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
# This contains common definitions used to define a host module to
# link SDL with the EmuGL test programs.

ifeq ($(BUILD_STANDALONE_EMULATOR),true)

# When using the emulator standalone build, inherit the values from the
# Makefile that included us.
EMUGL_SDL_CFLAGS := $(SDL_CFLAGS)
EMUGL_SDL_LDLIBS := $(SDL_LDLIBS)

else  # BUILD_STANDALONE_EMULATOR != true

# Otherwise, use the prebuilt libraries that come with the platform.

EMUGL_SDL_CONFIG ?= prebuilts/tools/$(HOST_PREBUILT_TAG)/sdl/bin/sdl-config
EMUGL_SDL_CFLAGS := $(shell $(EMUGL_SDL_CONFIG) --cflags)
EMUGL_SDL_LDLIBS := $(filter-out %.a %.lib,$(shell $(EMUGL_SDL_CONFIG) --static-libs))

ifeq ($(HOST_OS),windows)
EMUGL_SDL_LDLIBS += -lws2_32
endif

endif  # BUILD_STANDALONE_EMULATOR != true