2010-05-28 12:04:50 +00:00
|
|
|
include config.mak
|
|
|
|
|
2010-05-26 19:27:37 +00:00
|
|
|
TARGET = ssnes
|
|
|
|
|
2010-05-29 14:59:57 +00:00
|
|
|
SOURCE = ssnes.c
|
2010-05-28 12:04:50 +00:00
|
|
|
LIBS = -lsamplerate -lsnes
|
|
|
|
|
|
|
|
ifeq ($(BUILD_RSOUND), 1)
|
|
|
|
SOURCE += rsound.c
|
|
|
|
LIBS += -lrsound
|
|
|
|
endif
|
2010-05-28 12:33:18 +00:00
|
|
|
ifeq ($(BUILD_OSS), 1)
|
|
|
|
SOURCE += oss.c
|
|
|
|
endif
|
2010-05-28 13:41:38 +00:00
|
|
|
ifeq ($(BUILD_ALSA), 1)
|
|
|
|
SOURCE += alsa.c
|
|
|
|
LIBS += -lasound
|
|
|
|
endif
|
2010-05-28 12:04:50 +00:00
|
|
|
|
|
|
|
ifeq ($(BUILD_OPENGL), 1)
|
|
|
|
SOURCE += gl.c
|
|
|
|
LIBS += -lglfw
|
|
|
|
endif
|
2010-05-29 14:59:57 +00:00
|
|
|
ifeq ($(BUILD_FILTER), 1)
|
|
|
|
SOURCE += hqflt/hq.c
|
|
|
|
endif
|
2010-05-28 12:04:50 +00:00
|
|
|
|
2010-05-28 12:33:18 +00:00
|
|
|
CFLAGS = -Wall -O2 -march=native -s
|
2010-05-26 19:27:37 +00:00
|
|
|
|
|
|
|
OBJ = ssnes.o
|
|
|
|
|
|
|
|
|
2010-05-28 12:04:50 +00:00
|
|
|
|
2010-05-28 16:07:04 +00:00
|
|
|
all:
|
2010-05-28 12:04:50 +00:00
|
|
|
$(CC) $(CFLAGS) -o $(TARGET) $(SOURCE) $(LIBS)
|
|
|
|
|
|
|
|
install: $(TARGET)
|
|
|
|
install -m755 $(TARGET) $(PREFIX)/bin
|
|
|
|
|
|
|
|
uninstall: $(TARGET)
|
|
|
|
rm -rf $(PREFIX)/bin/$(TARGET)
|
2010-05-26 19:27:37 +00:00
|
|
|
|
|
|
|
clean:
|
|
|
|
rm -rf $(OBJ)
|
|
|
|
rm -rf $(TARGET)
|