summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristian <zerov83@gmail.com>2016-01-17 20:22:46 +0100
committerChristian <zerov83@gmail.com>2016-01-17 20:22:46 +0100
commitc1084ebf878a13eecff0eb6125a15057f0ea7076 (patch)
treeeeef550ae032b465bfc023d31132d2d626c1ef55
parent040d8d8becbb132bb4dbb0d2d1510175e8c2e080 (diff)
downloadvdr-plugin-boblight-c1084ebf878a13eecff0eb6125a15057f0ea7076.tar.gz
vdr-plugin-boblight-c1084ebf878a13eecff0eb6125a15057f0ea7076.tar.bz2
linking libboblight correctly0.0.7
-rw-r--r--Makefile4
-rw-r--r--boblightservice.c13
-rw-r--r--boblightservice.h4
3 files changed, 6 insertions, 15 deletions
diff --git a/Makefile b/Makefile
index a8607f9..8dbac4a 100644
--- a/Makefile
+++ b/Makefile
@@ -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