From 437e1fc59d8b0dddb9a0faf1e47d611f33a5f4e6 Mon Sep 17 00:00:00 2001 From: Dan Dennedy Date: Fri, 15 May 2009 00:57:03 -0700 Subject: [PATCH] Fix build of custom server example. Signed-off-by: Dan Dennedy --- src/examples/Makefile | 13 ++++--------- src/examples/server.cpp | 14 ++++++++------ 2 files changed, 12 insertions(+), 15 deletions(-) diff --git a/src/examples/Makefile b/src/examples/Makefile index 5a10be2..cda1a8a 100644 --- a/src/examples/Makefile +++ b/src/examples/Makefile @@ -1,21 +1,16 @@ -include ../config.mak +include ../../config.mak -CXXFLAGS+=-Wall -g `pkg-config mlt-framework --cflags` -I ../src -LDFLAGS+=-L../src -lmlt++ -lmiracle -lvalerie `pkg-config mlt-framework --libs` +CXXFLAGS += -Wall -g -I.. -I../melted++ `pkg-config mlt++ --cflags` +LDFLAGS += -L../melted++ -lmelted++ -L../melted -lmelted -L../mvcp -lmvcp `pkg-config mlt++ --libs` CC=c++ -all: play server - -play: play.o - -play.o: play.cpp +all: server server: server.o server.o: server.cpp clean: - $(RM) play play.o $(RM) server server.o distclean: clean diff --git a/src/examples/server.cpp b/src/examples/server.cpp index b82087f..c696bb4 100644 --- a/src/examples/server.cpp +++ b/src/examples/server.cpp @@ -5,9 +5,11 @@ using namespace std; #include +#include +#include using namespace Mlt; -class Custom : public Miracle +class Custom : public Melted { private: Event *event; @@ -15,10 +17,10 @@ class Custom : public Miracle public: Custom( char *name = "Custom", int port = 5290, char *config = NULL ) : - Miracle( name, port, config ), + Melted( name, port, config ), event( NULL ) { - // Ensure that we receive the westley document before it's deserialised + // Ensure that we receive the MLT XML document before it's deserialised set( "push-parser-off", 1 ); } @@ -27,11 +29,11 @@ class Custom : public Miracle delete event; } - // Optional step - receive the westley document and do something with it + // Optional step - receive the MLT XML document and do something with it Response *received( char *command, char *document ) { cerr << document << endl; - Producer producer( profile, "westley-xml", document ); + Producer producer( profile, "xml-string", document ); return push( command, &producer ); } @@ -75,7 +77,7 @@ class Custom : public Miracle else { // Use the default command processing - response = Miracle::execute( command ); + response = Melted::execute( command ); } // If no event exists and the first unit has been added... -- 1.7.4.4