diff options
author | nox <nox@FreeBSD.org> | 2012-05-12 01:47:31 +0800 |
---|---|---|
committer | nox <nox@FreeBSD.org> | 2012-05-12 01:47:31 +0800 |
commit | 603c8ec3aae946c47028ba51626bc9970e72f903 (patch) | |
tree | 8a1c566c59c3af6427c751e1fb607bee0cd409a0 /multimedia | |
parent | 10083f709f04eddf3259ff4885ab3cfb047d782c (diff) | |
download | freebsd-ports-gnome-603c8ec3aae946c47028ba51626bc9970e72f903.tar.gz freebsd-ports-gnome-603c8ec3aae946c47028ba51626bc9970e72f903.tar.zst freebsd-ports-gnome-603c8ec3aae946c47028ba51626bc9970e72f903.zip |
A software and GPU emulated HD output device plugin for VDR.
Video decoder CPU / VA-API / VDPAU
Video output VA-API / VDPAU
Audio FFMpeg / Alsa / Analog
Audio FFMpeg / Alsa / Digital
Audio FFMpeg / OSS / Analog
HDMI/SPDIF pass-through
YaepgHD support
Software deinterlacer Bob (VA-API only)
Autocrop
Grab image (VDPAU only)
Suspend
Letterbox, Stretch and Center cut-out video display modes
Note: currently doesn't support XV, only VDPAU or (optionally) VAAPI
WWW: http://projects.vdr-developer.org/projects/plg-softhddevice
Diffstat (limited to 'multimedia')
-rw-r--r-- | multimedia/Makefile | 1 | ||||
-rw-r--r-- | multimedia/vdr-plugin-softhddevice/Makefile | 56 | ||||
-rw-r--r-- | multimedia/vdr-plugin-softhddevice/distinfo | 2 | ||||
-rw-r--r-- | multimedia/vdr-plugin-softhddevice/files/patch-Makefile | 79 | ||||
-rw-r--r-- | multimedia/vdr-plugin-softhddevice/files/patch-codec.c | 14 | ||||
-rw-r--r-- | multimedia/vdr-plugin-softhddevice/files/patch-softhddev.c | 49 | ||||
-rw-r--r-- | multimedia/vdr-plugin-softhddevice/files/patch-video.c | 12 | ||||
-rw-r--r-- | multimedia/vdr-plugin-softhddevice/pkg-descr | 18 | ||||
-rw-r--r-- | multimedia/vdr-plugin-softhddevice/pkg-plist | 1 |
9 files changed, 232 insertions, 0 deletions
diff --git a/multimedia/Makefile b/multimedia/Makefile index 732dfa88e6fe..102e930a8631 100644 --- a/multimedia/Makefile +++ b/multimedia/Makefile @@ -345,6 +345,7 @@ SUBDIR += vdr-plugin-skinenigmang SUBDIR += vdr-plugin-sleeptimer SUBDIR += vdr-plugin-softdevice + SUBDIR += vdr-plugin-softhddevice SUBDIR += vdr-plugin-streamdev SUBDIR += vdr-plugin-ttxtsubs SUBDIR += vdr-plugin-upnp diff --git a/multimedia/vdr-plugin-softhddevice/Makefile b/multimedia/vdr-plugin-softhddevice/Makefile new file mode 100644 index 000000000000..f8a2d550c958 --- /dev/null +++ b/multimedia/vdr-plugin-softhddevice/Makefile @@ -0,0 +1,56 @@ +# New ports collection makefile for: vdr-plugin-softhddevie +# Date created: Sun Apr 29 17:00:02 CEST 2012 +# Whom: Juergen Lock <nox@freebsd.org> +# +# $FreeBSD$ +# + +PORTNAME= vdr-plugin-softhddevice +PORTVERSION= 0.5.0 +CATEGORIES= multimedia +MASTER_SITES= http://projects.vdr-developer.org/attachments/download/919/ +DISTNAME= ${PORTNAME:S/-plugin-/-/}-${DISTVERSIONPREFIX}${DISTVERSION}${DISTVERSIONSUFFIX} +EXTRACT_SUFX= .tgz + +MAINTAINER= nox@FreeBSD.org +COMMENT= Video Disk Recorder - softhddevice plugin + +LIB_DEPENDS+= avcodec.1:${PORTSDIR}/multimedia/ffmpeg \ + vdpau.1:${PORTSDIR}/multimedia/libvdpau \ + xcb.2:${PORTSDIR}/x11/libxcb \ + xcb-keysyms.1:${PORTSDIR}/x11/xcb-util-keysyms \ + asound.2:${PORTSDIR}/audio/alsa-lib + +USE_GNOME+= pkgconfig +USE_XORG+= xv x11 xinerama +USE_GL+= gl glu +PATCH_STRIP= -p1 +HAVE_CONFIGURE= yes +PORTDOCS= AGPL-3.0.txt ChangeLog README.txt +CONFIG+= -DLOCALBASE=\\\"${LOCALBASE}\\\" +CONFIG+= -DUSE_VDPAU +CONFIG+= -DUSE_OSS +MAKE_ARGS+= CONFIG="${CONFIG}" +MAKE_JOBS_SAFE= yes +WRKSRC= ${WRKDIR}/${PLUGIN}-${PORTVERSION} + +.include "${.CURDIR}/../vdr/Makefile.plugins" + +OPTIONS= VAAPI "Enable vaapi support (experimental)" off + +.include <bsd.port.options.mk> + +.if defined(WITH_VAAPI) +LIB_DEPENDS+= va.1:${PORTSDIR}/multimedia/libva +CONFIG+= -DUSE_VAAPI +.endif + +post-patch: post-patch-plugin + +post-install: post-install-pluginlocales +.if !defined(NOPORTDOCS) + ${MKDIR} ${DOCSDIR} + (cd ${WRKSRC} && ${INSTALL_DATA} ${PORTDOCS} ${DOCSDIR}) +.endif + +.include <bsd.port.mk> diff --git a/multimedia/vdr-plugin-softhddevice/distinfo b/multimedia/vdr-plugin-softhddevice/distinfo new file mode 100644 index 000000000000..76cd95638201 --- /dev/null +++ b/multimedia/vdr-plugin-softhddevice/distinfo @@ -0,0 +1,2 @@ +SHA256 (vdr/vdr-softhddevice-0.5.0.tgz) = e2fac582ac22a628f360f90657579367c88f2c4af78df9b6ce0739928cdb3f97 +SIZE (vdr/vdr-softhddevice-0.5.0.tgz) = 142044 diff --git a/multimedia/vdr-plugin-softhddevice/files/patch-Makefile b/multimedia/vdr-plugin-softhddevice/files/patch-Makefile new file mode 100644 index 000000000000..ac5b0ca2cac1 --- /dev/null +++ b/multimedia/vdr-plugin-softhddevice/files/patch-Makefile @@ -0,0 +1,79 @@ +--- a/Makefile ++++ b/Makefile +@@ -41,8 +41,8 @@ CXXFLAGS ?= -g -O2 -W -Wall -Wextra -Wer + + ### The directory environment: + +-VDRDIR ?= ../../.. +-LIBDIR ?= ../../lib ++VDRDIR = /usr/local/include/vdr ++LIBDIR = ../lib + TMPDIR ?= /tmp + + ### Make sure that necessary options are included: +@@ -72,7 +72,7 @@ DEFINES += $(CONFIG) -D_GNU_SOURCE -DPLU + _CFLAGS = $(DEFINES) $(INCLUDES) \ + $(shell pkg-config --cflags libavcodec) \ + `pkg-config --cflags x11 x11-xcb xcb xcb-xv xcb-shm xcb-dpms xcb-atom\ +- xcb-screensaver xcb-randr xcb-glx xcb-icccm xcb-keysyms`\ ++ xcb-screensaver xcb-randr xcb-glx xcb-keysyms`\ + `pkg-config --cflags gl glu` \ + $(if $(findstring USE_VDPAU,$(CONFIG)), \ + `pkg-config --cflags vdpau`) \ +@@ -88,7 +88,7 @@ override CFLAGS += $(_CFLAGS) + LIBS += -lrt \ + $(shell pkg-config --libs libavcodec) \ + `pkg-config --libs x11 x11-xcb xcb xcb-xv xcb-shm xcb-dpms xcb-atom\ +- xcb-screensaver xcb-randr xcb-glx xcb-icccm xcb-keysyms`\ ++ xcb-screensaver xcb-randr xcb-glx xcb-keysyms`\ + `pkg-config --libs gl glu` \ + $(if $(findstring USE_VDPAU,$(CONFIG)), \ + `pkg-config --libs vdpau`) \ +@@ -113,7 +113,7 @@ all: libvdr-$(PLUGIN).so i18n + + ### Dependencies: + +-MAKEDEP = $(CC) -MM -MG ++MAKEDEP = $(CC) -MM # # # -MG + DEPFILE = .dependencies + $(DEPFILE): Makefile + @$(MAKEDEP) $(DEFINES) $(INCLUDES) $(SRCS) >$@ +@@ -125,7 +125,7 @@ $(OBJS): Makefile + ### Internationalization (I18N): + + PODIR = po +-LOCALEDIR = $(VDRDIR)/locale ++LOCALEDIR = ../locale + I18Npo = $(wildcard $(PODIR)/*.po) + I18Nmsgs = $(addprefix $(LOCALEDIR)/, $(addsuffix /LC_MESSAGES/vdr-$(PLUGIN).mo, $(notdir $(foreach file, $(I18Npo), $(basename $(file)))))) + I18Npot = $(PODIR)/$(PLUGIN).pot +@@ -153,7 +153,11 @@ i18n: $(I18Nmsgs) $(I18Npot) + + libvdr-$(PLUGIN).so: $(OBJS) Makefile + $(CXX) $(CXXFLAGS) $(LDFLAGS) -shared -fPIC $(OBJS) -o $@ $(LIBS) ++ifdef FREEBSD ++ @cp -f $@ $(LIBDIR)/$@.$(APIVERSION) ++else + @cp --remove-destination $@ $(LIBDIR)/$@.$(APIVERSION) ++endif + + dist: $(I18Npo) clean + @-rm -rf $(TMPDIR)/$(ARCHIVE) +@@ -166,9 +170,17 @@ dist: $(I18Npo) clean + clean: + @-rm -f $(OBJS) $(DEPFILE) *.so *.tgz core* *~ $(PODIR)/*.mo $(PODIR)/*.pot + ++#install: libvdr-$(PLUGIN).so ++# cp --remove-destination libvdr-$(PLUGIN).so \ ++# /usr/lib/vdr/plugins/libvdr-$(PLUGIN).so.$(APIVERSION) ++ + install: libvdr-$(PLUGIN).so ++ifdef FREEBSD ++ ${INSTALL_PROGRAM} libvdr-$(PLUGIN).so $(PREFIX)/lib/vdr/libvdr-$(PLUGIN).so.$(APIVERSION) ++else + cp --remove-destination libvdr-$(PLUGIN).so \ + /usr/lib/vdr/plugins/libvdr-$(PLUGIN).so.$(APIVERSION) ++endif + + HDRS= $(wildcard *.h) + diff --git a/multimedia/vdr-plugin-softhddevice/files/patch-codec.c b/multimedia/vdr-plugin-softhddevice/files/patch-codec.c new file mode 100644 index 000000000000..544ae8e27f41 --- /dev/null +++ b/multimedia/vdr-plugin-softhddevice/files/patch-codec.c @@ -0,0 +1,14 @@ +--- a/codec.c ++++ b/codec.c +@@ -37,7 +37,11 @@ + + #include <stdio.h> + #include <unistd.h> ++#ifdef __FreeBSD__ ++#include <sys/endian.h> ++#else + #include <endian.h> ++#endif + + #include <sys/types.h> + #include <sys/stat.h> diff --git a/multimedia/vdr-plugin-softhddevice/files/patch-softhddev.c b/multimedia/vdr-plugin-softhddevice/files/patch-softhddev.c new file mode 100644 index 000000000000..ac0b02df7709 --- /dev/null +++ b/multimedia/vdr-plugin-softhddevice/files/patch-softhddev.c @@ -0,0 +1,49 @@ +--- a/softhddev.c ++++ b/softhddev.c +@@ -22,6 +22,9 @@ + + #include <sys/types.h> + #include <sys/stat.h> ++#ifdef __FreeBSD__ ++#include <signal.h> ++#endif + #include <fcntl.h> + + #include <stdio.h> +@@ -2212,6 +2215,11 @@ int ProcessArgs(int argc, char *const ar + // + // Parse arguments. + // ++#ifdef __FreeBSD__ ++ if (!strcmp(*argv, "softhddevice")) ++ ++argv, --argc; ++#endif ++ + for (;;) { + switch (getopt(argc, argv, "-a:c:d:fg:p:sv:w:x")) { + case 'a': // audio device for pcm +@@ -2294,7 +2302,11 @@ int ProcessArgs(int argc, char *const ar + + #define XSERVER_MAX_ARGS 512 ///< how many arguments support + ++#ifndef __FreeBSD__ + static const char *X11Server = "/usr/bin/X"; ///< default x11 server ++#else ++static const char *X11Server = LOCALBASE "/bin/X"; ///< default x11 server ++#endif + static const char *X11ServerArguments; ///< default command arguments + static pid_t X11ServerPid; ///< x11 server pid + +@@ -2338,7 +2350,12 @@ static void StartXServer(void) + if ((sval = X11ServerArguments)) { + char *s; + ++#ifndef __FreeBSD__ + s = buf = strdupa(sval); ++#else ++ s = buf = alloca(strlen(sval) + 1); ++ strcpy(buf, sval); ++#endif + while ((sval = strsep(&s, " \t"))) { + args[argn++] = sval; + diff --git a/multimedia/vdr-plugin-softhddevice/files/patch-video.c b/multimedia/vdr-plugin-softhddevice/files/patch-video.c new file mode 100644 index 000000000000..a53d78cb8166 --- /dev/null +++ b/multimedia/vdr-plugin-softhddevice/files/patch-video.c @@ -0,0 +1,12 @@ +--- a/video.c ++++ b/video.c +@@ -101,7 +101,9 @@ + //#include <xcb/xcb_image.h> + //#include <xcb/xcb_event.h> + #include <xcb/xcb_atom.h> ++#if 0 + #include <xcb/xcb_icccm.h> ++#endif + #ifdef XCB_ICCCM_NUM_WM_SIZE_HINTS_ELEMENTS + #include <xcb/xcb_ewmh.h> + #else // compatibility hack for old xcb-util diff --git a/multimedia/vdr-plugin-softhddevice/pkg-descr b/multimedia/vdr-plugin-softhddevice/pkg-descr new file mode 100644 index 000000000000..0187f418b276 --- /dev/null +++ b/multimedia/vdr-plugin-softhddevice/pkg-descr @@ -0,0 +1,18 @@ +A software and GPU emulated HD output device plugin for VDR. + + Video decoder CPU / VA-API / VDPAU + Video output VA-API / VDPAU + Audio FFMpeg / Alsa / Analog + Audio FFMpeg / Alsa / Digital + Audio FFMpeg / OSS / Analog + HDMI/SPDIF pass-through + YaepgHD support + Software deinterlacer Bob (VA-API only) + Autocrop + Grab image (VDPAU only) + Suspend + Letterbox, Stretch and Center cut-out video display modes + +Note: currently doesn't support XV, only VDPAU or (optionally) VAAPI + +WWW: http://projects.vdr-developer.org/projects/plg-softhddevice diff --git a/multimedia/vdr-plugin-softhddevice/pkg-plist b/multimedia/vdr-plugin-softhddevice/pkg-plist new file mode 100644 index 000000000000..7b35d06d1ffc --- /dev/null +++ b/multimedia/vdr-plugin-softhddevice/pkg-plist @@ -0,0 +1 @@ +lib/vdr/libvdr-softhddevice.so.%%APIVERSION%% |