Moved cross-platform sources into their own directory so that Windows builds don't need to add Unix to the include directory list.

This commit is contained in:
James Touton 2015-08-06 01:53:29 -07:00
parent c92feaf767
commit 284900f905
9 changed files with 11 additions and 10 deletions

View File

@ -21,7 +21,7 @@ CFLAGS = @CFLAGS@
CXXFLAGS = @CXXFLAGS@
CPUINCLUDES_FLAGS=@CPUINCLUDES@
CPUINCLUDES_FLAGS:=$(CPUINCLUDES_FLAGS:-I%=-I@top_srcdir@/%)
CPPFLAGS = @CPPFLAGS@ -I@top_srcdir@/../include -I@top_srcdir@/. -I. $(CPUINCLUDES_FLAGS) -I@top_srcdir@/../slirp
CPPFLAGS = @CPPFLAGS@ -I@top_srcdir@/../include -I@top_srcdir@/. -I. -I@top_srcdir@/../CrossPlatform $(CPUINCLUDES_FLAGS) -I@top_srcdir@/../slirp
DEFS = @DEFS@ @DEFINES@ -D_REENTRANT -DDATADIR=\"$(datadir)/$(APP)\"
LDFLAGS = @LDFLAGS@
LIBS = @LIBS@
@ -43,17 +43,18 @@ GUI_LIBS = @GUI_LIBS@
GUI_SRCS = ../prefs.cpp prefs_unix.cpp prefs_editor_gtk.cpp ../prefs_items.cpp \
../user_strings.cpp user_strings_unix.cpp xpram_unix.cpp sys_unix.cpp rpc_unix.cpp
XPLAT_SRCS = ../CrossPlatform/vm_alloc.cpp ../CrossPlatform/sigsegv.cpp ../CrossPlatform/video_blit.cpp
## Files
SRCS = ../main.cpp ../prefs.cpp ../prefs_items.cpp \
sys_unix.cpp ../rom_patches.cpp ../slot_rom.cpp ../rsrc_patches.cpp \
../emul_op.cpp ../macos_util.cpp ../xpram.cpp xpram_unix.cpp ../timer.cpp \
timer_unix.cpp ../adb.cpp ../serial.cpp ../ether.cpp \
../sony.cpp ../disk.cpp ../cdrom.cpp ../scsi.cpp ../video.cpp \
video_blit.cpp \
vm_alloc.cpp sigsegv.cpp ../audio.cpp ../extfs.cpp disk_sparsebundle.cpp \
../audio.cpp ../extfs.cpp disk_sparsebundle.cpp \
tinyxml2.cpp \
../user_strings.cpp user_strings_unix.cpp sshpty.c strlcpy.c rpc_unix.cpp \
$(SYSSRCS) $(CPUSRCS) $(SLIRP_SRCS)
$(XPLAT_SRCS) $(SYSSRCS) $(CPUSRCS) $(SLIRP_SRCS)
APP_FLAVOR ?=
ifneq ($(APP_FLAVOR),)
CURR_APP_FLAVOR := -$(APP_FLAVOR)

View File

@ -37,7 +37,7 @@ CC = @CC@
CXX = @CXX@
CFLAGS = @CFLAGS@ $(SDL_CFLAGS)
CXXFLAGS = @CXXFLAGS@ $(SDL_CFLAGS)
CPPFLAGS = @CPPFLAGS@ -I../include -I. @CPUINCLUDES@ -I../slirp
CPPFLAGS = @CPPFLAGS@ -I../include -I. -I../CrossPlatform @CPUINCLUDES@ -I../slirp
DEFS = @DEFS@ @DEFINES@
LDFLAGS = @LDFLAGS@
LIBS = @LIBS@ -lwsock32 -liphlpapi
@ -50,7 +50,7 @@ HOST_CXXFLAGS = -O2
HOST_LDFLAGS =
## Files
UNIXSRCS = vm_alloc.cpp vm_alloc.h sigsegv.cpp sigsegv.h video_vosf.h video_blit.cpp video_blit.h
XPLATSRCS = vm_alloc.cpp vm_alloc.h sigsegv.cpp sigsegv.h video_vosf.h video_blit.cpp video_blit.h
CDENABLESRCS = cdenable/cache.cpp cdenable/eject_nt.cpp cdenable/ntcd.cpp
@ -91,7 +91,7 @@ endif
all: $(PROGS)
$(UNIXSRCS): %: ../Unix/%
$(XPLATSRCS): %: ../CrossPlatform/%
$(LN_S) $< $@
OBJ_DIR = obj
@ -114,17 +114,17 @@ SRC_PATHS += $(sort $(foreach file, $(SRCS), $(dir $(file))))
VPATH :=
VPATH += $(addprefix :, $(subst ,:, $(filter-out $($(subst, :, ,$(VPATH))), $(SRC_PATHS))))
$(APP): $(UNIXSRCS) $(OBJ_DIR) $(OBJS)
$(APP): $(XPLATSRCS) $(OBJ_DIR) $(OBJS)
$(CXX) -o $@ $(LDFLAGS) $(OBJS) $(LIBS) $(SDL_LIBS)
$(UI_APP): $(UNIXSRCS) $(OBJ_DIR) $(UI_OBJS)
$(UI_APP): $(XPLATSRCS) $(OBJ_DIR) $(UI_OBJS)
$(CXX) -o $@ $(LDFLAGS) $(UI_OBJS) $(LIBS) $(GTK_LIBS) -mwindows -mno-cygwin
mostlyclean:
rm -f $(APP) $(UI_APP) $(OBJ_DIR)/* core* *.core *~ *.bak
clean: mostlyclean
rm -f $(UNIXSRCS)
rm -f $(XPLATSRCS)
rm -f cpuemu.cpp cpudefs.cpp cputmp*.s cpufast*.s cpustbl.cpp cputbl.h compemu.cpp compstbl.cpp comptbl.h
distclean: clean