diff options
-rw-r--r-- | Makefile | 8 | ||||
-rw-r--r-- | plugins/profiler/vdrDVBProfiler/dvbProfiler.cpp | 18 |
2 files changed, 20 insertions, 6 deletions
@@ -57,7 +57,7 @@ LIBS += -lupnp -lcxxtools -ltntnet -ltntdb -ldl ### The main target: -all: libvdr-$(PLUGIN).so i18n +all: plugin subplugins ### Implicit rules: @@ -103,6 +103,8 @@ i18n: $(I18Nmsgs) $(I18Npot) ### Targets: +plugin: libvdr-$(PLUGIN).so i18n + libvdr-$(PLUGIN).so: $(OBJS) $(TNTOBJ) $(CXX) $(CXXFLAGS) $(LDFLAGS) -rdynamic -shared $(OBJS) $(TNTOBJ) $(LIBS) -o $@ @cp --remove-destination $@ $(LIBDIR)/$@.$(APIVERSION) @@ -126,7 +128,9 @@ dist: $(I18Npo) clean @-rm -rf $(TMPDIR)/$(ARCHIVE) @echo Distribution package created as $(PACKAGE).tgz -clean: +clean: clean-plugin clean-subplugins + +clean-plugin: @-rm -f $(OBJS) $(TNTOBJ) $(DEPFILE) *.so *.so.$(APIVERSION) *.tgz core* *~ $(PODIR)/*.mo $(PODIR)/*.pot clean-subplugins: diff --git a/plugins/profiler/vdrDVBProfiler/dvbProfiler.cpp b/plugins/profiler/vdrDVBProfiler/dvbProfiler.cpp index 22285b4..9873fe4 100644 --- a/plugins/profiler/vdrDVBProfiler/dvbProfiler.cpp +++ b/plugins/profiler/vdrDVBProfiler/dvbProfiler.cpp @@ -111,7 +111,11 @@ public: } virtual bool CanHandleSchema(const string& schema){ - if(schema.find("vdr",0) == 0 || schema.find("rec",0) == 0){ +#if VDRVERSNUM > 10704 + if( schema.find("vdr",0) == 0 || schema.find("rec",0) == 0 ){ +#else + if( schema.find("vdr",0) == 0 ) { +#endif return true; } else { return false; @@ -121,9 +125,13 @@ public: virtual bool GetMetadata(const string& uri, cMetadata& metadata){ if (uri.find("vdr",0) == 0){ return GetChannelMetadata(uri, metadata); - } else if (uri.find("rec",0) == 0){ + } +#if VDRVERSNUM > 10704 + else if (uri.find("rec",0) == 0){ return GetRecordingMetadata(uri, metadata); - } else { + } +#endif + else { return false; } } @@ -132,6 +140,7 @@ public: private: +#if VDRVERSNUM > 10704 bool GetRecordingMetadata(const string& u, cMetadata& metadata){ string videoDir = string(VideoDirectory), uri = u.substr(6), recStr = videoDir + "/" + uri; cRecording* recording = Recordings.GetByName(recStr.c_str()); @@ -188,7 +197,7 @@ private: #if VDRVERSNUM < 10732 if (pid == parser.PmtPid()) #else - if (PatPmtParser.IsPmtPid(pid)) + if (parser.IsPmtPid(pid)) #endif { parser.ParsePmt(buf, TS_SIZE); @@ -302,6 +311,7 @@ private: return true; } +#endif bool GetChannelMetadata(const string& uri, cMetadata& metadata){ |