Update to version 0.7.1. That version uses unique_ptr which is not

supported on FreeBSD 9.3, 10.1, and 10.2.  "patch-src_dvbcut.cpp"
restores the code as it was in version 0.7.0.  That patch shall be
removed from the port in 2017, when the affected FreeBSD versions
have reached EoL.

Approved by:    antoine (implicit)
This commit is contained in:
Stefan Eßer 2016-12-01 10:53:22 +00:00
parent 914b4cf012
commit 30de4c11b2
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=427490
10 changed files with 52 additions and 32 deletions

View file

@ -2,7 +2,7 @@
# $FreeBSD$
PORTNAME= dvbcut
PORTVERSION= 0.7.0
PORTVERSION= 0.7.1
CATEGORIES= multimedia
MAINTAINER= se@FreeBSD.org
@ -21,7 +21,7 @@ RUN_DEPENDS:= ${BUILD_DEPENDS}
USE_GITHUB= yes
GH_ACCOUNT= bernhardu
GH_PROJECT= dvbcut-deb
GH_TAGNAME= 381549c
GH_TAGNAME= 040c1ef
USES= qmake:outsource pkgconfig desktop-file-utils shared-mime-info

View file

@ -1,3 +1,3 @@
TIMESTAMP = 1478854634
SHA256 (bernhardu-dvbcut-deb-0.7.0-381549c_GH0.tar.gz) = 176104ec3edb438161e96b21f04057670c23611f938baac510b6e4fc4a976298
SIZE (bernhardu-dvbcut-deb-0.7.0-381549c_GH0.tar.gz) = 183544
TIMESTAMP = 1479555788
SHA256 (bernhardu-dvbcut-deb-0.7.1-040c1ef_GH0.tar.gz) = 9094eb67adc98fc98e7b7292ca5dbe739c171852174406497764494e0bd2c9df
SIZE (bernhardu-dvbcut-deb-0.7.1-040c1ef_GH0.tar.gz) = 186236

View file

@ -1,11 +0,0 @@
--- src/dvbcut.cpp.orig 2016-06-23 12:34:35 UTC
+++ src/dvbcut.cpp
@@ -1232,7 +1232,7 @@ void dvbcut::playPlay()
arguments << "-geometry" << QString().sprintf("%dx%d+0+0",int(ui->imagedisplay->width()),int(ui->imagedisplay->height()));
if (currentaudiotrack>=0 && currentaudiotrack<mpg->getaudiostreams()) {
- arguments << "-aid" << QString().sprintf("0x%x",int(currentaudiotrack));
+ arguments << "-aid" << QString().sprintf("0x%x", int(mpg->mplayeraudioid(currentaudiotrack)));
}
// for now, pass all filenames from the current one up to the last one

View file

@ -1,11 +0,0 @@
--- src/main.cpp.orig 2016-06-23 12:34:35 UTC
+++ src/main.cpp
@@ -52,7 +52,7 @@ static char *argv0;
void
usage_exit(int rv=1) {
fprintf(stderr,
- "Usage ("VERSION_STRING"):\n"
+ "Usage (" VERSION_STRING "):\n"
" %s -generateidx [-idx <idxfilename>] [<mpgfilename> ...]\n"
" %s -batch [ OPTIONS ] <prjfilename> | <mpgfilename> ...\n\n"
"OPTIONS: -cut 4:3|16:9|TS|TS2|<list>, -exp <expfilename>,\n"

View file

@ -1,4 +1,4 @@
--- src/avframe.cpp.orig 2016-06-23 12:34:35 UTC
--- src/avframe.cpp.orig 2016-11-18 13:31:01 UTC
+++ src/avframe.cpp
@@ -52,7 +52,7 @@ avframe::avframe(AVFrame *src, AVCodecCo
tobefreed = (uint8_t *)malloc(avpicture_get_size(ctx->pix_fmt, ctx->width, ctx->height));

View file

@ -1,4 +1,4 @@
--- src/defines.h.orig 2016-06-23 12:34:35 UTC
--- src/defines.h.orig 2016-11-18 13:31:01 UTC
+++ src/defines.h
@@ -42,6 +42,11 @@ static inline int videostream(int s=0)
#endif

View file

@ -0,0 +1,42 @@
--- src/dvbcut.cpp.orig 2016-11-18 13:31:01 UTC
+++ src/dvbcut.cpp
@@ -580,7 +580,7 @@ void dvbcut::fileExport()
}
}
- std::unique_ptr<exportdialog> expd(new exportdialog(QString::fromStdString(expfilen),this));
+ std::auto_ptr<exportdialog> expd(new exportdialog(QString::fromStdString(expfilen),this));
expd->ui->muxercombo->addItem(tr("MPEG program stream/DVD (DVBCUT multiplexer)"));
expd->ui->muxercombo->addItem(tr("MPEG program stream (DVBCUT multiplexer)"));
expd->ui->muxercombo->addItem(tr("MPEG program stream/DVD (libavformat)"));
@@ -725,7 +725,7 @@ void dvbcut::fileExport()
// lavfmuxer mux(fmt,*mpg,outfilename);
- std::unique_ptr<muxer> mux;
+ std::auto_ptr<muxer> mux;
uint32_t audiostreammask(0);
for(int a=0;a<mpg->getaudiostreams();++a)
@@ -737,17 +737,17 @@ void dvbcut::fileExport()
switch(expfmt) {
case 1:
- mux = std::unique_ptr<muxer>(new mpegmuxer(audiostreammask,*mpg,out_file.c_str(),false,0));
+ mux = std::auto_ptr<muxer>(new mpegmuxer(audiostreammask,*mpg,out_file.c_str(),false,0));
break;
case 2:
- mux = std::unique_ptr<muxer>(new lavfmuxer("dvd",audiostreammask,*mpg,out_file.c_str()));
+ mux = std::auto_ptr<muxer>(new lavfmuxer("dvd",audiostreammask,*mpg,out_file.c_str()));
break;
case 3:
- mux = std::unique_ptr<muxer>(new lavfmuxer("mpegts",audiostreammask,*mpg,out_file.c_str()));
+ mux = std::auto_ptr<muxer>(new lavfmuxer("mpegts",audiostreammask,*mpg,out_file.c_str()));
break;
case 0:
default:
- mux = std::unique_ptr<muxer>(new mpegmuxer(audiostreammask,*mpg,out_file.c_str()));
+ mux = std::auto_ptr<muxer>(new mpegmuxer(audiostreammask,*mpg,out_file.c_str()));
break;
}

View file

@ -1,4 +1,4 @@
--- src/dvbcut.h.orig 2016-06-23 12:34:35 UTC
--- src/dvbcut.h.orig 2016-11-18 13:31:01 UTC
+++ src/dvbcut.h
@@ -22,11 +22,14 @@
#define _DVBCUT_DVBCUT_H

View file

@ -1,4 +1,4 @@
--- src/index.h.orig 2016-06-23 12:34:35 UTC
--- src/index.h.orig 2016-11-18 13:31:01 UTC
+++ src/index.h
@@ -22,7 +22,9 @@
#define _DVBCUT_INDEX_H

View file

@ -5,4 +5,4 @@ surgery" approach. Thus, the input video and audio data is mostly kept
unchanged, only very few frames at the beginning and/or end of the selected
range are recoded in order to obtain a valid MPEG file.
WWW: http://github.com/nextghost/dvbcut-qt4
WWW: http://github.com/bernhardu/dvbcut-deb/