Boost logo

Boost :

From: Max Fetz (maxfetz1_at_[hidden])
Date: 2021-01-19 12:52:17

   Hello Boost-Community I have asked the following question everywhere
   but nowhere has it been answered. I have now been advised to ask here.

   I really hope there is someone on this mail list who can help me.
   Unfortunately I don't have much time left and would be very grateful
   for an answer.

   With kind regards


   My Question:

   I'm using normal Boost.NumPy functions in C++ like ndarray::get_data(),
   and I get a "reference to unresolved external symbol" error. The .lib's
   are linked and I have no approach on how to solve the error.

   I am using Boost 1.74.

   Here is a Code example:


   using namespace boost;

   void func(python::object _obj)


       python::numpy::ndarray my_ndarray =

       char* data = my_ndarray.get_data();




       python::def("func", func);


   Thats the one of the unresolved symbols: ""__declspec(dllimport)
   public: char * __cdecl
   boost::python::numpy::ndarray::get_data(void)const "

   I am using the normal Visual Studio linker and this is my linker

   /OUT:"D:\OthelloGame_withAI\x64\Debug\ogwa_acc.pyd" /MANIFEST /NXCOMPAT

   /PDB:"D:\OthelloGame_withAI\x64\Debug\ogwa_acc.pdb" /DYNAMICBASE


   "boost_python38-vc142-mt-gd-x64-1_74.lib" "boost_python38-vc142-mt-x64-

   1_74.lib" "kernel32.lib" "user32.lib" "gdi32.lib" "winspool.lib"

   "advapi32.lib" "shell32.lib" "ole32.lib" "oleaut32.lib" "uuid.lib"

   "odbccp32.lib" /IMPLIB:"D:\OthelloGame_withAI\x64\Debug\ogwa_acc.lib"


   /PGD:"D:\OthelloGame_withAI\x64\Debug\ogwa_acc.pgd" /SUBSYSTEM:CONSOLE

   /MANIFESTUAC:"level='asInvoker' uiAccess='false'"


   /ERRORREPORT:PROMPT /NOLOGO /LIBPATH:"C:\Program Files\Python38\libs"


   D:\OthelloGame_withAI\Third-Party\boost_1_74_0\finished_libs is the
   location of:


   boost_python38-vc142-mt-gd-x64- 1_74.lib;



Boost list run by bdawes at, gregod at, cpdaniel at, john at