mirror of
https://github.com/LibreELEC/LibreELEC.tv
synced 2025-09-24 19:46:01 +07:00
55 lines
1.7 KiB
Diff
55 lines
1.7 KiB
Diff
diff --git a/Makefile b/Makefile
|
|
index efd124a..ed303fa 100644
|
|
--- a/Makefile
|
|
+++ b/Makefile
|
|
@@ -12,22 +12,14 @@ PLUGIN = dvbapi
|
|
### The version number of this plugin (taken from the main source file):
|
|
|
|
VERSION = $(shell grep 'static const char \*VERSION *=' DVBAPI.h | awk '{ print $$6 }' | sed -e 's/[";]//g')
|
|
-GITTAG = $(shell git describe --always 2>/dev/null)
|
|
|
|
### The directory environment:
|
|
|
|
-# Use package data if installed...otherwise assume we're under the VDR source directory:
|
|
-PKGCFG = $(if $(VDRDIR),$(shell pkg-config --variable=$(1) $(VDRDIR)/vdr.pc),$(shell PKG_CONFIG_PATH="$$PKG_CONFIG_PATH:../../.." pkg-config --variable=$(1) vdr))
|
|
-LIBDIR = $(call PKGCFG,libdir)
|
|
-LOCDIR = $(call PKGCFG,locdir)
|
|
-PLGCFG = $(call PKGCFG,plgcfg)
|
|
-#
|
|
TMPDIR ?= /tmp
|
|
|
|
### The compiler options:
|
|
|
|
-export CFLAGS = $(call PKGCFG,cflags)
|
|
-export CXXFLAGS = $(call PKGCFG,cxxflags)
|
|
+include $(VDRDIR)/Make.global
|
|
|
|
### Allow user defined options to overwrite defaults:
|
|
|
|
@@ -35,7 +27,7 @@ export CXXFLAGS = $(call PKGCFG,cxxflags)
|
|
|
|
### The version number of VDR's plugin API:
|
|
|
|
-APIVERSION = $(call PKGCFG,apiversion)
|
|
+APIVERSION = $(shell sed -ne '/define APIVERSION/s/^.*"\(.*\)".*$$/\1/p' $(VDRDIR)/config.h)
|
|
|
|
### The name of the distribution archive:
|
|
|
|
@@ -48,7 +40,7 @@ SOFILE = libvdr-$(PLUGIN).so
|
|
|
|
### Includes and Defines (add further entries here):
|
|
|
|
-INCLUDES +=
|
|
+INCLUDES += -I$(VDRDIR)/include
|
|
|
|
DEFINES += -DPLUGIN_NAME_I18N='"$(PLUGIN)"'
|
|
|
|
@@ -122,6 +114,7 @@ install-i18n: $(I18Nmsgs)
|
|
|
|
$(SOFILE): $(OBJS) $(FFDECSA)
|
|
$(CXX) $(CXXFLAGS) $(LDFLAGS) -shared $(OBJS) $(DECSALIB) -o $@
|
|
+ @cp --remove-destination $@ $(LIBDIR)/$@.$(APIVERSION)
|
|
|
|
ifndef LIBDVBCSA
|
|
$(FFDECSA): $(FFDECSADIR)/*.c $(FFDECSADIR)/*.h
|