--- src/build/makefile.orig Tue Feb 18 10:19:44 2003 +++ src/build/makefile Tue Sep 16 21:48:28 2003 @@ -23,7 +23,7 @@ ## Comment a line out to disable that option, remove comment to enable it. ##============================================================================ -OPTIMIZATIONS = -O2 -Wall -Wno-unused +# OPTIMIZATIONS = -O2 -Wall -Wno-unused ### to get full optimization under gcc/x Intel based OS's.. # OPTIMIZATIONS = -O3 -mcpu=pentiumpro -march=pentiumpro -Wall -Wno-unused \ # -funroll-loops -fstrength-reduce -fomit-frame-pointer -ffast-math \ @@ -61,7 +61,7 @@ ### to include support for saving snapshots in png format ### (requires PNG library) ### Only X11 and SDL ports supported for now -# SNAPSHOT_SUPPORT = 1 +SNAPSHOT_SUPPORT = 1 ### comment this out if your system doesn't ### have the gettimeofday function @@ -79,8 +79,8 @@ ## No configurable options below this line ... ##============================================================================ -CXX = g++ -LD = g++ +CXX ?= g++ +LD = $(CXX) LDFLAGS = LDLIBS = @@ -92,8 +92,8 @@ OBJS.SDL = OPTS.SDL = -LIBS.SDL = `sdl-config --libs` -CFLAGS.SDL = `sdl-config --cflags` +LIBS.SDL = `${SDL_CONFIG} --libs` +CFLAGS.SDL = `${SDL_CONFIG} --cflags` OPTS.DOS = @@ -103,7 +103,7 @@ INCLUDES = -I. -I$(CORE) -I$(CORE)/m6502/src -I$(CORE)/m6502/src/bspf/src -I$(UI)/common -CXXFLAGS = $(OPTIMIZATIONS) $(INCLUDES) $(SYS_INCLUDES) +CXXFLAGS += $(OPTIMIZATIONS) $(INCLUDES) $(SYS_INCLUDES) ## set the user-defined options ifdef BSPF_BOOL @@ -265,6 +265,32 @@ LDLIBS+="$(LIBS.X11)" \ OBJS="mainX11.o" OBJS+="$(OBJS.X11)" + +freebsd-x: + $(MAKE) stella.x11 \ + INCLUDES="$(INCLUDES) -I$(UI)/x11 -I$(UI)/sound" \ + SYS_INCLUDES="-I$(X11BASE)/include -I$(LOCALBASE)/include/libpng" \ + OPTIONS="-DBSPF_UNIX=1" \ + OPTIONS+="$(OPTS.X11)" \ + LDFLAGS="-L$(X11BASE)/lib -L$(LOCALBASE)/lib" \ + LDFLAGS+="$(CFLAGS.X11)" \ + LDLIBS="-lX11 -lXext" \ + LDLIBS+="$(LIBS.X11)" \ + OBJS="mainX11.o" \ + OBJS+="$(OBJS.X11)" + +freebsd-sdl: + $(MAKE) stella.sdl \ + INCLUDES="$(INCLUDES) -I$(UI)/sdl -I$(UI)/sound" \ + SYS_INCLUDES="-I$(X11BASE)/include -I$(LOCALBASE)/include/libpng" \ + OPTIONS="-DBSPF_UNIX=1" \ + OPTIONS+="$(OPTS.SDL)" \ + LDFLAGS="-L$(X11BASE)/lib -L$(LOCALBASE)/lib" \ + LDFLAGS+="$(CFLAGS.SDL)" \ + LDLIBS="-lX11 -lXext" \ + LDLIBS+="$(LIBS.SDL)" \ + OBJS="mainSDL.o RectList.o" \ + OBJS+="$(OBJS.SDL)" ############################################################################### ## List of "core" object files