mlt_repository.[hc]:
[melted] / src / framework / Makefile
index 9c24a58..5ee621f 100644 (file)
@@ -3,6 +3,16 @@ include ../../config.mak
 NAME = libmlt$(LIBSUF)
 TARGET = $(NAME).$(version)
 
+ifneq ($(targetos), Darwin)
+NAME = libmlt$(LIBSUF)
+TARGET = $(NAME).$(version)
+SHFLAGS += -Wl,-soname,$(TARGET)
+else
+NAME = libmlt$(LIBSUF)
+TARGET = libmlt.$(version)$(LIBSUF)
+SHFLAGS += -install_name $(libdir)/$(TARGET)
+endif
+
 OBJS = mlt_frame.o \
           mlt_geometry.o \
           mlt_deque.o \
@@ -22,7 +32,8 @@ OBJS = mlt_frame.o \
           mlt_factory.o \
           mlt_repository.o \
           mlt_pool.o \
-          mlt_tokeniser.o
+          mlt_tokeniser.o \
+          mlt_profile.o
 
 INCS = mlt_consumer.h \
           mlt_factory.h \
@@ -45,13 +56,14 @@ INCS = mlt_consumer.h \
           mlt_property.h \
           mlt_service.h  \
           mlt_transition.h \
-          mlt_tokeniser.h
+          mlt_tokeniser.h \
+          mlt_profile.h
 
 SRCS := $(OBJS:.o=.c)
 
-CFLAGS += $(RDYNAMIC) -DPREFIX="\"$(prefix)\""
+CFLAGS += $(RDYNAMIC) -DPREFIX="\"$(prefix)\"" -DLIBDIR="\"$(libdir)\""
 
-LDFLAGS += -Wl,-soname,libmlt.so.$(version) -lm $(LIBDL) -lpthread
+LDFLAGS += -lm $(LIBDL) -lpthread
 
 all:   $(TARGET)
 
@@ -75,6 +87,11 @@ install:
        install -d "$(DESTDIR)$(prefix)/include/mlt/framework"
        install -m 644 $(INCS) "$(DESTDIR)$(prefix)/include/mlt/framework"
 
+uninstall:
+       rm -f "$(DESTDIR)$(libdir)/$(TARGET)"
+       rm -f "$(DESTDIR)$(libdir)/$(NAME)"
+       rm -rf "$(DESTDIR)$(prefix)/include/mlt/framework"
+
 ifneq ($(wildcard .depend),)
 include .depend
 endif