Re: [SyncEvolution] Build failure with gcc 6

2016-07-06 Thread Justus-bulk
Tino Mettler  wrote on Wed, 6 Jul
2016 15:07:48 +0200:

> On Wed, Jul 06, 2016 at 14:42:08 +0200, Patrick Ohly wrote:
>> 
>> Isn't it possible to compile when asking explicitly for an older C++
>> version than the one used by g++ by default?

It is; in particular, it makes the following compile successfully:

> src/syncevo/Cmdline.cpp:1734:85: error: no matching function for call
> to 'bind(, const
> boost::reference_wrapper> >, boost::arg<1>&)'

Siehe auch https://aur.archlinux.org/packages/syncevolution and its
PKGBUILD.

Justus
___
SyncEvolution mailing list
SyncEvolution@syncevolution.org
https://lists.syncevolution.org/mailman/listinfo/syncevolution


Re: [SyncEvolution] Build failure with gcc 6

2016-07-06 Thread Tino Mettler
On Wed, Jul 06, 2016 at 14:42:08 +0200, Patrick Ohly wrote:
> On Wed, 2016-07-06 at 14:27 +0200, Tino Mettler wrote:
> > Hi Patrick,
> > 
> > 1.5.1 fails to build with GCC 6 [1], which makes it unsuitable for
> > Debian testing in the current state.  From looking at the
> > freedesktop.org git web interface, I don't see any branches with newer
> > code that was fixed regarding this issue.  Do you have any plans for
> > this?
> 
> Isn't it possible to compile when asking explicitly for an older C++
> version than the one used by g++ by default?

I'll check.

> I was aware of the need for changes to compile with default options, but
> haven't had time for that yet.

After fixing up some implicit shared_ptr-to-bool conversions (see the
attached patch), this one is left:

src/syncevo/Cmdline.cpp:1734:85: error: no matching function for call to 
'bind(, const 
boost::reference_wrapper 
>, boost::arg<1>&)'

Regards,
Tino
>From 78e57294e2e7da741c47f31ba6c17b7fb6219c87 Mon Sep 17 00:00:00 2001
From: Tino Mettler 
Date: Wed, 6 Jul 2016 14:33:19 +0200
Subject: [PATCH] Fix implicit shared_ptr conversions

---
 src/dbus/server/session.h| 2 +-
 src/syncevo/Logging.h| 4 ++--
 src/syncevo/StringDataBlob.h | 2 +-
 3 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/src/dbus/server/session.h b/src/dbus/server/session.h
index af46f5d..b762bab 100644
--- a/src/dbus/server/session.h
+++ b/src/dbus/server/session.h
@@ -425,7 +425,7 @@ public:
 void setServerAlerted(bool serverAlerted) { m_serverAlerted = serverAlerted; }
 
 void initServer(SharedBuffer data, const std::string );
-void setStubConnection(const boost::shared_ptr c) { m_connection = c; m_useConnection = c; }
+void setStubConnection(const boost::shared_ptr c) { m_connection = c; m_useConnection = static_cast (c); }
 boost::weak_ptr getStubConnection() { return m_connection; }
 bool useStubConnection() { return m_useConnection; }
 
diff --git a/src/syncevo/Logging.h b/src/syncevo/Logging.h
index ce9a249..5deb01b 100644
--- a/src/syncevo/Logging.h
+++ b/src/syncevo/Logging.h
@@ -255,7 +255,7 @@ class Logger
 Handle  = (const Handle ) throw ();
 ~Handle() throw ();
 
-operator bool () const { return m_logger; }
+operator bool () const { return static_cast (m_logger); }
 bool operator == (Logger *logger) const { return m_logger.get() == logger; }
 Logger *get() const { return m_logger.get(); }
 
@@ -398,7 +398,7 @@ template class PushLogger : boost::noncopyable
 }
 }
 
-operator bool () const { return m_logger; }
+operator bool () const { return static_cast (m_logger); }
 
 void reset(const Logger::Handle )
 {
diff --git a/src/syncevo/StringDataBlob.h b/src/syncevo/StringDataBlob.h
index 62bc4c7..14f0d61 100644
--- a/src/syncevo/StringDataBlob.h
+++ b/src/syncevo/StringDataBlob.h
@@ -53,7 +53,7 @@ class StringDataBlob : public DataBlob
 
 virtual boost::shared_ptr getData() { return m_data; }
 virtual std::string getName() const { return m_name; }
-virtual bool exists() const { return m_data; }
+virtual bool exists() const { return static_cast (m_data); }
 virtual bool isReadonly() const { return m_readonly; }
 };
 
___
SyncEvolution mailing list
SyncEvolution@syncevolution.org
https://lists.syncevolution.org/mailman/listinfo/syncevolution

Re: [SyncEvolution] Build failure with gcc 6

2016-07-06 Thread Patrick Ohly
On Wed, 2016-07-06 at 14:27 +0200, Tino Mettler wrote:
> Hi Patrick,
> 
> 1.5.1 fails to build with GCC 6 [1], which makes it unsuitable for
> Debian testing in the current state.  From looking at the
> freedesktop.org git web interface, I don't see any branches with newer
> code that was fixed regarding this issue.  Do you have any plans for
> this?

Isn't it possible to compile when asking explicitly for an older C++
version than the one used by g++ by default?

I was aware of the need for changes to compile with default options, but
haven't had time for that yet.

-- 
Best Regards, Patrick Ohly

The content of this message is my personal opinion only and although
I am an employee of Intel, the statements I make here in no way
represent Intel's position on the issue, nor am I authorized to speak
on behalf of Intel on this matter.



___
SyncEvolution mailing list
SyncEvolution@syncevolution.org
https://lists.syncevolution.org/mailman/listinfo/syncevolution


[SyncEvolution] Build failure with gcc 6

2016-07-06 Thread Tino Mettler
Hi Patrick,

1.5.1 fails to build with GCC 6 [1], which makes it unsuitable for
Debian testing in the current state.  From looking at the
freedesktop.org git web interface, I don't see any branches with newer
code that was fixed regarding this issue.  Do you have any plans for
this?

Regards,
Tino

[1] https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=811624
___
SyncEvolution mailing list
SyncEvolution@syncevolution.org
https://lists.syncevolution.org/mailman/listinfo/syncevolution