Build fixes for Emscripten (nw)

This commit is contained in:
Justin Kerk 2014-11-05 23:12:54 -08:00
parent ab15a23d33
commit 5e52630af1
2 changed files with 9 additions and 2 deletions

View File

@ -910,7 +910,7 @@ $(EMULATOR): $(EMUINFOOBJ) $(DRIVLISTOBJ) $(DRVLIBS) $(LIBOSD) $(LIBBUS) $(LIBOP
$(CC) $(CDEFS) $(CFLAGS) -c $(SRC)/version.c -o $(VERSIONOBJ)
@echo Linking $@...
ifeq ($(TARGETOS),emscripten)
# Emscripten's linker seems to be stricter about the ordering of .a files
# Emscripten's linker seems to be stricter about the ordering of .a files
$(LD) $(LDFLAGS) $(LDFLAGSEMULATOR) $(VERSIONOBJ) -Wl,--start-group $^ -Wl,--end-group $(LIBS) -o $@
else
$(LD) $(LDFLAGS) $(LDFLAGSEMULATOR) $(VERSIONOBJ) $^ $(LIBS) -o $@

View File

@ -83,13 +83,17 @@ SDL_FRAMEWORK_PATH = /Library/Frameworks/
OSDSRC = $(SRC)/osd
OSDOBJ = $(OBJ)/osd
# default to SDL2 for non-OS/2 builds now
# default to SDL2 for non-OS/2, non-Emscripten builds now
ifndef SDL_LIBVER
ifneq ($(TARGETOS),os2)
ifneq ($(TARGETOS),emscripten)
SDL_LIBVER = sdl2
else
SDL_LIBVER = sdl
endif
else
SDL_LIBVER = sdl
endif
endif
ifndef NO_USE_QTDEBUG
@ -258,6 +262,7 @@ NO_X11 = 1
NO_USE_XINPUT = 1
NO_USE_MIDI = 1
NO_USE_QTDEBUG = 1
DONT_USE_NETWORK = 1
endif
ifeq ($(TARGETOS),macosx)
@ -779,6 +784,8 @@ ifneq ($(TARGETOS),win32)
LIBS += -lpcap
endif
endif
else
OSDOBJS += $(SDLOBJ)/netdev.o
endif
#-------------------------------------------------