2011-09-20 14:38:12 +08:00
|
|
|
CC = gcc
|
|
|
|
CXX = g++
|
2011-09-28 13:56:06 +08:00
|
|
|
TARGET = libcocosdenshion.so
|
2011-09-20 14:38:12 +08:00
|
|
|
CCFLAGS = -Wall -g -O2
|
|
|
|
CXXFLAGS = -Wall -g -O2
|
|
|
|
VISIBILITY =
|
|
|
|
|
|
|
|
INCLUDES = -I.. \
|
|
|
|
-I../include \
|
|
|
|
-I../third_party/fmod/api/inc
|
|
|
|
|
|
|
|
DEFINES = -DLINUX
|
|
|
|
|
|
|
|
OBJECTS = ../Linux/FmodAudioPlayer.o \
|
|
|
|
../Linux/SimpleAudioEngine.o \
|
|
|
|
|
|
|
|
|
|
|
|
STATICLIBS =
|
|
|
|
SHAREDLIBS = -lfmodex
|
|
|
|
|
|
|
|
####### Build rules
|
|
|
|
$(TARGET): $(OBJECTS)
|
|
|
|
$(CXX) $(CXXFLAGS) $(INCLUDES) $(DEFINES) $(OBJECTS) -shared -o $(TARGET) $(SHAREDLIBS) $(STATICLIBS)
|
|
|
|
|
|
|
|
####### Compile
|
|
|
|
%.o: %.cpp
|
|
|
|
$(CXX) $(CXXFLAGS) $(INCLUDES) $(DEFINES) $(VISIBILITY) -c $< -o $@
|
|
|
|
|
|
|
|
%.o: %.c
|
|
|
|
$(CC) $(CCFLAGS) $(INCLUDES) $(DEFINES) $(VISIBILITY) -c $< -o $@
|
|
|
|
|
|
|
|
clean:
|
2011-09-28 13:56:06 +08:00
|
|
|
rm -f $(OBJECTS) $(TARGET) core
|