AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |
Back to Blog
Flat symbol9/22/2023 "/Users/$USER/opt/anaconda3/pkgs/python-3.9.12-hdfd78df_0/include/python3.9",Īdd_library(LIB_NAME STATIC src/BINDER_FILE.cpp) Include_directories("/Users/$USER/dictionary/pybind11/include", Set(CMAKE_CXX_FLAGS "-Wall -Wextra -fPIC") SET (CMAKE_C_COMPILER "/Library/Developer/CommandLineTools/usr/bin/clang") Here is my CMakeLists.txt file: cmake_minimum_required(VERSION 3.4.3.18) I have spent considerable time trying to fix this, but my knowledge of CMake and build systems is lacking. This is where I believe my issue is, but I am not entirely sure. I looked at the other answers that are related to my issue and none helped me as their CMake files weren't displayed. Everything builds fine and the package installs on a Python 3.8.9 virtual environment, but when I try to import I get: ImportError: dlopen(/Users/$USER/dictionary/py_test/venv/lib/python3.8/site-packages/, 0x0002): symbol not found in flat namespace '_P圜Method_New' I haven't worked with pybind11 until now so I watched a tutorial of a basic example and followed all the steps. I wrote a few classes in C++ that I want to package using pybind11. "symbol not found in flat namespace" error when importing pybind11 module
0 Comments
Read More
Leave a Reply. |