I want to use some Python code in my C ++ platform to build some statistics. I already found the following publication (on how to embed python in C ++), but following the instructions did not succeed: Embed python code in C ++ (Windows + minGW + Python 2.7.2 + Eclipse)
#include "Python.h" int main(int f_argc, const char* f_argv []) { Py_Initialize(); const char* pythonScript = "print 'Hello, world!'\n"; int result = PyRun_SimpleString(pythonScript); Py_Finalize(); return 0; }
I'm sorry, but I do not have much experience with make files or adding static or dynamic libraries ....
I have to follow the following system: Windows 7 + 64 bit + Eclipse IDE for C / C ++ developers, version: Juno Service Release 1 + mingw + python32
by path and symbols: + python32 directory is added + python32 library is added, which should correspond to libpython32.a + library path is added
Compiling and binding seem to work, but when I try to run exe, I get the following message:
"The program cannot start because the python32.dll file is missing on your computer. Try reinstalling the program to fix this problem."
I cannot understand this message because I am trying to add a static library to the source (libpython32.a). Could you give me a soft push in the right direction?
Many thanks for your help!
EDIT: added makefile and objects.mk
MAKEFILE ##################################################### # ################################ # Automatically generated files. Do not change! ####################################################### #################################
-include ../makefile.init RM := rm -rf
OBJECTS.MK