chadnickbok / librtcdcpp

A simple WebRTC DataChannels library
BSD 3-Clause "New" or "Revised" License
158 stars 41 forks source link

No std::function errors #37

Closed ClosetGeek-Git closed 6 years ago

ClosetGeek-Git commented 6 years ago

I'm currently on my phone so I can't paste the exact errors but I received around 30 errors of type error: 'function' in namespace 'std' does not name a template type while building on Ubuntu 18 with GCC 7. After doing some searching I found that this may be an issue with newer versions of gcc/g++ (see https://bugzilla.redhat.com/show_bug.cgi?id=1417383). If anyone has experienced this I would appreciate knowing if I'm heading down the wrong path. Otherwise I will try manual adding #include <functional>when I get back to it.

ClosetGeek-Git commented 6 years ago

After a quick search here on GitHub I found the only file with #include <functional> is WebSocketWrapper.hpp

See `https://github.com/chadnickbok/librtcdcpp/search?utf8=✓&q="%23include+%3cfunctional%3e"&type=

mo3rfan commented 6 years ago

See: https://github.com/chadnickbok/librtcdcpp/pull/32

Just apply this patch: https://patch-diff.githubusercontent.com/raw/chadnickbok/librtcdcpp/pull/32.patch

Hope it fixes the problem.

ClosetGeek-Git commented 6 years ago

I'll check that out!

gegles commented 6 years ago

Thanks @mo3rfan, I've just merged #32.