Merge branch 'review-1' of git://github.com/rayl/mlt
[melted] / src / modules / westley / Makefile
index a5d5d18..dda026e 100644 (file)
@@ -1,34 +1,36 @@
 include ../../../config.mak
 
-TARGET = ../libmltwestley.so
+TARGET = ../libmltwestley$(LIBSUF)
 
 OBJS = factory.o \
           consumer_westley.o \
           producer_westley.o
 
-CFLAGS = -O3 -I../../ -Wall -g -D_FILE_OFFSET_BITS=64 -pthread `xml2-config --cflags`
+CFLAGS += -I../../ `xml2-config --cflags`
 
-LDFLAGS = `xml2-config --libs`
+LDFLAGS += `xml2-config --libs`
+
+LDFLAGS+=-L../../framework -lmlt
 
 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
 
-dist-clean:    clean
+distclean:     clean
                rm -f .depend
 
 clean: 
                rm -f $(OBJS) $(TARGET) 
 
 install: all
-       install -m 755 $(TARGET) "$(prefix)/share/mlt/modules"
-       install -m 644 westley.dtd "$(prefix)/share/mlt/modules"
+       install -m 755 $(TARGET) "$(DESTDIR)$(libdir)/mlt"
+       install -m 644 westley.dtd "$(DESTDIR)$(prefix)/share/mlt"
 
 ifneq ($(wildcard .depend),)
 include .depend