1
0
mirror of https://git.FreeBSD.org/ports.git synced 2024-11-21 00:25:50 +00:00

Add new port multimedia/naludump:

Naludump is a tool to delete NALU fill data from h.264 streams embedded into
TS files. The overall file structure isn't modified, only complete TS packets
of NALU fill data are removed.

Naludump contains lots of code of Klaus Schmidinger's VDR, and is based on
cocepts from Marten Richter's Nalustripper.

Usage:
naludump inputfile.ts [outputfile.ts]

WWW: http://www.udo-richter.de/vdr/naludump.en.html
This commit is contained in:
Juergen Lock 2014-04-19 23:11:35 +00:00
parent 4648604d7f
commit 658ec3c2ed
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=351609
8 changed files with 104 additions and 0 deletions

View File

@ -241,6 +241,7 @@
SUBDIR += mxflib
SUBDIR += mythtv
SUBDIR += mythtv-frontend
SUBDIR += naludump
SUBDIR += nxtvepg
SUBDIR += oggvideotools
SUBDIR += ogmrip

View File

@ -0,0 +1,26 @@
# Created by: Juergen Lock <nox@FreeBSD.org>
# $FreeBSD$
PORTNAME= naludump
PORTVERSION= 0.1.1
CATEGORIES= multimedia
MASTER_SITES= http://www.udo-richter.de/vdr/files/
MAINTAINER= nox@FreeBSD.org
COMMENT= Delete NALU fill data from h.264 TS files
LICENSE= GPLv2
USES= gmake iconv:wchar_t tar:tgz
PATCH_STRIP= -p1
CFLAGS+= "-I${LOCALBASE}/include"
CFLAGS+= "-L${LOCALBASE}/lib"
CFLAGS+= ${ICONV_LIB}
MAKE_ARGS+= CC="${CC}" CXX="${CXX}"
MAKE_ARGS+= CFLAGS="${CFLAGS}" CXXFLAGS="${CXXFLAGS}"
PLIST_FILES+= bin/${PORTNAME}
do-install:
${INSTALL_PROGRAM} ${WRKSRC}/${PORTNAME} ${STAGEDIR}${PREFIX}/bin
.include <bsd.port.mk>

View File

@ -0,0 +1,2 @@
SHA256 (naludump-0.1.1.tgz) = b6bd1899b4e4aad8f850b6892b06f9b639e576a5801d2fa63a6a593a022fd2ca
SIZE (naludump-0.1.1.tgz) = 50459

View File

@ -0,0 +1,11 @@
--- a/Makefile
+++ b/Makefile
@@ -8,6 +8,8 @@ OBJS = naludump.o remux.o tools.o libsi/
DEFINES += -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE
+DEFINES += -DO_LARGEFILE=0
+
all: naludump
# Implicit rules:

View File

@ -0,0 +1,14 @@
--- a/libsi/headers.h
+++ b/libsi/headers.h
@@ -17,7 +17,11 @@
#ifndef LIBSI_HEADERS_H
#define LIBSI_HEADERS_H
+#ifdef __FreeBSD__
+#include <sys/endian.h>
+#else
#include <endian.h>
+#endif
namespace SI {

View File

@ -0,0 +1,24 @@
--- a/libsi/si.c
+++ b/libsi/si.c
@@ -13,7 +13,9 @@
#include "si.h"
#include <errno.h>
#include <iconv.h>
+#ifndef __FreeBSD__
#include <malloc.h>
+#endif
#include <stdlib.h> // for broadcaster stupidity workaround
#include <string.h>
#include "descriptor.h"
@@ -381,7 +383,11 @@ bool convertCharacterTable(const char *f
if (SystemCharacterTable) {
iconv_t cd = iconv_open(SystemCharacterTable, fromCode);
if (cd != (iconv_t)-1) {
+#ifdef __FreeBSD__
+ const char *fromPtr = from;
+#else
char *fromPtr = (char *)from;
+#endif
while (fromLength > 0 && toLength > 1) {
if (iconv(cd, &fromPtr, &fromLength, &to, &toLength) == size_t(-1)) {
if (errno == EILSEQ) {

View File

@ -0,0 +1,15 @@
--- a/tools.c
+++ b/tools.c
@@ -14,7 +14,12 @@
#include <stdarg.h>
#include <stdlib.h>
#include <sys/time.h>
+#ifdef __FreeBSD__
+#include <sys/param.h>
+#include <sys/mount.h>
+#else
#include <sys/vfs.h>
+#endif
#include <time.h>
#include <unistd.h>
#include <utime.h>

View File

@ -0,0 +1,11 @@
Naludump is a tool to delete NALU fill data from h.264 streams embedded into
TS files. The overall file structure isn't modified, only complete TS packets
of NALU fill data are removed.
Naludump contains lots of code of Klaus Schmidinger's VDR, and is based on
cocepts from Marten Richter's Nalustripper.
Usage:
naludump inputfile.ts [outputfile.ts]
WWW: http://www.udo-richter.de/vdr/naludump.en.html