Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ArchLinux build error - field has incomplete type ‘std::atomic<bool>’ #10

Open
miko opened this issue Sep 22, 2021 · 0 comments
Open

Comments

@miko
Copy link

miko commented Sep 22, 2021

I get build error for v0.17:

$ make
[  3%] Building CXX object src/CMakeFiles/harmonySEQ.dir/Action.cpp.o
In file included from /tmp/harmonySEQ-0.17/src/Action.cpp:24:
/tmp/harmonySEQ-0.17/src/Engine.hpp:164:23: error: field ‘running’ has incomplete type ‘std::atomic<bool>’
  164 |     std::atomic<bool> running;
      |                       ^~~~~~~
In file included from /usr/include/c++/11.1.0/bits/shared_ptr_atomic.h:33,
                 from /usr/include/c++/11.1.0/memory:78,
                 from /tmp/harmonySEQ-0.17/src/Action.hpp:24,
                 from /tmp/harmonySEQ-0.17/src/Action.cpp:20:
/usr/include/c++/11.1.0/bits/atomic_base.h:155:12: note: declaration of ‘struct std::atomic<bool>’
  155 |     struct atomic;
      |            ^~~~~~
In file included from /tmp/harmonySEQ-0.17/src/Action.cpp:24:

The fix for above would be:

diff -Nur harmonySEQ-0.17/src/Engine.hpp harmonySEQ-0.17.new/src/Engine.hpp
--- harmonySEQ-0.17src/Engine.hpp	2020-03-04 14:48:23.000000000 +0100
+++ harmonySEQ-0.17.new/src/Engine.hpp	2021-09-22 09:50:36.781589576 +0200
@@ -22,6 +22,8 @@
 #ifndef MIDIDRIVER_H
 #define	MIDIDRIVER_H
 
+#include <atomic>
+#include <deque>
 #include <boost/signals2.hpp>
 namespace bs2 = boost::signals2;
 
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant