From 8d3e7ee2d794452065182fdd77e25fd4a9daff13 Mon Sep 17 00:00:00 2001 From: David Guglielmi Date: Mon, 4 Jun 2018 12:22:32 +0200 Subject: [PATCH] media-sound/mixxx: update pre-2.1.1 patches #7 --- media-sound/mixxx/Manifest | 7 +- ...ash-when-importing-id3v2-apic-frames.patch | 84 + ...log-levels-and-reduce-debug-log-spam.patch | 1003 +++ ...for-all-skins-fix-lp1772202-in-tango.patch | 6336 +++++++++++++++++ ...ix-appstream-config-and-desktop-icon.patch | 125 + ...ew-link-to-updated-2-1-feedback-form.patch | 24 + media-sound/mixxx/mixxx-2.1.0.ebuild | 11 + 7 files changed, 7589 insertions(+), 1 deletion(-) create mode 100644 media-sound/mixxx/files/mixxx-2.1.0-fix-crash-when-importing-id3v2-apic-frames.patch create mode 100644 media-sound/mixxx/files/mixxx-2.1.0-fix-some-log-levels-and-reduce-debug-log-spam.patch create mode 100644 media-sound/mixxx/files/mixxx-2.1.0-library-improvements-for-all-skins-fix-lp1772202-in-tango.patch create mode 100644 media-sound/mixxx/files/mixxx-2.1.0-try-to-fix-appstream-config-and-desktop-icon.patch create mode 100644 media-sound/mixxx/files/mixxx-2.1.0-use-new-link-to-updated-2-1-feedback-form.patch diff --git a/media-sound/mixxx/Manifest b/media-sound/mixxx/Manifest index 5dd2069..f8f4296 100644 --- a/media-sound/mixxx/Manifest +++ b/media-sound/mixxx/Manifest @@ -11,6 +11,7 @@ AUX mixxx-2.1.0-empty-library-fix-lp1772591.patch 3337 BLAKE2B 3ab3e5f922dfe2fa5 AUX mixxx-2.1.0-fidlib-thread-safe-and-reentrant-generation-of-filters.patch 35122 BLAKE2B 976c623afc6f62fb5ee5082bcc503b7ca4bf5af160e102257024874e750a681347d6e4b70328a6596c88b261ed02f66ccb7c5897d1cf8174a92e4bb50d1e55c9 SHA512 377e2cd176264849f7de28d48107dca1c41b18a02c610d4f8c1ac824dc6e4c3d8b18363a7a3ae0d585157fed33592ad6cf578148508416b0783bd6b4084aaeb1 AUX mixxx-2.1.0-fix-cachingreader-compiler-warnings-about-non-trivial-types.patch 7055 BLAKE2B 669038949243674c8b7aaccd0cea4cc6c21644dd4bc2de463800bed71677d4e77cc5b3f5da89d0be3bdc44c847247afbf7b6248a29840aec676916bc8b9bc96f SHA512 45ec03e0d37b72d969fa730348a068df61200bae0a613045d9711637b6abc04608f2b3e7c2d99551dfa24c86846b3426c9f3600518258012e6e4d118f7beb947 AUX mixxx-2.1.0-fix-clearing-of-replaygain-gain-ratio-in-file-tags.patch 6898 BLAKE2B 7e20e44b0d6646cf410473b3d4c1ca310aa1b9ec8fafb06ee4480a90be7cb6fd3b67ac1a425d98beed03eef22016ad76f127ddcb46c6a7a22237ca93b59826ab SHA512 ecffb8bab5ad1d1f55acc2c3187a4dd10edda22e6708754e76184181808afc3fb014d43544b0a1006c9a439673bb56ab54549a0d95c0a05e709dcaba3600f8cc +AUX mixxx-2.1.0-fix-crash-when-importing-id3v2-apic-frames.patch 3731 BLAKE2B 7db0372c0e7cbcafc75214b900bc5a0e4e596a50aba7e681937f0de67d7f4b52fa6d65f91381f5a4193c6d5e86518cb01e64aa94080a400bff6fa44c97fa0b38 SHA512 082092491b1aa345df83e3d2e864087a198faf02ba81c64a6681c83e007d8c15e5bd9e1537712c5ff5e2f093443ad78597e7541d9074555b0f9f3f5dab007ee4 AUX mixxx-2.1.0-fix-crash-when-removing-a-quick-link.patch 3143 BLAKE2B e0562c35c83fcefe50362a5f2359cbca10853a0a4c2285866a5bd48a8ff7d13de066c2a153e86dd657c18fe1a30610f55f8e2ec95a958c9d0cc3a6288064f572 SHA512 94ba8e2e94f6f5ed8152f9499b5334211e812e374a5fafd48b8dc21e9e0b0ae8d6919f6a59fb3bae6c1d86de820ad654be45b0813f896cf4819dfaf2bebedc2d AUX mixxx-2.1.0-fix-decoding-of-improperly-encoded-flac-files.patch 8256 BLAKE2B 5fd8a4ddb15449477212f077b7b176ffe30adfbb5521eece8e9fa5e7af17a2247f3f9936841ebfcf271664e1cf8928f71426019e5b8e02ae4972193c4351de21 SHA512 0c44bbd9d8d67b843420de6cafeb3e10f2ed31ff8af424d5e9d219d41f3e465ddee40141530fcba000cb99e4a136850c418dcae5bd73047328c7436635d85071 AUX mixxx-2.1.0-fix-flac-decoding-and-upgrade-db-schema.patch 15891 BLAKE2B fd032363b07357c1fa16c2376b5f2f5b9580cb9c4534238336fca014f5432e460ba081c20608f22055c4e0799c17fba0f96b7d65a131d193d398ee5ffdda8e95 SHA512 99d3feb6761b8bd58acd7e1e4a8f0d2660b1bc1fb7f1885fb0211ad09dec3b1ab77c4ff0b8054e04313170bc050b0e655e8c90aa3d8301c39189ca6c2e2e4bdd @@ -20,14 +21,18 @@ AUX mixxx-2.1.0-fix-latenight-group-fx-buttons-in-deck.patch 7213 BLAKE2B 363c23 AUX mixxx-2.1.0-fix-memory-leak-when-loading-cover-art.patch 1473 BLAKE2B 4f7e59a8f97e36ecc073a2e6755dd44560a96f5f72217034a8ba2cd14f6790ab5d136ed54e2d4c87a2d039143c5804a9f8a9e476045433ab70367e973abdf145 SHA512 555d86b6793dbd4fb09c0c36bb69e31dd7cdceb99b1cdf9362349c6f25a93e3c0a078c4958a2bb3ad9d6329573d84e3ed913a5826a42444b0ec0902310e5cf3e AUX mixxx-2.1.0-fix-navigation-usability-issues-in-sidebar-tree.patch 15383 BLAKE2B 484df59087aaa09ca4cdfd61bb9236e1d07e9d7bb0d7be0e1bf576e1e546b3a8b10e9aadacb81336d01681612d920cfa28d809ceafc6f2d85a9cde724427b724 SHA512 4a817e0002d99812a092a808587f35adc849b8da8238e420ea7290e1900813374402d526bdabe0d260bf04b39c06051c64db2a41d0b7114c2381955cfb3abf57 AUX mixxx-2.1.0-fix-s4-mk2-for-windows.patch 2065 BLAKE2B aa36275f3e0fdb08c73408941f7374f5818890d0de119a6992a811f58c5da76ad45d47c5a2e5668eca47131eca12f565b4016c7b8510fb35f6ad03cd429cc0c8 SHA512 196ff5a3769a31b8b1fb264b8a3de1eccdd10c3764a4dd2c4c411ab3d886cd232601b86b119b375c0a08141f86afd8551a4315610cfd39459c3b0cb806246f6e +AUX mixxx-2.1.0-fix-some-log-levels-and-reduce-debug-log-spam.patch 43318 BLAKE2B 1afc339ee473c52e05f10104e44ba0460058115fb052b57496fc9eb9859a5bf74dcd49848bb5f9c7399da58463a0987516d0d21ec3ac1a5fd5d60637f83c955d SHA512 9599cb7da27244b3abf3e5bc01f1e89ca2c441639ce979ed3946404b023b9b1dbdec22d4a1e4481e6d2637d8e3f4f141e1ea21264eb3a9b80f0ec684d07623cf AUX mixxx-2.1.0-fix-spinback-inertia-effect-partial-revert-of-2b612c2.patch 1151 BLAKE2B a49e171ca017e3b36b7271859093e77bedd038dc42085330babc39a675549b708fa8b2a9b0774a44fa6cc0abbfcddad57173e75d7ce3d163828bfa6e727a1a6c SHA512 1bcda1e863337f9e330fb04ecdee1b0600093bad069bc0d48b3ac4e0c456471319bb42a0f5e9aa8b42bc1e88db81795063290733c57a1dff60f4750e55a206de AUX mixxx-2.1.0-fix-unresponsive-scrolling-through-crates-and-playlists-using-encoder.patch 10554 BLAKE2B fedfdb247f55ac438635a527e30b132386e95f40143c26b581f6929a45126b7d97a4ea98d84582a6dded002afa623a7fac3a0f1e2e03499e592967df0fbe7646 SHA512 18b3d51f5c341e412f9fae2bb596ef569906e628ea5102d35864f299be2c2f21853833964b0566f4c3c6a964ee52627eb6ec0982ebc3d4151b3e6210765504e1 +AUX mixxx-2.1.0-library-improvements-for-all-skins-fix-lp1772202-in-tango.patch 252028 BLAKE2B b74c8052548f7c65bf15300fefa998d619ab82ec073d162e7d6f856a3ea1626f6882c57f2e12cf9981e031390ee7aa476f349c1f33a8cad5c1ca68a2609e2dd3 SHA512 95442eb5cd8699d3e00d22baa76d4d41209f632a9fce04612dcf9fba598f00567546162f6375cdbd8922e8a61fc91c137847b166f1a8ced8fdb47eb4f8a92e17 AUX mixxx-2.1.0-optimize-flac-decoding.patch 9430 BLAKE2B f3d0b707f69332f94db54416fc9a9a6374302853daa8fb3046048e66f25259081f9bbe46c1dc8620076904a7f1a57abf051be0db3af02378ac9df06dc353f765 SHA512 5d244f8fe606eab6c6bea64439a520ada568dd2681d05fcdbdd1abebabf5bc74eecf3aa67765f4d2d78295a9a87c9ca7746cfc59cfd5db1a4b8a085f36b95cd6 AUX mixxx-2.1.0-pioneer-ddj-sx-mapping-bugfixes.patch 11255 BLAKE2B 9e15935f3fcfe9e26c04960496998450ee15cf8eb7b98e0439064caf9653617b94e0bf4c93f13ee49d169accabe662f9f8ca2abea05559b91d7f5362225de1c9 SHA512 f4774fe4884d339f2929468551b2f248200f3dc1c31c436070c8a439d18cf524aab0dd7ca990595e0c88ddd70e1e71dee025a641df6d240724fec94f2087ebd0 AUX mixxx-2.1.0-qt5-2.1.patch 20604 BLAKE2B 97b0145e68de1622020b52f08b9160fd23a7d9e42469201e40d93779eba903c496728a517ba274468de572a7714cfb0353859e76a380002219c39deb3fd23943 SHA512 8856aaa2d3c870a684d3e78deea2e162b00c96e3d64405615066430984525abcb71cc07c9f1dc0cdd18161ebb1aff8c1ebe223d21c3f3c4d3e92f3c38da3ffab AUX mixxx-2.1.0-reduce-log-spam-from-soundsourceproxy.patch 1791 BLAKE2B 84f51305c1054bc1ac50e59abf1fbad01f07dd316592fb6fdcbe268d19d19400c9a99e54ec74674c73632b8e443f25168f262eaa02e221204d0c3eb9320f3609 SHA512 d58f42be3b711df919e50ed2e665f95f63b265c6571e5b8109f2c7977f823d0360c8bd5e0618912d4c0d15a92a8ee673320fbd23c9fc2d75bd3a78aea0f9558b AUX mixxx-2.1.0-swap-default-values-for-temp-perm-ratechanges.patch 1534 BLAKE2B 30e2c7fe396919fcdfba7102f360e307e2104bfa6480ec5615bc1482f2e496f99435d745468621f6ff7ae15e0e4857fd6db692061cf5d7b19b0bc7672b889aea SHA512 e0c6365f26313935b503de36edb9ed247333e892352645d5379659bc7a53761b7b24d1a162dee38cb776e17f5e8741d5235713d47f5812975169395bb4d00f05 +AUX mixxx-2.1.0-try-to-fix-appstream-config-and-desktop-icon.patch 6964 BLAKE2B 360f71de43a63e19d052b46acfbd7437656fdf76325d17cae25509d409266263ae0dfb10b75f67c70a2f68d90c523a83bd052d772a28412dd9b40c76fdf8dac6 SHA512 20f45cfcd25cc11b1a39be58671f9a5162643247a3cd5e4dbf98620eebd2f8e79d2df454c932118ec630c20cdf8ec9dc9b54e15b9bcb20ae80683f3ecf25bc7c AUX mixxx-2.1.0-update-american-audio-vms4-preset-for-mixxx-v2.1.x.patch 26106 BLAKE2B e08dcc0a1572dcd1d6909644e2704e4b2c2f9646e0c96da6e0631bbebca4b680b490f13f20a5de5761ee826c77a53577ab24b5ba2d3627124bb4a93a4c54ef27 SHA512 5866243851348abfcb59db7d60932c523af62227d15df845517a283c1d579b358271ca22a1062a7df144f6c43ba9bdfc1c06eac41ea8b2ca23ae2493ca481322 AUX mixxx-2.1.0-use-an-in-memory-database-to-speed-up-library-tests.patch 3086 BLAKE2B d2cb0b7992cdb07b1ba2accde1d272cd3f75adf8bd3bb2450ad9203db5d7978c9b29dbf6e278a2a1f1fb8fb84f28b23f276f0f999b3e5d77c272b91716dcc9f1 SHA512 a6fefbc80f8facc8cd0bf501858b4dadb6ebe4bf476dc97273ad7e97ae2c0840ca9bd6b0b3aaa34caa837b967ee7fa12635c7c2957241ca6aff5a26531b6e25f +AUX mixxx-2.1.0-use-new-link-to-updated-2-1-feedback-form.patch 1091 BLAKE2B 49cd235c8bde044e9394f8b2b651714c793edcefd8a381954e3fa6e788e8277eab2370afe7d5523f8d6b0eb47277173fd757182f9b21a20e408bdb8931fd2f00 SHA512 c344991a8dbcf473ef368d5d6296fb598450d36cc22051669e496b35fdd7feb90c15dcf2c2ca53cf341e3b07b946f2f926b23fef10cba448d5eb5dadc29f8448 DIST mixxx-2.1.0-src.tar.gz 34835250 BLAKE2B 7a90c3794a146001fd0df6bb7c9c6231c0d26814eafc5c83da666d511d7af0e193b75da9b8728ad399dbef208cf2437881df2c87818e503945b02591bc300567 SHA512 d9f4fab92c2896ec455e2041aa6033f9a9091d2915a185a99427b9c35afe7c99565350ce477bf0487c6276c9585875f0be61f310779ae90195917d2e995bbf90 -EBUILD mixxx-2.1.0.ebuild 4663 BLAKE2B 7041f834fc0ebd35223734bb9cb48518ade04722522d6edc3391071c9dcb5ea3c99a3d541e27eedf15d19629e859c03978b917abafa180860f97006560353bb3 SHA512 df2ca290915d317a3a7d6e6cc46d408120b68b176d4a616c350e79a171c74c83c1643f5a8ec6585422737a7346204450ed56878780ad5a44ba7e2957ea3185c2 +EBUILD mixxx-2.1.0.ebuild 5463 BLAKE2B 099ec82f92155580e8d2e4232a0a0cfb3f88f521c820087983a02b59910763ed402945ef5943dce93b48ea849d1dc5c277870d7ac49367535594aa559e44dec1 SHA512 466ee536bf0f5b57fbf602615524ff266c77fec67c649389f747139058e903bb51626f873f452b71728792a8af925e59edb3fa16ac3749b0ca0bb8b5b33f4e5f diff --git a/media-sound/mixxx/files/mixxx-2.1.0-fix-crash-when-importing-id3v2-apic-frames.patch b/media-sound/mixxx/files/mixxx-2.1.0-fix-crash-when-importing-id3v2-apic-frames.patch new file mode 100644 index 0000000..dae29df --- /dev/null +++ b/media-sound/mixxx/files/mixxx-2.1.0-fix-crash-when-importing-id3v2-apic-frames.patch @@ -0,0 +1,84 @@ +From 8b408749a1efb7a9dba5bed6fec8a2af1023589c Mon Sep 17 00:00:00 2001 +From: Uwe Klotz +Date: Sat, 2 Jun 2018 17:23:57 +0200 +Subject: [PATCH] Fix crash when importing ID3v2 APIC frames with unexpected + type + +--- + src/track/trackmetadatataglib.cpp | 49 ++++++++++++++++++++++++++------------- + 1 file changed, 33 insertions(+), 16 deletions(-) + +diff --git a/src/track/trackmetadatataglib.cpp b/src/track/trackmetadatataglib.cpp +index 2615ae5bb6..ebbf120946 100644 +--- a/src/track/trackmetadatataglib.cpp ++++ b/src/track/trackmetadatataglib.cpp +@@ -876,6 +876,23 @@ QImage importCoverImageFromVorbisCommentPictureList( + return QImage(); + } + ++template ++const T* downcastID3v2Frame(TagLib::ID3v2::Frame* frame) { ++ DEBUG_ASSERT(frame); ++ // We need to use a safe dynamic_cast at runtime instead of an unsafe ++ // static_cast at compile time to detect unexpected frame subtypes! ++ // See also: https://bugs.launchpad.net/mixxx/+bug/1774790 ++ const T* downcastFrame = dynamic_cast(frame); ++ VERIFY_OR_DEBUG_ASSERT(downcastFrame) { ++ // This should only happen when reading corrupt or malformed files ++ kLogger.warning() ++ << "Unexpected ID3v2" ++ << frame->frameID().data() ++ << "frame type"; ++ } ++ return downcastFrame; ++} ++ + void importCoverImageFromID3v2Tag(QImage* pCoverArt, const TagLib::ID3v2::Tag& tag) { + if (!pCoverArt) { + return; // nothing to do +@@ -891,10 +908,9 @@ void importCoverImageFromID3v2Tag(QImage* pCoverArt, const TagLib::ID3v2::Tag& t + const TagLib::ID3v2::FrameList pFrames = iterAPIC->second; + for (const auto coverArtType: kPreferredID3v2PictureTypes) { + for (const auto pFrame: pFrames) { +- const TagLib::ID3v2::AttachedPictureFrame* pApicFrame = +- static_cast(pFrame); +- DEBUG_ASSERT(pApicFrame); // trust TagLib +- if (pApicFrame->type() == coverArtType) { ++ const auto* pApicFrame = ++ downcastID3v2Frame(pFrame); ++ if (pApicFrame && (pApicFrame->type() == coverArtType)) { + QImage image(loadImageFromID3v2PictureFrame(*pApicFrame)); + if (image.isNull()) { + kLogger.warning() +@@ -911,18 +927,19 @@ void importCoverImageFromID3v2Tag(QImage* pCoverArt, const TagLib::ID3v2::Tag& t + + // Fallback: No best match -> Simply select the 1st loadable image + for (const auto pFrame: pFrames) { +- const TagLib::ID3v2::AttachedPictureFrame* pApicFrame = +- static_cast(pFrame); +- DEBUG_ASSERT(pApicFrame); // trust TagLib +- const QImage image(loadImageFromID3v2PictureFrame(*pApicFrame)); +- if (image.isNull()) { +- kLogger.warning() +- << "Failed to load image from ID3v2 APIC frame of type" +- << pApicFrame->type(); +- continue; +- } else { +- *pCoverArt = image; +- return; // success ++ const auto* pApicFrame = ++ downcastID3v2Frame(pFrame); ++ if (pApicFrame) { ++ const QImage image(loadImageFromID3v2PictureFrame(*pApicFrame)); ++ if (image.isNull()) { ++ kLogger.warning() ++ << "Failed to load image from ID3v2 APIC frame of type" ++ << pApicFrame->type(); ++ continue; ++ } else { ++ *pCoverArt = image; ++ return; // success ++ } + } + } + } diff --git a/media-sound/mixxx/files/mixxx-2.1.0-fix-some-log-levels-and-reduce-debug-log-spam.patch b/media-sound/mixxx/files/mixxx-2.1.0-fix-some-log-levels-and-reduce-debug-log-spam.patch new file mode 100644 index 0000000..bb299c1 --- /dev/null +++ b/media-sound/mixxx/files/mixxx-2.1.0-fix-some-log-levels-and-reduce-debug-log-spam.patch @@ -0,0 +1,1003 @@ +From 217a05f9402177862144031202c7e92124fd6d3f Mon Sep 17 00:00:00 2001 +From: Uwe Klotz +Date: Sun, 27 May 2018 19:06:54 +0200 +Subject: [PATCH 1/6] Raise some log levels from debug to info/warning + +--- + plugins/soundsourcewv/soundsourcewv.cpp | 2 +- + src/library/dao/settingsdao.cpp | 2 +- + src/sources/soundsourcemp3.cpp | 4 ++-- + src/sources/soundsourcepluginlibrary.cpp | 2 +- + src/sources/soundsourceproxy.cpp | 4 ++-- + src/track/track.cpp | 2 +- + src/track/trackmetadatataglib.cpp | 2 +- + src/util/db/dbconnection.cpp | 4 ++-- + 8 files changed, 11 insertions(+), 11 deletions(-) + +diff --git a/plugins/soundsourcewv/soundsourcewv.cpp b/plugins/soundsourcewv/soundsourcewv.cpp +index 5d5c5b1c08..9d3a4f58c6 100644 +--- a/plugins/soundsourcewv/soundsourcewv.cpp ++++ b/plugins/soundsourcewv/soundsourcewv.cpp +@@ -62,7 +62,7 @@ SoundSource::OpenResult SoundSourceWV::tryOpen( + m_wpc = WavpackOpenFileInputEx(&s_streamReader, m_pWVFile, m_pWVCFile, + msg, openFlags, 0); + if (!m_wpc) { +- kLogger.debug() << "failed to open file : " << msg; ++ kLogger.warning() << "failed to open file : " << msg; + return OpenResult::Failed; + } + +diff --git a/src/library/dao/settingsdao.cpp b/src/library/dao/settingsdao.cpp +index 148409ab22..9f4a7ed19f 100644 +--- a/src/library/dao/settingsdao.cpp ++++ b/src/library/dao/settingsdao.cpp +@@ -32,7 +32,7 @@ QString SettingsDAO::getValue(const QString& name, QString defaultValue) const { + } else { + // Prepare is expected to fail for a fresh database + // when the schema is still empty! +- kLogger.debug() ++ kLogger.info() + << "Failed to prepare query:" + << "Returning default value" + << defaultValue +diff --git a/src/sources/soundsourcemp3.cpp b/src/sources/soundsourcemp3.cpp +index bce9186f95..84c5483f48 100644 +--- a/src/sources/soundsourcemp3.cpp ++++ b/src/sources/soundsourcemp3.cpp +@@ -630,7 +630,7 @@ ReadableSampleFrames SoundSourceMp3::readSampleFramesClamped( + #ifndef QT_NO_DEBUG_OUTPUT + const SINT madFrameChannelCount = MAD_NCHANNELS(&m_madFrame.header); + if (madFrameChannelCount != channelCount()) { +- kLogger.debug() << "MP3 frame header with mismatching number of channels" ++ kLogger.warning() << "MP3 frame header with mismatching number of channels" + << madFrameChannelCount << "<>" << channelCount(); + } + #endif +@@ -640,7 +640,7 @@ ReadableSampleFrames SoundSourceMp3::readSampleFramesClamped( + #ifndef QT_NO_DEBUG_OUTPUT + const SINT madSynthSampleRate = m_madSynth.pcm.samplerate; + if (madSynthSampleRate != sampleRate()) { +- kLogger.debug() << "Reading MP3 data with different sample rate" ++ kLogger.warning() << "Reading MP3 data with different sample rate" + << madSynthSampleRate << "<>" << sampleRate(); + } + #endif +diff --git a/src/sources/soundsourcepluginlibrary.cpp b/src/sources/soundsourcepluginlibrary.cpp +index 7270a039c2..c0ab472710 100644 +--- a/src/sources/soundsourcepluginlibrary.cpp ++++ b/src/sources/soundsourcepluginlibrary.cpp +@@ -49,7 +49,7 @@ bool SoundSourcePluginLibrary::init() { + << ":" << m_library.errorString(); + return false; + } +- kLogger.debug() << "Dynamically loaded plugin library" ++ kLogger.info() << "Dynamically loaded plugin library" + << m_library.fileName(); + + SoundSourcePluginAPI_getVersionFunc getVersionFunc = (SoundSourcePluginAPI_getVersionFunc) +diff --git a/src/sources/soundsourceproxy.cpp b/src/sources/soundsourceproxy.cpp +index 4dbe1b4765..1d3433523c 100644 +--- a/src/sources/soundsourceproxy.cpp ++++ b/src/sources/soundsourceproxy.cpp +@@ -55,7 +55,7 @@ QList getSoundSourcePluginDirectories() { + + const QString& pluginPath = CmdlineArgs::Instance().getPluginPath(); + if (!pluginPath.isEmpty()) { +- kLogger.debug() << "Adding plugin path from commandline arg:" << pluginPath; ++ kLogger.info() << "Adding plugin path from commandline arg:" << pluginPath; + pluginDirs << QDir(pluginPath); + } + +@@ -186,7 +186,7 @@ void SoundSourceProxy::loadPlugins() { + // that have been registered before (see above)! + const QList pluginDirs(getSoundSourcePluginDirectories()); + for (const auto& pluginDir: pluginDirs) { +- kLogger.debug() << "Loading SoundSource plugins" << pluginDir.path(); ++ kLogger.info() << "Loading SoundSource plugins" << pluginDir.path(); + const QStringList files(pluginDir.entryList( + SOUND_SOURCE_PLUGIN_FILENAME_PATTERN, + QDir::Files | QDir::NoDotAndDotDot)); +diff --git a/src/track/track.cpp b/src/track/track.cpp +index 4c114cd4d6..8f4a0dc087 100644 +--- a/src/track/track.cpp ++++ b/src/track/track.cpp +@@ -1007,7 +1007,7 @@ Track::ExportMetadataResult Track::exportMetadata( + // must be exported explicitly once. This ensures that we don't + // overwrite existing file tags with completely different + // information. +- kLogger.debug() ++ kLogger.info() + << "Skip exporting of unsynchronized track metadata:" + << getLocation(); + return ExportMetadataResult::Skipped; +diff --git a/src/track/trackmetadatataglib.cpp b/src/track/trackmetadatataglib.cpp +index 2615ae5bb6..21e84ed6c1 100644 +--- a/src/track/trackmetadatataglib.cpp ++++ b/src/track/trackmetadatataglib.cpp +@@ -249,7 +249,7 @@ bool parseReplayGainGain( + // the replay gain. + if (ratio == ReplayGain::kRatio0dB) { + // special case +- kLogger.debug() << "Ignoring possibly undefined gain:" << dbGain; ++ kLogger.info() << "Ignoring possibly undefined gain:" << dbGain; + ratio = ReplayGain::kRatioUndefined; + } + pReplayGain->setRatio(ratio); +diff --git a/src/util/db/dbconnection.cpp b/src/util/db/dbconnection.cpp +index d34f818478..98a43d6b42 100644 +--- a/src/util/db/dbconnection.cpp ++++ b/src/util/db/dbconnection.cpp +@@ -25,7 +25,7 @@ const mixxx::Logger kLogger("DbConnection"); + QSqlDatabase createDatabase( + const DbConnection::Params& params, + const QString connectionName) { +- kLogger.debug() ++ kLogger.info() + << "Available drivers for database connections:" + << QSqlDatabase::drivers(); + +@@ -233,7 +233,7 @@ bool initDatabase(QSqlDatabase database) { + #ifdef __SQLITE3__ + QVariant v = database.driver()->handle(); + VERIFY_OR_DEBUG_ASSERT(v.isValid()) { +- kLogger.debug() << "Driver handle is invalid"; ++ kLogger.warning() << "Driver handle is invalid"; + return false; // abort + } + if (strcmp(v.typeName(), "sqlite3*") != 0) { + +From 012421669b6c773d800c7bb457d91daa97d011df Mon Sep 17 00:00:00 2001 +From: Uwe Klotz +Date: Sun, 27 May 2018 19:08:19 +0200 +Subject: [PATCH 2/6] Lower log level for non-critical MP3 decoding errors + +--- + src/sources/soundsourcemp3.cpp | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/src/sources/soundsourcemp3.cpp b/src/sources/soundsourcemp3.cpp +index 84c5483f48..9f5e684e1f 100644 +--- a/src/sources/soundsourcemp3.cpp ++++ b/src/sources/soundsourcemp3.cpp +@@ -612,7 +612,7 @@ ReadableSampleFrames SoundSourceMp3::readSampleFramesClamped( + kLogger.debug() << "Recoverable MP3 frame decoding error:" + << mad_stream_errorstr(&m_madStream); + } else { +- kLogger.warning() << "Recoverable MP3 frame decoding error:" ++ kLogger.info() << "Recoverable MP3 frame decoding error:" + << mad_stream_errorstr(&m_madStream); + } + } + +From 2fd6df0b258dc8dd4bb30da0b8781286d4aac09d Mon Sep 17 00:00:00 2001 +From: Uwe Klotz +Date: Sun, 27 May 2018 19:09:08 +0200 +Subject: [PATCH 3/6] Only log debug messages if debug logging is enabled + +--- + src/database/schemamanager.cpp | 8 +++++--- + src/library/coverartcache.cpp | 14 +++++++++++--- + src/library/crate/cratestorage.cpp | 30 ++++++++++++++++++++---------- + src/library/trackcollection.cpp | 4 +++- + src/sources/metadatasourcetaglib.cpp | 28 +++++++++++++++++----------- + src/sources/soundsourcemp3.cpp | 15 +++++++++++---- + src/sources/soundsourceproxy.cpp | 34 ++++++++++++++++++++-------------- + src/track/track.cpp | 20 +++++++++++++------- + src/track/trackmetadatataglib.cpp | 21 ++++++++++++++------- + src/util/db/dbconnection.cpp | 16 ++++++++++------ + src/util/db/dbconnectionpooled.cpp | 8 +++++--- + src/util/db/sqltransaction.cpp | 24 +++++++++++++++--------- + 12 files changed, 144 insertions(+), 78 deletions(-) + +diff --git a/src/database/schemamanager.cpp b/src/database/schemamanager.cpp +index 2e678fc8e1..1e2e2122d7 100644 +--- a/src/database/schemamanager.cpp ++++ b/src/database/schemamanager.cpp +@@ -99,9 +99,11 @@ SchemaManager::Result SchemaManager::upgradeToSchemaVersion( + } + } + +- kLogger.debug() +- << "Loading database schema migrations from" +- << schemaFilename; ++ if (kLogger.debugEnabled()) { ++ kLogger.debug() ++ << "Loading database schema migrations from" ++ << schemaFilename; ++ } + QDomElement schemaRoot = XmlParse::openXMLFile(schemaFilename, "schema"); + if (schemaRoot.isNull()) { + kLogger.critical() +diff --git a/src/library/coverartcache.cpp b/src/library/coverartcache.cpp +index e76168422d..aa19e1506f 100644 +--- a/src/library/coverartcache.cpp ++++ b/src/library/coverartcache.cpp +@@ -194,15 +194,23 @@ void CoverArtCache::requestGuessCover(TrackPointer pTrack) { + + void CoverArtCache::guessCover(TrackPointer pTrack) { + if (pTrack) { +- kLogger.debug() << "Guessing cover art for" << pTrack->getLocation(); ++ if (kLogger.debugEnabled()) { ++ kLogger.debug() ++ << "Guessing cover art for" ++ << pTrack->getLocation(); ++ } + CoverInfo cover = CoverArtUtils::guessCoverInfo(*pTrack); + pTrack->setCoverInfo(cover); + } + } + + void CoverArtCache::guessCovers(QList tracks) { +- kLogger.debug() << "Guessing cover art for" +- << tracks.size() << "tracks"; ++ if (kLogger.debugEnabled()) { ++ kLogger.debug() ++ << "Guessing cover art for" ++ << tracks.size() ++ << "tracks"; ++ } + foreach (TrackPointer pTrack, tracks) { + guessCover(pTrack); + } +diff --git a/src/library/crate/cratestorage.cpp b/src/library/crate/cratestorage.cpp +index 05afdfcde2..8260f8cb0a 100644 +--- a/src/library/crate/cratestorage.cpp ++++ b/src/library/crate/cratestorage.cpp +@@ -303,8 +303,11 @@ bool CrateStorage::readCrateByName(const QString& name, Crate* pCrate) const { + } + return true; + } else { +- kLogger.debug() +- << "Crate not found by name:" << name; ++ if (kLogger.debugEnabled()) { ++ kLogger.debug() ++ << "Crate not found by name:" ++ << name; ++ } + } + } + return false; +@@ -647,8 +650,11 @@ bool CrateStorage::onDeletingCrate( + return false; + } + if (query.numRowsAffected() <= 0) { +- kLogger.debug() +- << "Deleting empty crate with id" << crateId; ++ if (kLogger.debugEnabled()) { ++ kLogger.debug() ++ << "Deleting empty crate with id" ++ << crateId; ++ } + } + } + { +@@ -697,9 +703,11 @@ bool CrateStorage::onAddingCrateTracks( + } + if (query.numRowsAffected() == 0) { + // track is already in crate +- kLogger.debug() +- << "Track" << trackId +- << "not added to crate" << crateId; ++ if (kLogger.debugEnabled()) { ++ kLogger.debug() ++ << "Track" << trackId ++ << "not added to crate" << crateId; ++ } + } else { + DEBUG_ASSERT(query.numRowsAffected() == 1); + } +@@ -729,9 +737,11 @@ bool CrateStorage::onRemovingCrateTracks( + } + if (query.numRowsAffected() == 0) { + // track not found in crate +- kLogger.debug() +- << "Track" << trackId +- << "not removed from crate" << crateId; ++ if (kLogger.debugEnabled()) { ++ kLogger.debug() ++ << "Track" << trackId ++ << "not removed from crate" << crateId; ++ } + } else { + DEBUG_ASSERT(query.numRowsAffected() == 1); + } +diff --git a/src/library/trackcollection.cpp b/src/library/trackcollection.cpp +index 1981fb781c..62c0b64ab4 100644 +--- a/src/library/trackcollection.cpp ++++ b/src/library/trackcollection.cpp +@@ -24,7 +24,9 @@ TrackCollection::TrackCollection( + } + + TrackCollection::~TrackCollection() { +- kLogger.debug() << "~TrackCollection()"; ++ if (kLogger.debugEnabled()) { ++ kLogger.debug() << "~TrackCollection()"; ++ } + // The database should have been detached earlier + DEBUG_ASSERT(!m_database.isOpen()); + } +diff --git a/src/sources/metadatasourcetaglib.cpp b/src/sources/metadatasourcetaglib.cpp +index 91b3277a9b..de617b618c 100644 +--- a/src/sources/metadatasourcetaglib.cpp ++++ b/src/sources/metadatasourcetaglib.cpp +@@ -112,10 +112,12 @@ MetadataSourceTagLib::importTrackMetadataAndCoverImage( + << "with type" << m_fileType; + return afterImport(ImportResult::Unavailable); + } +- kLogger.trace() << "Importing" +- << ((pTrackMetadata && pCoverImage) ? "track metadata and cover art" : (pTrackMetadata ? "track metadata" : "cover art")) +- << "from file" << m_fileName +- << "with type" << m_fileType; ++ if (kLogger.traceEnabled()) { ++ kLogger.trace() << "Importing" ++ << ((pTrackMetadata && pCoverImage) ? "track metadata and cover art" : (pTrackMetadata ? "track metadata" : "cover art")) ++ << "from file" << m_fileName ++ << "with type" << m_fileType; ++ } + + // Rationale: If a file contains different types of tags only + // a single type of tag will be read. Tag types are read in a +@@ -326,10 +328,12 @@ MetadataSourceTagLib::importTrackMetadataAndCoverImage( + return afterImport(ImportResult::Failed); + } + +- kLogger.debug() +- << "No track metadata or cover art found" +- << "in file" << m_fileName +- << "with type" << m_fileType; ++ if (kLogger.debugEnabled()) { ++ kLogger.debug() ++ << "No track metadata or cover art found" ++ << "in file" << m_fileName ++ << "with type" << m_fileType; ++ } + return afterImport(ImportResult::Unavailable); + } + +@@ -745,9 +749,11 @@ class SafelyWritableFile final { + std::pair + MetadataSourceTagLib::exportTrackMetadata( + const TrackMetadata& trackMetadata) const { +- kLogger.debug() << "Exporting track metadata" +- << "into file" << m_fileName +- << "with type" << m_fileType; ++ if (kLogger.debugEnabled()) { ++ kLogger.debug() << "Exporting track metadata" ++ << "into file" << m_fileName ++ << "with type" << m_fileType; ++ } + + SafelyWritableFile safelyWritableFile(m_fileName, kExportTrackMetadataIntoTemporaryFile); + +diff --git a/src/sources/soundsourcemp3.cpp b/src/sources/soundsourcemp3.cpp +index 9f5e684e1f..8a79f863b3 100644 +--- a/src/sources/soundsourcemp3.cpp ++++ b/src/sources/soundsourcemp3.cpp +@@ -393,7 +393,9 @@ void SoundSourceMp3::close() { + + void SoundSourceMp3::restartDecoding( + const SeekFrameType& seekFrame) { +- kLogger.debug() << "restartDecoding @" << seekFrame.frameIndex; ++ if (kLogger.debugEnabled()) { ++ kLogger.debug() << "restartDecoding @" << seekFrame.frameIndex; ++ } + + // Discard decoded output + m_madSynthCount = 0; +@@ -609,8 +611,11 @@ ReadableSampleFrames SoundSourceMp3::readSampleFramesClamped( + // Don't bother the user with warnings from recoverable + // errors while skipping decoded samples or that even + // might occur for files that are perfectly ok. +- kLogger.debug() << "Recoverable MP3 frame decoding error:" +- << mad_stream_errorstr(&m_madStream); ++ if (kLogger.debugEnabled()) { ++ kLogger.debug() ++ << "Recoverable MP3 frame decoding error:" ++ << mad_stream_errorstr(&m_madStream); ++ } + } else { + kLogger.info() << "Recoverable MP3 frame decoding error:" + << mad_stream_errorstr(&m_madStream); +@@ -620,7 +625,9 @@ ReadableSampleFrames SoundSourceMp3::readSampleFramesClamped( + } + } + if (pMadThisFrame == m_madStream.this_frame) { +- kLogger.debug() << "Retry decoding MP3 frame @" << m_curFrameIndex; ++ if (kLogger.debugEnabled()) { ++ kLogger.debug() << "Retry decoding MP3 frame @" << m_curFrameIndex; ++ } + // Retry decoding + continue; + } +diff --git a/src/sources/soundsourceproxy.cpp b/src/sources/soundsourceproxy.cpp +index 1d3433523c..3431ac3fcd 100644 +--- a/src/sources/soundsourceproxy.cpp ++++ b/src/sources/soundsourceproxy.cpp +@@ -402,12 +402,14 @@ void SoundSourceProxy::initSoundSource() { + // ...and continue loop + DEBUG_ASSERT(!m_pSoundSource); + } else { +- kLogger.debug() << "SoundSourceProvider" +- << pProvider->getName() +- << "created a SoundSource for file" +- << getUrl().toString() +- << "of type" +- << m_pSoundSource->getType(); ++ if (kLogger.debugEnabled()) { ++ kLogger.debug() << "SoundSourceProvider" ++ << pProvider->getName() ++ << "created a SoundSource for file" ++ << getUrl().toString() ++ << "of type" ++ << m_pSoundSource->getType(); ++ } + } + } + } +@@ -618,12 +620,14 @@ mixxx::AudioSourcePointer SoundSourceProxy::openAudioSource(const mixxx::AudioSo + DEBUG_ASSERT(m_pTrack); + auto openMode = mixxx::SoundSource::OpenMode::Strict; + while (m_pSoundSource && !m_pAudioSource) { +- kLogger.debug() << "Opening file" +- << getUrl().toString() +- << "with provider" +- << getSoundSourceProvider()->getName() +- << "using mode" +- << openMode; ++ if (kLogger.debugEnabled()) { ++ kLogger.debug() << "Opening file" ++ << getUrl().toString() ++ << "with provider" ++ << getSoundSourceProvider()->getName() ++ << "using mode" ++ << openMode; ++ } + const mixxx::SoundSource::OpenResult openResult = + m_pSoundSource->open(openMode, params); + if ((openResult == mixxx::SoundSource::OpenResult::Aborted) || +@@ -695,7 +699,9 @@ void SoundSourceProxy::closeAudioSource() { + DEBUG_ASSERT(m_pSoundSource); + m_pSoundSource->close(); + m_pAudioSource = mixxx::AudioSourcePointer(); +- kLogger.debug() << "Closed AudioSource for file" +- << getUrl().toString(); ++ if (kLogger.debugEnabled()) { ++ kLogger.debug() << "Closed AudioSource for file" ++ << getUrl().toString(); ++ } + } + } +diff --git a/src/track/track.cpp b/src/track/track.cpp +index 8f4a0dc087..1da3ed8ee7 100644 +--- a/src/track/track.cpp ++++ b/src/track/track.cpp +@@ -306,7 +306,9 @@ double Track::setBpm(double bpmValue) { + + // Continue with the regular case + if (m_pBeats->getBpm() != bpmValue) { +- kLogger.debug() << "Updating BPM:" << getLocation(); ++ if (kLogger.debugEnabled()) { ++ kLogger.debug() << "Updating BPM:" << getLocation(); ++ } + m_pBeats->setBpm(bpmValue); + markDirtyAndUnlock(&lock); + // Tell the GUI to update the bpm label... +@@ -1052,9 +1054,11 @@ Track::ExportMetadataResult Track::exportMetadata( + if (!m_record.getMetadata().hasBeenModifiedAfterImport(importedFromFile)) { + // The file tags are in-sync with the track's metadata and don't need + // to be updated. +- kLogger.debug() +- << "Skip exporting of unmodified track metadata into file:" +- << getLocation(); ++ if (kLogger.debugEnabled()) { ++ kLogger.debug() ++ << "Skip exporting of unmodified track metadata into file:" ++ << getLocation(); ++ } + return ExportMetadataResult::Skipped; + } + } else { +@@ -1085,9 +1089,11 @@ Track::ExportMetadataResult Track::exportMetadata( + DEBUG_ASSERT(!trackMetadataExported.second.isNull()); + //pTrack->setMetadataSynchronized(trackMetadataExported.second); + m_record.setMetadataSynchronized(!trackMetadataExported.second.isNull()); +- kLogger.debug() +- << "Exported track metadata:" +- << getLocation(); ++ if (kLogger.debugEnabled()) { ++ kLogger.debug() ++ << "Exported track metadata:" ++ << getLocation(); ++ } + return ExportMetadataResult::Succeeded; + } else { + kLogger.warning() +diff --git a/src/track/trackmetadatataglib.cpp b/src/track/trackmetadatataglib.cpp +index 21e84ed6c1..0f0aa01b61 100644 +--- a/src/track/trackmetadatataglib.cpp ++++ b/src/track/trackmetadatataglib.cpp +@@ -564,7 +564,11 @@ int removeUserTextIdentificationFrames( + toQString(pFrame->description())); + if (0 == frameDescription.compare( + description, Qt::CaseInsensitive)) { +- kLogger.debug() << "Removing ID3v2 TXXX frame:" << toQString(pFrame->description()); ++ if (kLogger.debugEnabled()) { ++ kLogger.debug() ++ << "Removing ID3v2 TXXX frame:" ++ << toQString(pFrame->description()); ++ } + // After removing a frame the result of frameListMap() + // is no longer valid!! + pTag->removeFrame(pFrame, false); // remove an unowned frame +@@ -838,7 +842,9 @@ bool readAudioProperties( + QImage importCoverImageFromVorbisCommentPictureList( + const TagLib::List& pictures) { + if (pictures.isEmpty()) { +- kLogger.debug() << "VorbisComment picture list is empty"; ++ if (kLogger.debugEnabled()) { ++ kLogger.debug() << "VorbisComment picture list is empty"; ++ } + return QImage(); + } + +@@ -883,8 +889,9 @@ void importCoverImageFromID3v2Tag(QImage* pCoverArt, const TagLib::ID3v2::Tag& t + + const auto iterAPIC = tag.frameListMap().find("APIC"); + if ((iterAPIC == tag.frameListMap().end()) || iterAPIC->second.isEmpty()) { +- kLogger.debug() +- << "No cover art: None or empty list of ID3v2 APIC frames"; ++ if (kLogger.debugEnabled()) { ++ kLogger.debug() << "No cover art: None or empty list of ID3v2 APIC frames"; ++ } + return; // abort + } + +@@ -1026,9 +1033,9 @@ void importCoverImageFromVorbisCommentTag(QImage* pCoverArt, TagLib::Ogg::XiphCo + } + } + } +- +- kLogger.debug() +- << "No cover art found in VorbisComment tag"; ++ if (kLogger.debugEnabled()) { ++ kLogger.debug() << "No cover art found in VorbisComment tag"; ++ } + } + + void importCoverImageFromMP4Tag(QImage* pCoverArt, const TagLib::MP4::Tag& tag) { +diff --git a/src/util/db/dbconnection.cpp b/src/util/db/dbconnection.cpp +index 98a43d6b42..ee78dfec0f 100644 +--- a/src/util/db/dbconnection.cpp ++++ b/src/util/db/dbconnection.cpp +@@ -313,9 +313,11 @@ DbConnection::~DbConnection() { + } + + bool DbConnection::open() { +- kLogger.debug() +- << "Opening database connection" +- << *this; ++ if (kLogger.debugEnabled()) { ++ kLogger.debug() ++ << "Opening database connection" ++ << *this; ++ } + if (!m_sqlDatabase.open()) { + kLogger.warning() + << "Failed to open database connection" +@@ -343,9 +345,11 @@ void DbConnection::close() { + << "Rolled back open transaction before closing database connection:" + << *this; + } +- kLogger.debug() +- << "Closing database connection:" +- << *this; ++ if (kLogger.debugEnabled()) { ++ kLogger.debug() ++ << "Closing database connection:" ++ << *this; ++ } + m_sqlDatabase.close(); + } + } +diff --git a/src/util/db/dbconnectionpooled.cpp b/src/util/db/dbconnectionpooled.cpp +index cf74c4d2d5..33369511eb 100644 +--- a/src/util/db/dbconnectionpooled.cpp ++++ b/src/util/db/dbconnectionpooled.cpp +@@ -26,9 +26,11 @@ DbConnectionPooled::operator QSqlDatabase() const { + << "Thread-local database connection not found"; + return QSqlDatabase(); // abort + } +- kLogger.debug() +- << "Found thread-local database connection" +- << *pDbConnection;; ++ if (kLogger.debugEnabled()) { ++ kLogger.debug() ++ << "Found thread-local database connection" ++ << *pDbConnection;; ++ } + return *pDbConnection; + } + +diff --git a/src/util/db/sqltransaction.cpp b/src/util/db/sqltransaction.cpp +index 463637743c..c6ae4fe108 100644 +--- a/src/util/db/sqltransaction.cpp ++++ b/src/util/db/sqltransaction.cpp +@@ -18,9 +18,11 @@ bool beginTransaction(QSqlDatabase database) { + return false; + } + if (database.transaction()) { +- kLogger.debug() +- << "Started new SQL database transaction on" +- << database.connectionName(); ++ if (kLogger.debugEnabled()) { ++ kLogger.debug() ++ << "Started new SQL database transaction on" ++ << database.connectionName(); ++ } + return true; + } else { + kLogger.warning() +@@ -63,9 +65,11 @@ bool SqlTransaction::commit() { + return false; + } + if (m_database.commit()) { +- kLogger.debug() +- << "Committed SQL database transaction on" +- << m_database.connectionName(); ++ if (kLogger.debugEnabled()) { ++ kLogger.debug() ++ << "Committed SQL database transaction on" ++ << m_database.connectionName(); ++ } + release(); // commit/rollback only once + return true; + } else { +@@ -84,9 +88,11 @@ bool SqlTransaction::rollback() { + return false; + } + if (m_database.rollback()) { +- kLogger.debug() +- << "Rolled back SQL database transaction on" +- << m_database.connectionName(); ++ if (kLogger.debugEnabled()) { ++ kLogger.debug() ++ << "Rolled back SQL database transaction on" ++ << m_database.connectionName(); ++ } + release(); // commit/rollback only once + return true; + } else { + +From 84a40ba879b63636efa9d09d6a2cace2fc22fff0 Mon Sep 17 00:00:00 2001 +From: Uwe Klotz +Date: Mon, 28 May 2018 09:57:53 +0200 +Subject: [PATCH 4/6] Re-enable file related logs + +--- + src/sources/metadatasourcetaglib.cpp | 11 ++++++----- + src/sources/soundsourceproxy.cpp | 17 +++++++++-------- + 2 files changed, 15 insertions(+), 13 deletions(-) + +diff --git a/src/sources/metadatasourcetaglib.cpp b/src/sources/metadatasourcetaglib.cpp +index de617b618c..0b68ef8af6 100644 +--- a/src/sources/metadatasourcetaglib.cpp ++++ b/src/sources/metadatasourcetaglib.cpp +@@ -749,11 +749,12 @@ class SafelyWritableFile final { + std::pair + MetadataSourceTagLib::exportTrackMetadata( + const TrackMetadata& trackMetadata) const { +- if (kLogger.debugEnabled()) { +- kLogger.debug() << "Exporting track metadata" +- << "into file" << m_fileName +- << "with type" << m_fileType; +- } ++ // NOTE(uklotzde): Log unconditionally (with debug level) to ++ // identify files in the log file that might have caused a ++ // crash while exporting metadata. ++ kLogger.debug() << "Exporting track metadata" ++ << "into file" << m_fileName ++ << "with type" << m_fileType; + + SafelyWritableFile safelyWritableFile(m_fileName, kExportTrackMetadataIntoTemporaryFile); + +diff --git a/src/sources/soundsourceproxy.cpp b/src/sources/soundsourceproxy.cpp +index 3431ac3fcd..145303eaf2 100644 +--- a/src/sources/soundsourceproxy.cpp ++++ b/src/sources/soundsourceproxy.cpp +@@ -620,14 +620,15 @@ mixxx::AudioSourcePointer SoundSourceProxy::openAudioSource(const mixxx::AudioSo + DEBUG_ASSERT(m_pTrack); + auto openMode = mixxx::SoundSource::OpenMode::Strict; + while (m_pSoundSource && !m_pAudioSource) { +- if (kLogger.debugEnabled()) { +- kLogger.debug() << "Opening file" +- << getUrl().toString() +- << "with provider" +- << getSoundSourceProvider()->getName() +- << "using mode" +- << openMode; +- } ++ // NOTE(uklotzde): Log unconditionally (with debug level) to ++ // identify files in the log file that might have caused a ++ // crash while importing metadata or decoding audio subsequently. ++ kLogger.debug() << "Opening file" ++ << getUrl().toString() ++ << "with provider" ++ << getSoundSourceProvider()->getName() ++ << "using mode" ++ << openMode; + const mixxx::SoundSource::OpenResult openResult = + m_pSoundSource->open(openMode, params); + if ((openResult == mixxx::SoundSource::OpenResult::Aborted) || + +From 2442f53bd40130fa2ad23c7b3323631af43ec86c Mon Sep 17 00:00:00 2001 +From: Uwe Klotz +Date: Sat, 2 Jun 2018 19:22:07 +0200 +Subject: [PATCH 5/6] Fix propagation of log levels into plugins with an ugly + hack + +The configured log levels have to be propagated into the plugins +upon initialization! This was already broken before I submitted +the previous changes that finally broke the plugin build on macOS. +--- + plugins/soundsourcem4a/soundsourcem4a.cpp | 9 ++++++++- + plugins/soundsourcem4a/soundsourcem4a.h | 2 +- + .../soundsourcemediafoundation.cpp | 9 ++++++++- + .../soundsourcemediafoundation.h | 2 +- + plugins/soundsourcewv/soundsourcewv.cpp | 9 ++++++++- + plugins/soundsourcewv/soundsourcewv.h | 2 +- + src/sources/soundsourcepluginapi.h | 3 ++- + src/sources/soundsourcepluginlibrary.cpp | 2 +- + src/util/logging.cpp | 8 ++++---- + src/util/logging.h | 14 +++++++++----- + 10 files changed, 43 insertions(+), 17 deletions(-) + +diff --git a/plugins/soundsourcem4a/soundsourcem4a.cpp b/plugins/soundsourcem4a/soundsourcem4a.cpp +index f0a5e15c92..192cc7f132 100644 +--- a/plugins/soundsourcem4a/soundsourcem4a.cpp ++++ b/plugins/soundsourcem4a/soundsourcem4a.cpp +@@ -22,6 +22,11 @@ typedef unsigned long SAMPLERATE_TYPE; + + namespace mixxx { + ++// TODO(XXX): Remove this ugly "extern" hack after getting rid of ++// the broken plugin architecture. ++LogLevel g_logLevel; ++LogLevel g_logFlushLevel; ++ + namespace { + + const Logger kLogger("SoundSourceM4A"); +@@ -617,9 +622,11 @@ SoundSourcePointer SoundSourceProviderM4A::newSoundSource(const QUrl& url) { + } // namespace mixxx + + extern "C" MIXXX_SOUNDSOURCEPLUGINAPI_EXPORT +-mixxx::SoundSourceProvider* Mixxx_SoundSourcePluginAPI_createSoundSourceProvider() { ++mixxx::SoundSourceProvider* Mixxx_SoundSourcePluginAPI_createSoundSourceProvider(int logLevel, int logFlushLevel) { + // SoundSourceProviderM4A is stateless and a single instance + // can safely be shared ++ mixxx::g_logLevel = static_cast(logLevel); ++ mixxx::g_logFlushLevel = static_cast(logFlushLevel); + static mixxx::SoundSourceProviderM4A singleton; + return &singleton; + } +diff --git a/plugins/soundsourcem4a/soundsourcem4a.h b/plugins/soundsourcem4a/soundsourcem4a.h +index 0ef84a9ac5..98dc47f15c 100644 +--- a/plugins/soundsourcem4a/soundsourcem4a.h ++++ b/plugins/soundsourcem4a/soundsourcem4a.h +@@ -74,7 +74,7 @@ class SoundSourceProviderM4A: public SoundSourceProvider { + } // namespace mixxx + + extern "C" MIXXX_SOUNDSOURCEPLUGINAPI_EXPORT +-mixxx::SoundSourceProvider* Mixxx_SoundSourcePluginAPI_createSoundSourceProvider(); ++mixxx::SoundSourceProvider* Mixxx_SoundSourcePluginAPI_createSoundSourceProvider(int logLevel, int logFlushLevel); + + extern "C" MIXXX_SOUNDSOURCEPLUGINAPI_EXPORT + void Mixxx_SoundSourcePluginAPI_destroySoundSourceProvider(mixxx::SoundSourceProvider*); +diff --git a/plugins/soundsourcemediafoundation/soundsourcemediafoundation.cpp b/plugins/soundsourcemediafoundation/soundsourcemediafoundation.cpp +index 8eac78220d..c1a751b948 100755 +--- a/plugins/soundsourcemediafoundation/soundsourcemediafoundation.cpp ++++ b/plugins/soundsourcemediafoundation/soundsourcemediafoundation.cpp +@@ -43,6 +43,11 @@ template static void safeRelease(T **ppT) { + + namespace mixxx { + ++// TODO(XXX): Remove this ugly "extern" hack after getting rid of ++// the broken plugin architecture. ++LogLevel g_logLevel; ++LogLevel g_logFlushLevel; ++ + SoundSourceMediaFoundation::SoundSourceMediaFoundation(const QUrl& url) + : SoundSourcePlugin(url, "m4a"), + m_hrCoInitialize(E_FAIL), +@@ -803,9 +808,11 @@ SoundSourcePointer SoundSourceProviderMediaFoundation::newSoundSource(const QUrl + } // namespace mixxx + + extern "C" MIXXX_SOUNDSOURCEPLUGINAPI_EXPORT +-mixxx::SoundSourceProvider* Mixxx_SoundSourcePluginAPI_createSoundSourceProvider() { ++mixxx::SoundSourceProvider* Mixxx_SoundSourcePluginAPI_createSoundSourceProvider(int logLevel, int logFlushLevel) { + // SoundSourceProviderMediaFoundation is stateless and a single instance + // can safely be shared ++ mixxx::g_logLevel = static_cast(logLevel); ++ mixxx::g_logFlushLevel = static_cast(logFlushLevel); + static mixxx::SoundSourceProviderMediaFoundation singleton; + return &singleton; + } +diff --git a/plugins/soundsourcemediafoundation/soundsourcemediafoundation.h b/plugins/soundsourcemediafoundation/soundsourcemediafoundation.h +index e9a8d608f1..e299408cb9 100755 +--- a/plugins/soundsourcemediafoundation/soundsourcemediafoundation.h ++++ b/plugins/soundsourcemediafoundation/soundsourcemediafoundation.h +@@ -101,7 +101,7 @@ class SoundSourceProviderMediaFoundation: public SoundSourceProvider { + + + extern "C" MIXXX_SOUNDSOURCEPLUGINAPI_EXPORT +-mixxx::SoundSourceProvider* Mixxx_SoundSourcePluginAPI_createSoundSourceProvider(); ++mixxx::SoundSourceProvider* Mixxx_SoundSourcePluginAPI_createSoundSourceProvider(int logLevel, int logFlushLevel); + + extern "C" MIXXX_SOUNDSOURCEPLUGINAPI_EXPORT + void Mixxx_SoundSourcePluginAPI_destroySoundSourceProvider(mixxx::SoundSourceProvider*); +diff --git a/plugins/soundsourcewv/soundsourcewv.cpp b/plugins/soundsourcewv/soundsourcewv.cpp +index 9d3a4f58c6..e69babfa4c 100644 +--- a/plugins/soundsourcewv/soundsourcewv.cpp ++++ b/plugins/soundsourcewv/soundsourcewv.cpp +@@ -6,6 +6,11 @@ + + namespace mixxx { + ++// TODO(XXX): Remove this ugly "extern" hack after getting rid of ++// the broken plugin architecture. ++LogLevel g_logLevel; ++LogLevel g_logFlushLevel; ++ + namespace { + + const Logger kLogger("SoundSourceWV"); +@@ -267,9 +272,11 @@ int32_t SoundSourceWV::WriteBytesCallback(void* id, void* data, int32_t bcount) + } // namespace mixxx + + extern "C" MIXXX_SOUNDSOURCEPLUGINAPI_EXPORT +-mixxx::SoundSourceProvider* Mixxx_SoundSourcePluginAPI_createSoundSourceProvider() { ++mixxx::SoundSourceProvider* Mixxx_SoundSourcePluginAPI_createSoundSourceProvider(int logLevel, int logFlushLevel) { + // SoundSourceProviderWV is stateless and a single instance + // can safely be shared ++ mixxx::g_logLevel = static_cast(logLevel); ++ mixxx::g_logFlushLevel = static_cast(logFlushLevel); + static mixxx::SoundSourceProviderWV singleton; + return &singleton; + } +diff --git a/plugins/soundsourcewv/soundsourcewv.h b/plugins/soundsourcewv/soundsourcewv.h +index 7ce6f340b6..7c2144101d 100644 +--- a/plugins/soundsourcewv/soundsourcewv.h ++++ b/plugins/soundsourcewv/soundsourcewv.h +@@ -55,7 +55,7 @@ class SoundSourceProviderWV: public SoundSourceProvider { + } // namespace mixxx + + extern "C" MIXXX_SOUNDSOURCEPLUGINAPI_EXPORT +-mixxx::SoundSourceProvider* Mixxx_SoundSourcePluginAPI_createSoundSourceProvider(); ++mixxx::SoundSourceProvider* Mixxx_SoundSourcePluginAPI_createSoundSourceProvider(int logLevel, int logFlushLevel); + + extern "C" MIXXX_SOUNDSOURCEPLUGINAPI_EXPORT + void Mixxx_SoundSourcePluginAPI_destroySoundSourceProvider(mixxx::SoundSourceProvider*); +diff --git a/src/sources/soundsourcepluginapi.h b/src/sources/soundsourcepluginapi.h +index d85487f8b6..ccb513bbb6 100644 +--- a/src/sources/soundsourcepluginapi.h ++++ b/src/sources/soundsourcepluginapi.h +@@ -3,6 +3,7 @@ + + #define MIXXX_SOUNDSOURCEPLUGINAPI_VERSION 17 + // SoundSource Plugin API version history: ++// 18 - Mixxx 2.1.1 - Add log level parameters for plugin initialization + // 17 - Mixxx 2.1.0 - Bump version number after ABI breaking changes (lp1737815) + // 16 - Mixxx 2.1.0 - Support 2 different modes for opening files + // 15 - Mixxx 2.1.0 - AudioSource v2 +@@ -44,7 +45,7 @@ typedef int (*SoundSourcePluginAPI_getVersionFunc)(); + const char * const SoundSourcePluginAPI_getVersionFuncName = "Mixxx_SoundSourcePluginAPI_getVersion"; + + // extern "C" MIXXX_SOUNDSOURCEPLUGINAPI_EXPORT SoundSourceProvider* Mixxx_SoundSourcePluginAPI_createSoundSourceProvider() +-typedef SoundSourceProvider* (*SoundSourcePluginAPI_createSoundSourceProviderFunc)(); ++typedef SoundSourceProvider* (*SoundSourcePluginAPI_createSoundSourceProviderFunc)(int logLevel, int logFlushLevel); + const char* const SoundSourcePluginAPI_createSoundSourceProviderFuncName = "Mixxx_SoundSourcePluginAPI_createSoundSourceProvider"; + + // extern "C" MIXXX_SOUNDSOURCEPLUGINAPI_EXPORT void Mixxx_SoundSourcePluginAPI_destroySoundSourceProvider(mixxx::SoundSourceProvider*) +diff --git a/src/sources/soundsourcepluginlibrary.cpp b/src/sources/soundsourcepluginlibrary.cpp +index c0ab472710..c91551ed93 100644 +--- a/src/sources/soundsourcepluginlibrary.cpp ++++ b/src/sources/soundsourcepluginlibrary.cpp +@@ -91,7 +91,7 @@ bool SoundSourcePluginLibrary::init() { + } + + m_pSoundSourceProvider = SoundSourceProviderPointer( +- (*createSoundSourceProviderFunc)(), ++ (*createSoundSourceProviderFunc)(static_cast(g_logLevel), static_cast(g_logFlushLevel)), + destroySoundSourceProviderFunc); + if (m_pSoundSourceProvider) { + return true; +diff --git a/src/util/logging.cpp b/src/util/logging.cpp +index affd2c08b4..9c044a5b0c 100644 +--- a/src/util/logging.cpp ++++ b/src/util/logging.cpp +@@ -21,8 +21,8 @@ + namespace mixxx { + + // Initialize the log level with the default value +-LogLevel Logging::s_logLevel = kLogLevelDefault; +-LogLevel Logging::s_logFlushLevel = kLogFlushLevelDefault; ++LogLevel g_logLevel = kLogLevelDefault; ++LogLevel g_logFlushLevel = kLogFlushLevelDefault; + + namespace { + +@@ -189,8 +189,8 @@ void Logging::initialize(const QDir& settingsDir, + return; + } + +- s_logLevel = logLevel; +- s_logFlushLevel = logFlushLevel; ++ g_logLevel = logLevel; ++ g_logFlushLevel = logFlushLevel; + + QString logFileName; + +diff --git a/src/util/logging.h b/src/util/logging.h +index e55ac5fb99..306b0a13c6 100644 +--- a/src/util/logging.h ++++ b/src/util/logging.h +@@ -17,6 +17,13 @@ enum class LogLevel { + constexpr LogLevel kLogLevelDefault = LogLevel::Warning; + constexpr LogLevel kLogFlushLevelDefault = LogLevel::Critical; + ++// Almost constant, i.e. initialized once at startup ++// TODO(XXX): Remove this ugly "extern" hack after getting rid of ++// the broken plugin architecture. Both globals should (again) ++// become static members of the class Logging. ++extern LogLevel g_logLevel; ++extern LogLevel g_logFlushLevel; ++ + class Logging { + public: + // These are not thread safe. Only call them on Mixxx startup and shutdown. +@@ -29,10 +36,10 @@ class Logging { + static void flushLogFile(); + + static bool enabled(LogLevel logLevel) { +- return s_logLevel >= logLevel; ++ return g_logLevel >= logLevel; + } + static bool flushing(LogLevel logFlushLevel) { +- return s_logFlushLevel >= logFlushLevel; ++ return g_logFlushLevel >= logFlushLevel; + } + static bool traceEnabled() { + return enabled(LogLevel::Trace); +@@ -46,9 +53,6 @@ class Logging { + + private: + Logging() = delete; +- +- static LogLevel s_logLevel; +- static LogLevel s_logFlushLevel; + }; + + } // namespace mixxx + +From 3c9974b9fddb4c04f84ff0a6cb52df6a6fc82b23 Mon Sep 17 00:00:00 2001 +From: Uwe Klotz +Date: Sun, 3 Jun 2018 01:06:54 +0200 +Subject: [PATCH 6/6] Bump API version (now actually) + +--- + src/sources/soundsourcepluginapi.h | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/src/sources/soundsourcepluginapi.h b/src/sources/soundsourcepluginapi.h +index ccb513bbb6..5b6d9a97d4 100644 +--- a/src/sources/soundsourcepluginapi.h ++++ b/src/sources/soundsourcepluginapi.h +@@ -1,7 +1,7 @@ + #ifndef MIXXX_SOUNDSOURCEPLUGINAPI_H + #define MIXXX_SOUNDSOURCEPLUGINAPI_H + +-#define MIXXX_SOUNDSOURCEPLUGINAPI_VERSION 17 ++#define MIXXX_SOUNDSOURCEPLUGINAPI_VERSION 18 + // SoundSource Plugin API version history: + // 18 - Mixxx 2.1.1 - Add log level parameters for plugin initialization + // 17 - Mixxx 2.1.0 - Bump version number after ABI breaking changes (lp1737815) diff --git a/media-sound/mixxx/files/mixxx-2.1.0-library-improvements-for-all-skins-fix-lp1772202-in-tango.patch b/media-sound/mixxx/files/mixxx-2.1.0-library-improvements-for-all-skins-fix-lp1772202-in-tango.patch new file mode 100644 index 0000000..3ad2d67 --- /dev/null +++ b/media-sound/mixxx/files/mixxx-2.1.0-library-improvements-for-all-skins-fix-lp1772202-in-tango.patch @@ -0,0 +1,6336 @@ +From 43f33764db7ca6520cd9cbe67e8ccb2eb6c8fbb2 Mon Sep 17 00:00:00 2001 +From: ronso0 +Date: Mon, 21 May 2018 02:53:05 +0200 +Subject: [PATCH 01/45] Tango: improve Library sort buttons + +--- + res/skins/Tango/graphics/library_sort_down.svg | 42 ++++++++++++----- + .../Tango/graphics/library_sort_down_hover.svg | 37 --------------- + res/skins/Tango/graphics/library_sort_up.svg | 52 +++++++++++++++------- + res/skins/Tango/graphics/library_sort_up_hover.svg | 37 --------------- + res/skins/Tango/style.qss | 29 +++++++----- + 5 files changed, 87 insertions(+), 110 deletions(-) + delete mode 100644 res/skins/Tango/graphics/library_sort_down_hover.svg + delete mode 100644 res/skins/Tango/graphics/library_sort_up_hover.svg + +diff --git a/res/skins/Tango/graphics/library_sort_down.svg b/res/skins/Tango/graphics/library_sort_down.svg +index aab977383c..f60ad295e7 100644 +--- a/res/skins/Tango/graphics/library_sort_down.svg ++++ b/res/skins/Tango/graphics/library_sort_down.svg +@@ -1,17 +1,19 @@ + +- +- + ++ version="1.1" ++ viewBox="0 0 23.999998 14.83" ++ id="svg2" ++ inkscape:version="0.91 r13725" ++ sodipodi:docname="style_sort_down.svg"> + + +@@ -20,19 +22,39 @@ + image/svg+xml + +- + + + + ++ + ++ style="display:inline"> + ++ style="fill-opacity:1" /> + + +diff --git a/res/skins/Tango/graphics/library_sort_down_hover.svg b/res/skins/Tango/graphics/library_sort_down_hover.svg +deleted file mode 100644 +index 4dcd5a0aef..0000000000 +--- a/res/skins/Tango/graphics/library_sort_down_hover.svg ++++ /dev/null +@@ -1,37 +0,0 @@ +- +- +- +- +- +- +- +- image/svg+xml +- +- +- +- +- +- +- +- +- +- +diff --git a/res/skins/Tango/graphics/library_sort_up.svg b/res/skins/Tango/graphics/library_sort_up.svg +index 978557775a..e92f24780d 100644 +--- a/res/skins/Tango/graphics/library_sort_up.svg ++++ b/res/skins/Tango/graphics/library_sort_up.svg +@@ -1,38 +1,60 @@ + +- +- + ++ version="1.1" ++ viewBox="0 0 23.999998 14.83" ++ id="svg2" ++ inkscape:version="0.91 r13725" ++ sodipodi:docname="style_sort_up.svg"> + ++ id="metadata12"> + + + image/svg+xml + +- + + + + ++ id="defs10" /> ++ + ++ transform="translate(-315.44 -310.66)" ++ id="g4" ++ style="display:inline"> + ++ d="m315.44 322.66 2.83 2.83 9.17-9.17 9.17 9.17 2.83-2.83-12-12z" ++ fill="#FF7100" ++ id="path6" ++ style="fill-opacity:1" /> + + +diff --git a/res/skins/Tango/graphics/library_sort_up_hover.svg b/res/skins/Tango/graphics/library_sort_up_hover.svg +deleted file mode 100644 +index f07d0afc34..0000000000 +--- a/res/skins/Tango/graphics/library_sort_up_hover.svg ++++ /dev/null +@@ -1,37 +0,0 @@ +- +- +- +- +- +- +- +- image/svg+xml +- +- +- +- +- +- +- +- +- +- +diff --git a/res/skins/Tango/style.qss b/res/skins/Tango/style.qss +index 6d24ddaaee..8fb6d79729 100644 +--- a/res/skins/Tango/style.qss ++++ b/res/skins/Tango/style.qss +@@ -2106,20 +2106,27 @@ QHeaderView { + + QHeaderView::up-arrow, + QHeaderView::down-arrow { +- font-size: 10pt; +- } +- QHeaderView::up-arrow { +- image: url(skin:/graphics/library_sort_up.svg) +- } +- QHeaderView::up-arrow:hover { +- image: url(skin:/graphics/library_sort_up_hover.svg) +- } +- QHeaderView::down-arrow { +- image: url(skin:/graphics/library_sort_down.svg) ++ width: 12px; ++ padding-right: 2px; ++ border-right: 1px solid #585858; ++ background-color: #333; + } ++ QHeaderView::up-arrow:hover, + QHeaderView::down-arrow:hover { +- image: url(skin:/graphics/library_sort_down_hover.svg) ++ background-color: #585858; + } ++ QHeaderView::up-arrow { ++ image: url(skin:/graphics/library_sort_up.svg) ++ } ++ QHeaderView::up-arrow:hover { ++ image: url(skin:/graphics/library_sort_down.svg) ++ } ++ QHeaderView::down-arrow { ++ image: url(skin:/graphics/library_sort_down.svg) ++ } ++ QHeaderView::down-arrow:hover { ++ image: url(skin:/graphics/library_sort_up.svg) ++ } + + /* Scroll bars */ + QScrollBar:horizontal { + +From e58b2bbd463def2a31370c9efccb0a27cea2aa08 Mon Sep 17 00:00:00 2001 +From: ronso0 +Date: Mon, 21 May 2018 03:22:10 +0200 +Subject: [PATCH 02/45] Tango: fix height of effect slot > static size/position + even if an effect is cleared + +--- + res/skins/Tango/fx_parameter_row.xml | 2 +- + res/skins/Tango/fx_unit_right.xml | 1 + + 2 files changed, 2 insertions(+), 1 deletion(-) + +diff --git a/res/skins/Tango/fx_parameter_row.xml b/res/skins/Tango/fx_parameter_row.xml +index 1271e979ff..0b64a08ec9 100644 +--- a/res/skins/Tango/fx_parameter_row.xml ++++ b/res/skins/Tango/fx_parameter_row.xml +@@ -9,7 +9,7 @@ Variables passed through from fx_unit: + + FxParameters + horizontal +- min,max ++ min,47f + + +