+include ../../../config.mak
-TARGET = ../libmltsdl.so
+TARGET = ../libmltsdl$(LIBSUF)
OBJS = factory.o \
- consumer_sdl.o
+ consumer_sdl.o \
+ consumer_sdl_preview.o \
+ consumer_sdl_still.o
-CFLAGS = -O3 -I../../ `sdl-config --cflags` -Wall -g -D_FILE_OFFSET_BITS=64 -pthread
+ifeq ($(targetos),Darwin)
+ CFLAGS +=-ObjC
+ LDFLAGS +=-lobjc -framework Foundation
+endif
+
+CFLAGS +=-I../.. `sdl-config --cflags`
+
+LDFLAGS +=`sdl-config --libs`
+
+LDFLAGS +=-L../../framework -lmlt
-LDFLAGS= `sdl-config --libs`
SRCS := $(OBJS:.o=.c)
all: $(TARGET)
$(TARGET): $(OBJS)
- $(CC) -shared -o $@ $(OBJS) $(LDFLAGS)
+ $(CC) $(SHFLAGS) -o $@ $(OBJS) $(LDFLAGS)
depend: $(SRCS)
$(CC) -MM $(CFLAGS) $^ 1>.depend
clean:
rm -f $(OBJS) $(TARGET)
+install: all
+ install -m 755 $(TARGET) "$(prefix)/share/mlt/modules"
+
ifneq ($(wildcard .depend),)
include .depend
endif