# AdPlub Plugin for GameMusicGear by gama
#   Based on AdPlug v2.2
#    2001 - 2009 Simon Peter.	

TARGET = in_adplug

OBJS = in_adplug.o

# Define to build this as a prx (instead of a static elf)
BUILD_PRX = 1
# Define the name of our custom exports (minus the .exp extension)
PRX_EXPORTS = ../Input_Exports.exp

CFLAGS = -G0 -O2 -Wall -ffast-math
CXXFLAGS = $(CFLAGS) -fno-exceptions -fno-rtti

LDFLAGS = -mno-crt0 -nostartfiles

LIBS = -ladplug22 -lm \
	   -lutils -lconfig -lstdc++

INCDIR = adplug-2.2 adplug-2.2/adplug adplug-2.2/binio
LIBDIR = adplug-2.2/adplug adplug-2.2/binio ../ShareLib/libutils ../SharedLib/libconfig

all: exports $(TARGET).prx
	
exports:
	psp-build-exports -s ../../Input_Exports.exp

PSPSDK = $(shell psp-config --pspsdk-path)
include $(PSPSDK)/lib/build.mak
