Giter Site home page Giter Site logo

Comments (3)

knmcguire avatar knmcguire commented on June 28, 2024

sorry for the late reply... I guess this is still an issue for you currently right?

Probably not immediately something to worry about I would say. @whoenig is more acquinted with python binding though.

from crazyflie-link-cpp.

ntamas avatar ntamas commented on June 28, 2024

Yes, it's still an issue with the latest master, although the messages are a bit different now:

ld: warning: direct access in function 'pybind11_init_cflinkcpp(pybind11::module_&)' from file 'CMakeFiles/cflinkcpp.dir/src/python_bindings.cpp.o' to global weak symbol 'bitcraze::crazyflieLinkCpp::Packet::valid() const' from file 'libcrazyflieLinkCpp.a(Connection.cpp.o)' means the weak symbol cannot be overridden at runtime. This was likely caused by different translation units being compiled with different visibility settings.
ld: warning: direct access in function 'pybind11_init_cflinkcpp(pybind11::module_&)' from file 'CMakeFiles/cflinkcpp.dir/src/python_bindings.cpp.o' to global weak symbol 'bitcraze::crazyflieLinkCpp::Packet::valid() const' from file 'libcrazyflieLinkCpp.a(Connection.cpp.o)' means the weak symbol cannot be overridden at runtime. This was likely caused by different translation units being compiled with different visibility settings.
ld: warning: direct access in function 'pybind11_init_cflinkcpp(pybind11::module_&)' from file 'CMakeFiles/cflinkcpp.dir/src/python_bindings.cpp.o' to global weak symbol 'bitcraze::crazyflieLinkCpp::Packet::port() const' from file 'libcrazyflieLinkCpp.a(Connection.cpp.o)' means the weak symbol cannot be overridden at runtime. This was likely caused by different translation units being compiled with different visibility settings.
ld: warning: direct access in function 'pybind11_init_cflinkcpp(pybind11::module_&)' from file 'CMakeFiles/cflinkcpp.dir/src/python_bindings.cpp.o' to global weak symbol 'bitcraze::crazyflieLinkCpp::Packet::port() const' from file 'libcrazyflieLinkCpp.a(Connection.cpp.o)' means the weak symbol cannot be overridden at runtime. This was likely caused by different translation units being compiled with different visibility settings.
ld: warning: direct access in function 'unsigned long std::__1::__str_rfind<char, unsigned long, std::__1::char_traits<char>, 18446744073709551615ul>(char const*, unsigned long, char const*, unsigned long, unsigned long)' from file 'CMakeFiles/cflinkcpp.dir/src/python_bindings.cpp.o' to global weak symbol 'std::__1::char_traits<char>::eq(char, char)' from file 'libcrazyflieLinkCpp.a(Connection.cpp.o)' means the weak symbol cannot be overridden at runtime. This was likely caused by different translation units being compiled with different visibility settings.
ld: warning: direct access in function 'unsigned long std::__1::__str_rfind<char, unsigned long, std::__1::char_traits<char>, 18446744073709551615ul>(char const*, unsigned long, char const*, unsigned long, unsigned long)' from file 'CMakeFiles/cflinkcpp.dir/src/python_bindings.cpp.o' to global weak symbol 'std::__1::char_traits<char>::eq(char, char)' from file 'libcrazyflieLinkCpp.a(Connection.cpp.o)' means the weak symbol cannot be overridden at runtime. This was likely caused by different translation units being compiled with different visibility settings.

Furthermore, I needed to patch CMakeLists.txt to build on macOS:

diff --git a/CMakeLists.txt b/CMakeLists.txt
index d2f972c..a543583 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -75,8 +75,8 @@ add_library(crazyflieLinkCpp

 # Apple macOS libraries
 if (APPLE)
-  set(CMAKE_EXE_LINKER_FLAGS "-lobjc -framework IOKit -framework CoreFoundation")
-  set(CMAKE_MODULE_LINKER_FLAGS "-lobjc -framework IOKit -framework CoreFoundation")
+  set(CMAKE_EXE_LINKER_FLAGS "-lobjc -framework IOKit -framework CoreFoundation -framework Security")
+  set(CMAKE_MODULE_LINKER_FLAGS "-lobjc -framework IOKit -framework CoreFoundation -framework Security")
 endif()

 # Link pthread on Linux and Mac only

Required linker flags were taken from the pkg-config configuration file from libusb:

Libs.private:  -lobjc -Wl,-framework,IOKit -Wl,-framework,CoreFoundation -Wl,-framework,Security

from crazyflie-link-cpp.

ntamas avatar ntamas commented on June 28, 2024

CMakeLists.txt patch as outlined in the previous comment is not necessary any more now that 2095781 was committed.

The original warnings are still there, but indeed they don't seem to cause any problems.

from crazyflie-link-cpp.

Related Issues (14)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.