mirror of
https://github.com/jojo61/vdr-plugin-softhdcuvid.git
synced 2025-03-01 10:39:28 +00:00
- Reindent all sources to common coding style again.
- Fix compile bug occurred with gcc10 (-fno-common is now default)
This commit is contained in:
40
Makefile
40
Makefile
@@ -1,6 +1,6 @@
|
||||
#
|
||||
# Makefile for a Video Disk Recorder plugin
|
||||
#
|
||||
#
|
||||
# $Id: 2a41981a57e5e83036463c6a08c84b86ed9d2be3 $
|
||||
|
||||
# The official name of this plugin.
|
||||
@@ -11,7 +11,7 @@
|
||||
### Configuration (edit this for your needs)
|
||||
# config as needed
|
||||
|
||||
# what kind of decoder do we make -
|
||||
# what kind of decoder do we make -
|
||||
# if VAAPI is enabled the pluginname is softhdvaapi
|
||||
# if CUVID is enabled the pluginname is softhdcuvid
|
||||
# if DRM is enabled the pluginname is softhddrm
|
||||
@@ -19,12 +19,12 @@ VAAPI ?= 0
|
||||
CUVID ?= 0
|
||||
|
||||
# if you enable DRM then the plugin will only run without X server
|
||||
# only valid for VAAPI
|
||||
# only valid for VAAPI
|
||||
# does not work with libplacebo
|
||||
DRM ?= 0
|
||||
|
||||
|
||||
# use libplacebo - available for both decoders but not for DRM
|
||||
# use libplacebo - available for both decoders but not for DRM
|
||||
LIBPLACEBO ?= 1
|
||||
|
||||
# use YADIF deint - only available with cuvid
|
||||
@@ -124,7 +124,7 @@ TMPDIR ?= /tmp
|
||||
|
||||
### The compiler options:
|
||||
|
||||
export CFLAGS = $(call PKGCFG,cflags)
|
||||
export CFLAGS = $(call PKGCFG,cflags)
|
||||
export CXXFLAGS = $(call PKGCFG,cxxflags)
|
||||
|
||||
ifeq ($(CFLAGS),)
|
||||
@@ -146,10 +146,10 @@ APIVERSION = $(call PKGCFG,apiversion)
|
||||
|
||||
### Parse config
|
||||
ifeq ($(VAAPI),1)
|
||||
CONFIG += -DVAAPI
|
||||
CONFIG += -DVAAPI
|
||||
#LIBPLACEBO=1
|
||||
PLUGIN = softhdvaapi
|
||||
LIBS += -lEGL
|
||||
LIBS += -lEGL
|
||||
endif
|
||||
|
||||
|
||||
@@ -159,13 +159,13 @@ CONFIG += -DUSE_DRM -DVAAPI
|
||||
LIBPLACEBO=0
|
||||
_CFLAGS += $(shell pkg-config --cflags libdrm)
|
||||
LIBS += -lgbm -ldrm
|
||||
LIBS += -lEGL
|
||||
LIBS += -lEGL
|
||||
endif
|
||||
|
||||
ifeq ($(CUVID),1)
|
||||
CONFIG += -DUSE_PIP # PIP support
|
||||
CONFIG += -DCUVID # enable CUVID decoder
|
||||
LIBS += -lEGL -lGL
|
||||
LIBS += -lEGL -lGL
|
||||
ifeq ($(YADIF),1)
|
||||
CONFIG += -DYADIF # Yadif only with CUVID
|
||||
endif
|
||||
@@ -213,7 +213,7 @@ SOFILE = libvdr-$(PLUGIN).so
|
||||
|
||||
|
||||
#
|
||||
# Test that libswresample is available
|
||||
# Test that libswresample is available
|
||||
#
|
||||
#ifneq (exists, $(shell pkg-config libswresample && echo exists))
|
||||
# $(warning ******************************************************************)
|
||||
@@ -222,7 +222,7 @@ SOFILE = libvdr-$(PLUGIN).so
|
||||
#endif
|
||||
|
||||
#
|
||||
# Test and set config for libavutil
|
||||
# Test and set config for libavutil
|
||||
#
|
||||
ifneq (exists, $(shell pkg-config libavutil && echo exists))
|
||||
$(warning ******************************************************************)
|
||||
@@ -233,7 +233,7 @@ _CFLAGS += $(shell pkg-config --cflags libavutil)
|
||||
LIBS += $(shell pkg-config --libs libavutil)
|
||||
|
||||
#
|
||||
# Test and set config for libswscale
|
||||
# Test and set config for libswscale
|
||||
#
|
||||
ifneq (exists, $(shell pkg-config libswscale && echo exists))
|
||||
$(warning ******************************************************************)
|
||||
@@ -281,14 +281,14 @@ _CFLAGS += -I./opengl -I./
|
||||
LIBS += -L/usr/lib64
|
||||
|
||||
ifeq ($(LIBPLACEBO),1)
|
||||
LIBS += -lplacebo
|
||||
LIBS += -lplacebo
|
||||
endif
|
||||
|
||||
ifeq ($(CUVID),1)
|
||||
LIBS += -lcuda -lnvcuvid
|
||||
LIBS += -lcuda -lnvcuvid
|
||||
endif
|
||||
|
||||
LIBS += -lGLEW -lGLU -ldl -lglut
|
||||
LIBS += -lGLEW -lGLU -ldl -lglut
|
||||
### Includes and Defines (add further entries here):
|
||||
|
||||
INCLUDES +=
|
||||
@@ -299,16 +299,16 @@ DEFINES += -DPLUGIN_NAME_I18N='"$(PLUGIN)"' -D_GNU_SOURCE $(CONFIG) \
|
||||
### Make it standard
|
||||
|
||||
override CXXFLAGS += $(_CFLAGS) $(DEFINES) $(INCLUDES) \
|
||||
-g -W -Wextra -Winit-self -Werror=overloaded-virtual -Wno-unused-parameter
|
||||
-g -W -Wextra -Winit-self -Werror=overloaded-virtual -Wno-unused-parameter
|
||||
override CFLAGS += $(_CFLAGS) $(DEFINES) $(INCLUDES) \
|
||||
-g -W -Wextra -Winit-self -Wdeclaration-after-statement
|
||||
|
||||
|
||||
### The object files (add further files here):
|
||||
|
||||
OBJS = softhdcuvid.o softhddev.o video.o audio.o codec.o ringbuffer.o
|
||||
OBJS = softhdcuvid.o softhddev.o video.o audio.o codec.o ringbuffer.o
|
||||
ifeq ($(OPENGLOSD),1)
|
||||
OBJS += openglosd.o
|
||||
OBJS += openglosd.o
|
||||
endif
|
||||
|
||||
SRCS = $(wildcard $(OBJS:.o=.c)) *.cpp
|
||||
@@ -385,9 +385,7 @@ HDRS= $(wildcard *.h)
|
||||
|
||||
indent:
|
||||
for i in $(SRCS) $(HDRS); do \
|
||||
indent $$i; \
|
||||
unexpand -a $$i | sed -e s/constconst/const/ > $$i.up; \
|
||||
mv $$i.up $$i; \
|
||||
VERSION_CONTROL=none indent $$i; \
|
||||
done
|
||||
|
||||
video_test: video.c Makefile
|
||||
|
||||
Reference in New Issue
Block a user