Package: clementine
Version: 1.2.3+dfsg-3
Severity: important
Tags: patch
User: ubuntu-de...@lists.ubuntu.com
Usertags: origin-ubuntu wily ubuntu-patch

Dear Maintainer,

The attached patch resolves the clementine FTBFS by wrapping boost includes in
a way that causes the buggy qt4 moc to ignore them.

*** /tmp/tmpgSMehO/bug_body

In Ubuntu, the attached patch was applied to achieve the following:

  * Wrap boost imports with '#ifndef Q_MOC_RUN // #endif' to avoid qt4 moc 
issues.


Thanks for considering the patch.


-- System Information:
Debian Release: jessie/sid
  APT prefers vivid-updates
  APT policy: (500, 'vivid-updates'), (500, 'vivid-security'), (500, 'vivid'), 
(100, 'vivid-backports')
Architecture: amd64 (x86_64)
Foreign Architectures: i386

Kernel: Linux 3.19.0-25-generic (SMP w/8 CPU cores)
Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Init: systemd (via /run/systemd/system)
diff -Nru clementine-1.2.3+dfsg/debian/changelog clementine-1.2.3+dfsg/debian/changelog
diff -Nru clementine-1.2.3+dfsg/debian/control clementine-1.2.3+dfsg/debian/control
--- clementine-1.2.3+dfsg/debian/control	2015-08-10 11:43:52.000000000 -0700
+++ clementine-1.2.3+dfsg/debian/control	2015-08-10 16:20:10.000000000 -0700
@@ -1,8 +1,7 @@
 Source: clementine
 Section: sound
 Priority: optional
-Maintainer: Ubuntu Developers <ubuntu-devel-disc...@lists.ubuntu.com>
-XSBC-Original-Maintainer: Thomas Pierson <cont...@thomaspierson.fr>
+Maintainer: Thomas Pierson <cont...@thomaspierson.fr>
 Build-Depends: cmake (>= 2.6),
                debhelper (>= 9),
                docbook-to-man,
diff -Nru clementine-1.2.3+dfsg/debian/patches/hide_boost_includes_from_q_moc.patch clementine-1.2.3+dfsg/debian/patches/hide_boost_includes_from_q_moc.patch
--- clementine-1.2.3+dfsg/debian/patches/hide_boost_includes_from_q_moc.patch	1969-12-31 16:00:00.000000000 -0800
+++ clementine-1.2.3+dfsg/debian/patches/hide_boost_includes_from_q_moc.patch	2015-08-10 15:25:37.000000000 -0700
@@ -0,0 +1,192 @@
+Description: Wrap boost includes to avoid FTBFS due to qt4 moc.
+Author: Robert Bruce Park <robert.p...@canonical.com>
+
+---
+The information above should follow the Patch Tagging Guidelines, please
+checkout http://dep.debian.net/deps/dep3/ to learn about the format. Here
+are templates for supplementary fields that you might want to add:
+
+Origin: <vendor|upstream|other>, <url of original patch>
+Bug: <url in upstream bugtracker>
+Bug-Debian: https://bugs.debian.org/<bugnumber>
+Bug-Ubuntu: https://launchpad.net/bugs/<bugnumber>
+Forwarded: <no|not-needed|url proving that it has been forwarded>
+Reviewed-By: <name and email of someone who approved the patch>
+Last-Update: <YYYY-MM-DD>
+
+--- clementine-1.2.3+dfsg.orig/src/core/boundfuturewatcher.h
++++ clementine-1.2.3+dfsg/src/core/boundfuturewatcher.h
+@@ -3,7 +3,9 @@
+ 
+ #include <QFutureWatcher>
+ 
++#ifndef Q_MOC_RUN
+ #include <boost/noncopyable.hpp>
++#endif
+ 
+ template <typename T, typename D>
+ class BoundFutureWatcher : public QFutureWatcher<T>, boost::noncopyable {
+--- clementine-1.2.3+dfsg.orig/src/core/database.cpp
++++ clementine-1.2.3+dfsg/src/core/database.cpp
+@@ -23,7 +23,9 @@
+ #include "core/logging.h"
+ #include "core/taskmanager.h"
+ 
++#ifndef Q_MOC_RUN
+ #include <boost/scope_exit.hpp>
++#endif
+ 
+ #include <QCoreApplication>
+ #include <QDir>
+--- clementine-1.2.3+dfsg.orig/src/core/macglobalshortcutbackend.mm
++++ clementine-1.2.3+dfsg/src/core/macglobalshortcutbackend.mm
+@@ -22,7 +22,9 @@
+ #include "mac_startup.h"
+ #import "mac_utilities.h"
+ 
++#ifndef Q_MOC_RUN
+ #include <boost/noncopyable.hpp>
++#endif
+ 
+ #include <QAction>
+ #include <QList>
+--- clementine-1.2.3+dfsg.orig/src/core/mergedproxymodel.h
++++ clementine-1.2.3+dfsg/src/core/mergedproxymodel.h
+@@ -25,10 +25,12 @@
+ using std::placeholders::_1;
+ using std::placeholders::_2;
+ 
++#ifndef Q_MOC_RUN
+ #include <boost/multi_index_container.hpp>
+ #include <boost/multi_index/member.hpp>
+ #include <boost/multi_index/ordered_index.hpp>
+ #include <boost/multi_index/hashed_index.hpp>
++#endif
+ 
+ using boost::multi_index::multi_index_container;
+ using boost::multi_index::indexed_by;
+--- clementine-1.2.3+dfsg.orig/src/core/scopedtransaction.h
++++ clementine-1.2.3+dfsg/src/core/scopedtransaction.h
+@@ -18,7 +18,9 @@
+ #ifndef SCOPEDTRANSACTION_H
+ #define SCOPEDTRANSACTION_H
+ 
++#ifndef Q_MOC_RUN
+ #include <boost/noncopyable.hpp>
++#endif
+ 
+ class QSqlDatabase;
+ 
+--- clementine-1.2.3+dfsg.orig/src/core/signalchecker.h
++++ clementine-1.2.3+dfsg/src/core/signalchecker.h
+@@ -20,8 +20,10 @@
+ 
+ #include <glib-object.h>
+ 
++#ifndef Q_MOC_RUN
+ #include <boost/function_types/function_arity.hpp>
+ #include <boost/typeof/typeof.hpp>
++#endif
+ 
+ // Do not call this directly, use CHECKED_GCONNECT instead.
+ bool CheckedGConnect(
+--- clementine-1.2.3+dfsg.orig/src/devices/macdevicelister.mm
++++ clementine-1.2.3+dfsg/src/devices/macdevicelister.mm
+@@ -38,7 +38,9 @@
+ #import <Foundation/NSString.h>
+ #import <Foundation/NSURL.h>
+ 
++#ifndef Q_MOC_RUN
+ #include <boost/scope_exit.hpp>
++#endif
+ 
+ #include <libmtp.h>
+ 
+--- clementine-1.2.3+dfsg.orig/src/library/groupbydialog.h
++++ clementine-1.2.3+dfsg/src/library/groupbydialog.h
+@@ -25,9 +25,11 @@
+ using std::placeholders::_1;
+ using std::placeholders::_2;
+ 
++#ifndef Q_MOC_RUN
+ #include <boost/multi_index_container.hpp>
+ #include <boost/multi_index/member.hpp>
+ #include <boost/multi_index/ordered_index.hpp>
++#endif
+ 
+ #include "librarymodel.h"
+ 
+--- clementine-1.2.3+dfsg.orig/tests/database_test.cpp
++++ clementine-1.2.3+dfsg/tests/database_test.cpp
+@@ -20,7 +20,9 @@
+ 
+ #include "core/database.h"
+ 
++#ifndef Q_MOC_RUN
+ #include <boost/scoped_ptr.hpp>
++#endif
+ 
+ #include <QtDebug>
+ #include <QSqlQuery>
+--- clementine-1.2.3+dfsg.orig/tests/librarybackend_test.cpp
++++ clementine-1.2.3+dfsg/tests/librarybackend_test.cpp
+@@ -23,7 +23,9 @@
+ #include "core/song.h"
+ #include "core/database.h"
+ 
++#ifndef Q_MOC_RUN
+ #include <boost/scoped_ptr.hpp>
++#endif
+ 
+ #include <QFileInfo>
+ #include <QSignalSpy>
+--- clementine-1.2.3+dfsg.orig/tests/plsparser_test.cpp
++++ clementine-1.2.3+dfsg/tests/plsparser_test.cpp
+@@ -27,7 +27,9 @@
+ #include <QUrl>
+ #include <QtDebug>
+ 
++#ifndef Q_MOC_RUN
+ #include <boost/shared_ptr.hpp>
++#endif
+ 
+ using boost::shared_ptr;
+ 
+--- clementine-1.2.3+dfsg.orig/tests/songloader_test.cpp
++++ clementine-1.2.3+dfsg/tests/songloader_test.cpp
+@@ -29,7 +29,10 @@
+ #include <QSignalSpy>
+ #include <QtDebug>
+ 
++#ifndef Q_MOC_RUN
+ #include <boost/scoped_ptr.hpp>
++#endif
++
+ #include <cstdlib>
+ 
+ using ::testing::_;
+--- clementine-1.2.3+dfsg.orig/tests/songplaylistitem_test.cpp
++++ clementine-1.2.3+dfsg/tests/songplaylistitem_test.cpp
+@@ -19,7 +19,10 @@
+ #include "test_utils.h"
+ 
+ #include <gtest/gtest.h>
++
++#ifndef Q_MOC_RUN
+ #include <boost/scoped_ptr.hpp>
++#endif
+ 
+ #include <QTemporaryFile>
+ #include <QFileInfo>
+--- clementine-1.2.3+dfsg.orig/tests/utilities_test.cpp
++++ clementine-1.2.3+dfsg/tests/utilities_test.cpp
+@@ -21,7 +21,9 @@
+ 
+ #include "core/utilities.h"
+ 
++#ifndef Q_MOC_RUN
+ #include <boost/scoped_ptr.hpp>
++#endif
+ 
+ #include <QtDebug>
+ 
diff -Nru clementine-1.2.3+dfsg/debian/patches/series clementine-1.2.3+dfsg/debian/patches/series
--- clementine-1.2.3+dfsg/debian/patches/series	2015-07-05 12:40:36.000000000 -0700
+++ clementine-1.2.3+dfsg/debian/patches/series	2015-08-10 15:27:14.000000000 -0700
@@ -5,3 +5,4 @@
 fix_gcc5_ftbfs.patch
 remove-references-to-non-dfsg-files.patch
 freebsd_isnt_kfreebsd.patch
+hide_boost_includes_from_q_moc.patch

Reply via email to