On Thu, 2018-06-21 at 17:35 +0200, Grégoire Jadi wrote:
> Kurt Miller <li...@intricatesoftware.com> writes:
> > > 
> > On Wed, 2018-06-20 at 16:25 +0200, Grégoire Jadi wrote:
> > 
> > > 
> > > Christian Weisgerber <na...@mips.inka.de> writes:
> > > Hello,
> > > 
> > > I may have encountered the same bug when I tried to build programs
> > > generated with devel/arduino. cc1 aborts with a coredump during the
> > > compilation.
> > I just committed a fix for devel/avr/gcc, please rebuild it from an
> > updated ports tree or wait for the next set of snapshot packages.
> > devel/simulavr and devel/arduino build fine now.
> Thanks! I'll try it when I can.
> > Regarding my patch to update devel/simulavr, should I submit it on a
> dedicated thread?
> 

Yes please. I just pitched in for the gcc bug and don't use devel/simulavr.

I did quickly look at the patches in your diff and noticed the one for
gdbserver.cpp:

--- /dev/null
+++ b/devel/simulavr/patches/patch-src_cmd_gdbserver_cpp
@@ -0,0 +1,147 @@
+$OpenBSD$
+
+Remove `using namespace std` directive because of a conflict between
+std::bind() and bind(2).
+
+Index: src/cmd/gdbserver.cpp
+--- src/cmd/gdbserver.cpp.orig
++++ src/cmd/gdbserver.cpp
+@@ -24,7 +24,6 @@
+  */
+ 
+ #include <iostream>
+-using namespace std;
+ 

Try leaving the using namespace std in and putting :: in front of
bind(2) to have it use the global namespace explicitly. It should
make for a much shorter patch and accomplish the same thing I believe.
( e.g. ::bind(sock, ...)

-Kurt

Reply via email to