1
0
mirror of https://git.FreeBSD.org/ports.git synced 2025-01-08 06:48:28 +00:00

audio/kid3-*: Update to 3.7.0

- Clean up Makefile after removal of kde4 and qt4 variants
- Remove PHONON option which was only for the qt4 variant
- Further simplify substitutions in pkg-plist
This commit is contained in:
Jason E. Hale 2019-02-14 13:03:23 +00:00
parent 0841e1c43a
commit 578f6d04c3
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=492916
8 changed files with 116 additions and 118 deletions

View File

@ -1,8 +1,8 @@
# $FreeBSD$
PORTNAME= kid3
PORTVERSION= 3.6.2
PORTREVISION?= 3
PORTVERSION= 3.7.0
PORTREVISION?= 0
CATEGORIES= audio kde
MASTER_SITES= SF
PKGNAMESUFFIX= -${SLAVE}
@ -15,9 +15,11 @@ LICENSE_FILE= ${WRKSRC}/LICENSE
BUILD_DEPENDS= ${LOCALBASE}/share/xsl/docbook/html/docbook.xsl:textproc/docbook-xsl
USES= cmake gnome pkgconfig
USES= cmake compiler:c++11-lang desktop-file-utils gnome pkgconfig qt:5
USE_GNOME= libxslt:build
USE_LDCONFIG= yes
USE_QT= core dbus gui multimedia network xml widgets \
buildtools_build linguisttools_build qmake_build
CMAKE_ARGS= -DWITH_DOCBOOKDIR="${LOCALBASE}/share/xsl/docbook" \
-DWITH_LIBDIR=lib \
@ -31,28 +33,15 @@ PLIST_SUB+= SHLIB_VER=${PORTVERSION}
SLAVE?= qt5
.if ${SLAVE} == qt5
# Qt5
USES+= desktop-file-utils
PLIST_SUB+= KDE="@comment " KF5="@comment " QT="" QT_SUFX="-qt"
PLIST_SUB+= KF5="@comment " QT="" QT_SUFX="-qt"
KID3_APPS+= QT
.else
# KF5
PLIST_SUB+= KDE="" QT="@comment " QT_SUFX=""
KID3_APPS+= KDE
.endif
# KF5 and Qt5
USES+= compiler:c++11-lang qt:5
USE_QT+= core dbus gui multimedia network xml widgets \
buildtools_build linguisttools_build qmake_build
CMAKE_ON+= WITH_QT5
OPTIONS_EXCLUDE+= PHONON
.if ${SLAVE} == kf5
# KF5 only
USES+= desktop-file-utils kde:5
USES+= kde:5
USE_KDE+= auth codecs config configwidgets coreaddons \
widgetsaddons xmlgui doctools_build ecm_build
PLIST_SUB+= KDE4="@comment " KF5=""
PLIST_SUB+= KF5="" QT="@comment " QT_SUFX=""
KID3_APPS+= KDE
.endif
.for s in kf5 qt5
@ -61,7 +50,7 @@ CONFLICTS_INSTALL+= kid3-${s}
. endif
.endfor
OPTIONS_DEFINE= CLI ACOUSTID FLAC MP3 MP4 VORBIS TAGLIB PHONON TEST
OPTIONS_DEFINE= CLI ACOUSTID FLAC MP3 MP4 VORBIS TAGLIB TEST
OPTIONS_DEFAULT= CLI ACOUSTID FLAC MP3 MP4 VORBIS TAGLIB
OPTIONS_SUB= yes
NO_OPTIONS_SORT= yes
@ -71,7 +60,7 @@ ACOUSTID_LIB_DEPENDS= libchromaprint.so:audio/chromaprint \
ACOUSTID_CMAKE_BOOL= WITH_CHROMAPRINT WITH_FFMPEG
CLI_DESC= Build and install command line utility
CLI_USES= python:3.4+,test readline
CLI_USES= python:3.5+,test readline
CLI_VARS= KID3_APPS+=CLI
FLAC_LIB_DEPENDS= libFLAC.so:audio/flac
@ -83,9 +72,6 @@ MP3_CMAKE_BOOL= WITH_ID3LIB
MP4_LIB_DEPENDS= libmp4v2.so:multimedia/mp4v2
MP4_CMAKE_BOOL= WITH_MP4V2
PHONON_USE= QT=phonon
PHONON_CMAKE_BOOL= WITH_PHONON
TAGLIB_DESC= Various audio formats support via Taglib
TAGLIB_LIB_DEPENDS= libtag.so:audio/taglib
TAGLIB_CMAKE_BOOL= WITH_TAGLIB

View File

@ -1,3 +1,3 @@
TIMESTAMP = 1535209745
SHA256 (kid3-3.6.2.tar.gz) = df03d98a2bfd08b7baea6c1006b89bac8ce4c07e8d91d6194a2f05895d1ad8a7
SIZE (kid3-3.6.2.tar.gz) = 1430880
TIMESTAMP = 1550130652
SHA256 (kid3-3.7.0.tar.gz) = 1d7459b4b517b096eae016b3d3f5c4b2bf56fbfa92f59503baeed109139e44ae
SIZE (kid3-3.7.0.tar.gz) = 1466849

View File

@ -1,30 +1,27 @@
Qt5Test is only needed for running the regression tests.
--- CMakeLists.txt.orig 2018-04-25 11:23:10 UTC
--- CMakeLists.txt.orig 2018-12-21 05:40:14 UTC
+++ CMakeLists.txt
@@ -258,7 +258,9 @@ if (NOT WITH_QT4 AND NOT Qt4_FOUND AND NOT QT4_FOUND)
set(Qt5Xml_DIR "${_qt5Dir}/lib/cmake/Qt5Xml")
set(Qt5Multimedia_DIR "${_qt5Dir}/lib/cmake/Qt5Multimedia")
set(Qt5LinguistTools_DIR "${_qt5Dir}/lib/cmake/Qt5LinguistTools")
- set(Qt5Test_DIR "${_qt5Dir}/lib/cmake/Qt5Test")
+ if (BUILD_TEST_APP)
+ set(Qt5Test_DIR "${_qt5Dir}/lib/cmake/Qt5Test")
+ endif (BUILD_TEST_APP)
if (WITH_DBUS)
set(Qt5DBus_DIR "${_qt5Dir}/lib/cmake/Qt5DBus")
endif (WITH_DBUS)
@@ -299,9 +301,11 @@ if (NOT WITH_QT4 AND NOT Qt4_FOUND AND NOT QT4_FOUND)
endif (Qt5${_qt5Component}_FOUND)
endforeach ()
find_package(Qt5LinguistTools)
- find_package(Qt5Test)
- set(QT_QTTEST_LIBRARY Qt5::Test)
- set(QT_QTTEST_INCLUDE_DIR ${Qt5Test_INCLUDE_DIRS})
@@ -223,7 +223,9 @@ if(_qt5Dir)
set(Qt5Xml_DIR "${_qt5Dir}/lib/cmake/Qt5Xml")
set(Qt5Multimedia_DIR "${_qt5Dir}/lib/cmake/Qt5Multimedia")
set(Qt5LinguistTools_DIR "${_qt5Dir}/lib/cmake/Qt5LinguistTools")
- set(Qt5Test_DIR "${_qt5Dir}/lib/cmake/Qt5Test")
+ if (BUILD_TEST_APP)
+ find_package(Qt5Test)
+ set(QT_QTTEST_LIBRARY Qt5::Test)
+ set(QT_QTTEST_INCLUDE_DIR ${Qt5Test_INCLUDE_DIRS})
+ endif (BUILD_TEST_APP)
if (Qt5DBus_FOUND)
set(HAVE_QTDBUS 1)
endif (Qt5DBus_FOUND)
+ set(Qt5Test_DIR "${_qt5Dir}/lib/cmake/Qt5Test")
+ endif()
if(WITH_DBUS)
set(Qt5DBus_DIR "${_qt5Dir}/lib/cmake/Qt5DBus")
endif()
@@ -240,7 +242,10 @@ else()
find_package(Qt5Core)
endif()
if(Qt5Core_FOUND)
- set(_qtComponents Core Gui Widgets Network Xml Multimedia LinguistTools Test)
+ set(_qtComponents Core Gui Widgets Network Xml Multimedia LinguistTools)
+ if(BUILD_TEST_APP)
+ set(_qtComponents ${_qtComponents} Test)
+ endif()
if(WITH_DBUS)
set(_qtComponents ${_qtComponents} DBus)
endif()

View File

@ -1,45 +1,43 @@
Squash startup warnings for KF5 app.
Shortcut for action "open_directory" "O&pen Directory..." set with QAction::setShortcut()! Use KActionCollection::setDefaultShortcut(s) instead.
Shortcut for action "reload" "Re&load" set with QAction::setShortcut()! Use KActionCollection::setDefaultShortcut(s) instead.
Shortcut for action "filelist_rename" "&Rename" set with QAction::setShortcut()! Use KActionCollection::setDefaultShortcut(s) instead.
Shortcut for action "filelist_delete" "&Move to Trash" set with QAction::setShortcut()! Use KActionCollection::setDefaultShortcut(s) instead.
--- src/app/kde/kdemainwindow.cpp.orig 2018-03-18 20:56:24 UTC
--- src/app/kde/kdemainwindow.cpp.orig 2018-12-21 05:40:14 UTC
+++ src/app/kde/kdemainwindow.cpp
@@ -162,7 +162,12 @@ void KdeMainWindow::initActions()
action = new KAction(KIcon(QLatin1String("document-open")),
@@ -180,7 +180,7 @@ void KdeMainWindow::initActions()
action = new QAction(QIcon::fromTheme(QLatin1String("document-open")),
tr("O&pen Directory..."), this);
action->setStatusTip(tr("Opens a directory"));
+#if QT_VERSION >= 0x050000
+ collection->setDefaultShortcut(action,
+ QKeySequence(Qt::CTRL + Qt::Key_D));
+#else
action->setShortcut(KShortcut(QLatin1String("Ctrl+D")));
+#endif
- action->setShortcut(QKeySequence(QLatin1String("Ctrl+D")));
+ collection->setDefaultShortcut(action, QKeySequence(Qt::CTRL + Qt::Key_D));
collection->addAction(QLatin1String("open_directory"), action);
connect(action, SIGNAL(triggered()), impl(), SLOT(slotFileOpenDirectory()));
action = new KAction(KIcon(QLatin1String("document-import")),
@@ -359,13 +364,23 @@ void KdeMainWindow::initActions()
connect(action, &QAction::triggered,
impl(), &BaseMainWindowImpl::slotFileOpenDirectory);
@@ -188,7 +188,7 @@ void KdeMainWindow::initActions()
action = new QAction(QIcon::fromTheme(QLatin1String("view-refresh")),
tr("Re&load"), this);
action->setStatusTip(tr("Reload directory"));
- action->setShortcut(QKeySequence::Refresh);
+ collection->setDefaultShortcut(action, QKeySequence::Refresh);
collection->addAction(QLatin1String("reload"), action);
connect(action, &QAction::triggered,
impl(), &BaseMainWindowImpl::slotFileReload);
@@ -401,13 +401,13 @@ void KdeMainWindow::initActions()
collection->addAction(QLatin1String("filelist_focus"), action);
connect(action, SIGNAL(triggered()), form(), SLOT(setFocusFileList()));
action = new KAction(tr("&Rename"), this);
+#if QT_VERSION >= 0x050000
+ collection->setDefaultShortcut(action,
+ QKeySequence(Qt::Key_F2));
+#else
action->setShortcut(QKeySequence(Qt::Key_F2));
+#endif
connect(action, &QAction::triggered, form(), &Kid3Form::setFocusFileList);
action = new QAction(tr("&Rename"), this);
- action->setShortcut(QKeySequence(Qt::Key_F2));
+ collection->setDefaultShortcut(action, QKeySequence(Qt::Key_F2));
action->setShortcutContext(Qt::WidgetShortcut);
connect(action, SIGNAL(triggered()), impl(), SLOT(renameFile()));
connect(action, &QAction::triggered, impl(), &BaseMainWindowImpl::renameFile);
collection->addAction(QLatin1String("filelist_rename"), action);
form()->getFileList()->setRenameAction(action);
action = new KAction(tr("&Move to Trash"), this);
+#if QT_VERSION >= 0x050000
+ collection->setDefaultShortcut(action,
+ QKeySequence::Delete);
+#else
action->setShortcut(QKeySequence::Delete);
+#endif
action = new QAction(tr("&Move to Trash"), this);
- action->setShortcut(QKeySequence::Delete);
+ collection->setDefaultShortcut(action, QKeySequence::Delete);
action->setShortcutContext(Qt::WidgetShortcut);
connect(action, SIGNAL(triggered()), impl(), SLOT(deleteFile()));
connect(action, &QAction::triggered, impl(), &BaseMainWindowImpl::deleteFile);
collection->addAction(QLatin1String("filelist_delete"), action);

View File

@ -1,15 +1,13 @@
Fix import of track duration from Discogs.
Fix import of album title from Discogs. (fixed upstream: b3bd70)
--- src/plugins/discogsimport/discogsimporter.cpp.orig 2018-04-18 18:01:00 UTC
--- src/plugins/discogsimport/discogsimporter.cpp.orig 2018-12-21 05:40:14 UTC
+++ src/plugins/discogsimport/discogsimporter.cpp
@@ -526,8 +526,8 @@ void DiscogsImporter::parseAlbumResults(const QByteArr
QRegExp titleRe(QLatin1String(
"class=\"tracklist_track_title\"[^>]*>([^<]+)<"));
QRegExp durationRe(QLatin1String(
- "<td [^>]*class=\"tracklist_track_duration\"[^>]*>(?:<meta[^>]*>)?"
- "(?:<span>)?(\\d+):(\\d+)</"));
+ "<td [^>]*class=\"tracklist_track_duration\">"
+ "(?:<meta[^>]*>)(?:\\s+<span>)(\\d+):(\\d+)</"));
QRegExp indexRe(QLatin1String("<td class=\"track_index\">([^<]+)$"));
QRegExp rowEndRe(QLatin1String("</td>[\\s\\r\\n]*</tr>"));
ImportTrackDataVector::iterator it = trackDataVector.begin();
@@ -265,7 +265,7 @@ void DiscogsImporter::parseFindResults(const QByteArra
void DiscogsImporter::parseAlbumResults(const QByteArray& albumStr)
{
QRegExp nlSpaceRe(QLatin1String("[\r\n]+\\s*"));
- QRegExp atDiscogsRe(QLatin1String("\\s*\\([^)]+\\) at Discogs\n?$"));
+ QRegExp atDiscogsRe(QLatin1String("\\s*\\([^)]+\\) (?:at|\\|) Discogs\n?$"));
QString str = QString::fromUtf8(albumStr);
FrameCollection framesHdr;

View File

@ -0,0 +1,14 @@
The QDateTime object used to create the test value contains milliseconds, so
the test fails because the returned value did not match the expected value.
--- src/test/testjsonparser.cpp.orig 2018-12-21 05:40:14 UTC
+++ src/test/testjsonparser.cpp
@@ -103,7 +103,7 @@ void TestJsonParser::serializeAndDeserializeTypes()
QString str = JsonParser::serialize(map);
QCOMPARE(str, QString(QLatin1String(
- "{\"val00\": \"2011-08-18T14:02:07\", \"val01\": -7654321, "
+ "{\"val00\": \"2011-08-18T14:02:07.000\", \"val01\": -7654321, "
"\"val02\": 1234567890123456789, "
"\"val03\": false, \"val04\": true, \"val05\": null, \"val06\": "
"\"String with \\\"'\\\\{}[]\", \"val07\": 3.141592653, "

View File

@ -1,6 +1,6 @@
Fix test to reflect the current data in the MusicBrainz database.
--- src/test/testmusicbrainzreleaseimporter.cpp.orig 2018-04-18 18:01:00 UTC
--- src/test/testmusicbrainzreleaseimporter.cpp.orig 2018-12-21 05:40:14 UTC
+++ src/test/testmusicbrainzreleaseimporter.cpp
@@ -38,7 +38,7 @@ void TestMusicBrainzReleaseImporter::testQueryAlbums()
{
@ -8,21 +8,27 @@ Fix test to reflect the current data in the MusicBrainz database.
QStandardItemModel* albumModel = m_importer->getAlbumListModel();
- QCOMPARE(albumModel->rowCount(), 3);
+ QCOMPARE(albumModel->rowCount(), 4);
AlbumListItem* item = static_cast<AlbumListItem*>(albumModel->item(0, 0));
auto item = static_cast<AlbumListItem*>(albumModel->item(0, 0));
QVERIFY(item);
QVERIFY(item->type() == AlbumListItem::Type);
@@ -53,12 +53,12 @@ void TestMusicBrainzReleaseImporter::testQueryTracks()
@@ -54,9 +54,9 @@ void TestMusicBrainzReleaseImporter::testQueryTracks()
QStringList titles;
titles << QLatin1String("The Prophecy") << QLatin1String("Betrayer") << QLatin1String("Dead Hope") << QLatin1String("Dark God")
- << QLatin1String("Loki's Punishment") << QLatin1String("Beginning of the End") << QLatin1String("Thor's Hammer")
+ << QString::fromUtf8("Loki\u2019s Punishment") << QLatin1String("Beginning of the End") << QString::fromUtf8("Thor\u2019s Hammer")
<< QLatin1String("Hall of Odin") << QLatin1String("The Powergod") << QLatin1String("March of the Einheriers")
titles << QLatin1String("The Prophecy") << QLatin1String("Betrayer")
<< QLatin1String("Dead Hope") << QLatin1String("Dark God")
- << QLatin1String("Loki's Punishment")
+ << QString::fromUtf8("Loki\u2019s Punishment")
<< QLatin1String("Beginning of the End")
- << QLatin1String("Thor's Hammer")
+ << QString::fromUtf8("Thor\u2019s Hammer")
<< QLatin1String("Hall of Odin") << QLatin1String("The Powergod")
<< QLatin1String("March of the Einheriers")
<< QLatin1String("End of All");
QStringList lengths;
lengths << QLatin1String("5:19") << QLatin1String("4:53") << QLatin1String("6:02") << QLatin1String("5:42") << QLatin1String("5:08") << QLatin1String("4:01") << QLatin1String("5:01")
- << QLatin1String("5:06") << QLatin1String("5:21") << QLatin1String("5:40") << QLatin1String("3:53");
+ << QLatin1String("5:06") << QLatin1String("5:21") << QLatin1String("5:40") << QLatin1String("3:55");
@@ -66,7 +66,7 @@ void TestMusicBrainzReleaseImporter::testQueryTracks()
<< QLatin1String("5:08") << QLatin1String("4:01")
<< QLatin1String("5:01") << QLatin1String("5:06")
<< QLatin1String("5:21") << QLatin1String("5:40")
- << QLatin1String("3:53");
+ << QLatin1String("3:55");
QCOMPARE(m_trackDataModel->rowCount(), 11);
for (int row = 0; row < 11; ++row) {
QCOMPARE(m_trackDataModel->index(row, 0).data().toString(), lengths.at(row));
QCOMPARE(m_trackDataModel->index(row, 0).data().toString(),

View File

@ -19,13 +19,12 @@ man/de/man1/kid3.1.gz
%%CLI%%man/man1/kid3-cli.1.gz
%%QT%%man/man1/kid3-qt.1.gz
man/man1/kid3.1.gz
%%KF5%%share/applications/net.sourceforge.kid3.desktop
%%QT%%share/applications/kid3-qt.desktop
%%KDE%%share/dbus-1/interfaces/net.sourceforge.Kid3.xml
%%KDE%%share/doc/HTML/de/kid3/index.cache.bz2
%%KDE%%share/doc/HTML/de/kid3/index.docbook
%%KDE%%share/doc/HTML/en/kid3/index.cache.bz2
%%KDE%%share/doc/HTML/en/kid3/index.docbook
share/applications/net.sourceforge.kid3%%QT_SUFX%%.desktop
%%KF5%%share/dbus-1/interfaces/net.sourceforge.Kid3.xml
%%KF5%%share/doc/HTML/de/kid3/index.cache.bz2
%%KF5%%share/doc/HTML/de/kid3/index.docbook
%%KF5%%share/doc/HTML/en/kid3/index.cache.bz2
%%KF5%%share/doc/HTML/en/kid3/index.docbook
%%QT%%share/doc/kid3-qt/kid3_de.html
%%QT%%share/doc/kid3-qt/kid3_en.html
share/icons/hicolor/128x128/apps/kid3%%QT_SUFX%%.png
@ -34,7 +33,7 @@ share/icons/hicolor/32x32/apps/kid3%%QT_SUFX%%.png
share/icons/hicolor/48x48/apps/kid3%%QT_SUFX%%.png
share/icons/hicolor/64x64/apps/kid3%%QT_SUFX%%.png
%%QT%%share/icons/hicolor/scalable/apps/kid3-qt.svg
%%KDE%%share/icons/hicolor/scalable/apps/kid3.svgz
%%KF5%%share/icons/hicolor/scalable/apps/kid3.svgz
%%KF5%%share/kxmlgui5/kid3/kid3ui.rc
%%DATADIR%%/translations/kid3_cs.qm
%%DATADIR%%/translations/kid3_da.qm
@ -54,4 +53,4 @@ share/icons/hicolor/64x64/apps/kid3%%QT_SUFX%%.png
%%DATADIR%%/translations/kid3_tr.qm
%%DATADIR%%/translations/kid3_zh_CN.qm
%%DATADIR%%/translations/kid3_zh_TW.qm
share/metainfo/kid3%%QT_SUFX%%.appdata.xml
share/metainfo/net.sourceforge.kid3%%QT_SUFX%%.appdata.xml