diff options
-rw-r--r-- | Makefile | 4 | ||||
-rw-r--r-- | boblightservice.c | 13 | ||||
-rw-r--r-- | boblightservice.h | 4 |
3 files changed, 6 insertions, 15 deletions
@@ -14,6 +14,8 @@ PLUGIN = vdrboblight #VERSION = $(shell grep 'static const char \*VERSION *=' vdrboblight.h | awk '{ print $$6 }' | sed -e 's/[";]//g') VERSION := $(shell git describe --tags master) +LIBS += -lboblight + ### The directory environment: # Use package data if installed...otherwise assume we're under the VDR source directory: @@ -111,7 +113,7 @@ $(DEPFILE): Makefile ### Targets: $(SOFILE): $(OBJS) $(FFDECSA) - $(CXX) $(CXXFLAGS) $(LDFLAGS) -shared $(OBJS) $(DECSALIB) -o $@ + $(CXX) $(CXXFLAGS) $(LDFLAGS) -shared $(OBJS) $(DECSALIB) $(LIBS) -o $@ install-lib: $(SOFILE) diff --git a/boblightservice.c b/boblightservice.c index e8e289c..060f2d3 100644 --- a/boblightservice.c +++ b/boblightservice.c @@ -19,20 +19,9 @@ #include <stdio.h> -#define BOBLIGHT_DLOPEN #include <libboblight/boblight.h> #include "boblightservice.h" -cBoblight::cBoblight() -{ - - char* boblight_error = boblight_loadlibrary(NULL); - if (boblight_error) - { - error("Couldn't load libboblight"); - } -} - //*************************************************************************** // Open/Close //*************************************************************************** @@ -138,4 +127,4 @@ int cBoblight::sendOptions() { boblight_setpriority(m_boblight, cfg.priority); return success; -}
\ No newline at end of file +} diff --git a/boblightservice.h b/boblightservice.h index c34d9f3..22b270e 100644 --- a/boblightservice.h +++ b/boblightservice.h @@ -28,7 +28,7 @@ class cBoblight : public cAmbiService { public: - cBoblight(); + cBoblight() {}; ~cBoblight() { close(); } int open(); @@ -46,4 +46,4 @@ class cBoblight : public cAmbiService }; -#endif
\ No newline at end of file +#endif |