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

Does not build on Mac M1 Silicon #617

Open
timseed opened this issue Sep 8, 2023 · 1 comment
Open

Does not build on Mac M1 Silicon #617

timseed opened this issue Sep 8, 2023 · 1 comment

Comments

@timseed
Copy link

timseed commented Sep 8, 2023

No problem with the cmake ...

It seems to have (eventually) found the correct package

-- CMake libzmq package not found, trying again with pkg-config (normal install of zeromq)
-- Found PkgConfig: /opt/homebrew/bin/pkg-config (found version "0.29.2")
-- Found ZeroMQ: /opt/homebrew/lib/libzmq.dylib
-- cppzmq v4.10.0
-- Performing Test CMAKE_HAVE_LIBC_PTHREAD
-- Performing Test CMAKE_HAVE_LIBC_PTHREAD - Success

But in the final linking step ...

[  7%] Linking CXX executable unit_tests
Undefined symbols for architecture arm64:
  "_zmq_msg_group", referenced from:
      zmq::message_t::group() const in message.cpp.o
  "_zmq_msg_routing_id", referenced from:
      zmq::message_t::routing_id() const in message.cpp.o
  "_zmq_msg_set_group", referenced from:
      zmq::message_t::set_group(char const*) in message.cpp.o
  "_zmq_msg_set_routing_id", referenced from:
      zmq::message_t::set_routing_id(unsigned int) in message.cpp.o
  "_zmq_poller_add", referenced from:
      zmq::poller_t<zmq::no_user_data>::add_impl(zmq::socket_ref, zmq::event_flags, zmq::no_user_data*) in poller.cpp.o
      zmq::poller_t<void>::add_impl(zmq::socket_ref, zmq::event_flags, void*) in poller.cpp.o
      zmq::poller_t<int>::add_impl(zmq::socket_ref, zmq::event_flags, int*) in poller.cpp.o
      zmq::poller_t<zmq::socket_t>::add_impl(zmq::socket_ref, zmq::event_flags, zmq::socket_t*) in poller.cpp.o
      zmq::poller_t<std::__1::function<void (zmq::event_flags)>>::add_impl(zmq::socket_ref, zmq::event_flags, std::__1::function<void (zmq::event_flags)>*) in active_poller.cpp.o
  "_zmq_poller_add_fd", referenced from:
      zmq::poller_t<std::__1::function<void (zmq::event_flags)>>::add_impl(int, zmq::event_flags, std::__1::function<void (zmq::event_flags)>*) in active_poller.cpp.o
  "_zmq_poller_destroy", referenced from:
      zmq::poller_t<zmq::no_user_data>::destroy_poller_t::operator()(void*) in poller.cpp.o
      zmq::poller_t<void>::destroy_poller_t::operator()(void*) in poller.cpp.o
      zmq::poller_t<int>::destroy_poller_t::operator()(void*) in poller.cpp.o
      zmq::poller_t<zmq::socket_t>::destroy_poller_t::operator()(void*) in poller.cpp.o
      zmq::poller_t<std::__1::function<void (zmq::event_flags)>>::destroy_poller_t::operator()(void*) in active_poller.cpp.o
  "_zmq_poller_modify", referenced from:
      zmq::poller_t<zmq::no_user_data>::modify(zmq::socket_ref, zmq::event_flags) in poller.cpp.o
      zmq::poller_t<zmq::socket_t>::modify(zmq::socket_ref, zmq::event_flags) in poller.cpp.o
      zmq::poller_t<std::__1::function<void (zmq::event_flags)>>::modify(zmq::socket_ref, zmq::event_flags) in active_poller.cpp.o
  "_zmq_poller_new", referenced from:
      zmq::poller_t<zmq::no_user_data>::poller_t() in poller.cpp.o
      zmq::poller_t<void>::poller_t() in poller.cpp.o
      zmq::poller_t<int>::poller_t() in poller.cpp.o
      zmq::poller_t<zmq::socket_t>::poller_t() in poller.cpp.o
      zmq::poller_t<std::__1::function<void (zmq::event_flags)>>::poller_t() in active_poller.cpp.o
  "_zmq_poller_remove", referenced from:
      zmq::poller_t<zmq::no_user_data>::remove(zmq::socket_ref) in poller.cpp.o
      zmq::poller_t<int>::remove(zmq::socket_ref) in poller.cpp.o
      zmq::poller_t<std::__1::function<void (zmq::event_flags)>>::remove(zmq::socket_ref) in active_poller.cpp.o
  "_zmq_poller_remove_fd", referenced from:
      zmq::poller_t<std::__1::function<void (zmq::event_flags)>>::remove(int) in active_poller.cpp.o
  "_zmq_poller_size", referenced from:
      zmq::poller_t<zmq::no_user_data>::size() const in poller.cpp.o
  "_zmq_poller_wait_all", referenced from:
      zmq::poller_t<zmq::no_user_data>::wait_all(std::__1::vector<zmq::poller_event<zmq::no_user_data>, std::__1::allocator<zmq::poller_event<zmq::no_user_data>>>&, std::__1::chrono::duration<long long, std::__1::ratio<1l, 1000l>>) in poller.cpp.o
      zmq::poller_t<int>::wait_all(std::__1::vector<zmq::poller_event<int>, std::__1::allocator<zmq::poller_event<int>>>&, std::__1::chrono::duration<long long, std::__1::ratio<1l, 1000l>>) in poller.cpp.o
      zmq::poller_t<zmq::socket_t>::wait_all(std::__1::vector<zmq::poller_event<zmq::socket_t>, std::__1::allocator<zmq::poller_event<zmq::socket_t>>>&, std::__1::chrono::duration<long long, std::__1::ratio<1l, 1000l>>) in poller.cpp.o
      zmq::poller_t<std::__1::function<void (zmq::event_flags)>>::wait_all(std::__1::vector<zmq::poller_event<std::__1::function<void (zmq::event_flags)>>, std::__1::allocator<zmq::poller_event<std::__1::function<void (zmq::event_flags)>>>>&, std::__1::chrono::duration<long long, std::__1::ratio<1l, 1000l>>) in active_poller.cpp.o
ld: symbol(s) not found for architecture arm64
@gummif
Copy link
Member

gummif commented Sep 8, 2023

You probably have drafts enabled in cppzmq but not in libzmq, try disabling that feature.

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

2 participants