Here is a makefile for unixes systems:
<<
Project: crazeedood
Makefile created by Dev-C++ 4.9.9.2
CPP? = g++
CC?? = gcc
RES? =
OBJ? = src/crazeedood.o $(RES)
LINKOBJ? = src/crazeedood.o $(RES)
LIBS =? $(shell sdl-config --libs) -lSDL_image -lSDL_mixer -s
INCS =? $(shell sdl-config --cflags)
BIN? = crazeedood
CXXFLAGS = $(CXXINCS)?? -fexpensive-optimizations -O3
CFLAGS = $(INCS)?? -fexpensive-optimizations -O3
RM = rm -f
…PHONY: all all-before all-after clean clean-custom
all: all-before crazeedood all-after
clean: clean-custom
??? ${RM} $(OBJ) $(BIN)
$(BIN): $(OBJ)
??? $(CC) $(LINKOBJ) -o “crazeedood” $(LIBS)
src/crazeedood.o: src/crazeedood.c
??? $(CC) -c src/crazeedood.c -o src/crazeedood.o $(CFLAGS)
You have to replace the crazeedood header by:
<<
#ifdef WIN32
#include <SDL/SDL.h>
#include <SDL/SDL_image.h>
#include <SDL/SDL_mixer.h>
#define DATA_PREFIX “./”
#else
#include “SDL.h”
#include “SDL_image.h”
#include “SDL_mixer.h”
#define DATA_PREFIX “./”
#endif
(“SDL_mixer” instead of “SDL_Mixer”, and “DATA_PREFIX” was left undefined in non WIN32 systems …)
The program crashes even with sound disabled. GDB gives no relevant information even with the “-ggdb” switch turned on.
When you put “#ifdef WIN32” 's in your source code, be sure that it won’t crash in other systems … example if you allocate memory only in a #ifdef WIN32? section or something like this. I didn’t take time to look at the source code.
Julien
— En date de?: Jeu 5.3.09, Neil White a ?crit? Neil White
Objet: Re: [SDL] [Getting OT] Re: “Gauntlet” engine
?: “A list for developers using the SDL library. (includes SDL-announce)”
Date: Jeudi 5 Mars 2009, 11h30
2009/3/5 Neil White
ok, that was slightly wrong… must be 9 per isometric grid, its hurting my brain now, i dont want to look at the code cos i’ll probably end up doing it for the next week or something… but i have found a half working bit of code which was the level designer, you are welcome to rip it up fix it turn it inot its original intention whatver, i have put it here for your amusement http://www.cloudsprinter.com/random/crazee8way.zip yet another day i think i thould set upo myself a versioning code svn type scenario
www.cloudsprinter.com/random/crazee8way.zip
have fun!
please if anyone want to finish my dream of 8 way isometic pacman clone with a* i’ll pay you with a jelly bean or 3, of whicheve colour you like ( as long as it is possible to obtian jelly beans in that colour, no i want an ultraqviolet jelly bean )
i really should proof read before i click send, sorry i came to windows land to find this and firefox isnt set up with idiot check on
-----La pi?ce jointe associ?e suit-----
SDL mailing list
SDL at lists.libsdl.org
http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org