Compile debug packages on windows

M

mg

First, I compiled Python in DEBUG on Win32 with MSCV.net and the
solution distributed in the Python packages.
Second, I try to compiled NUMARRAY with my python debug :

python_d setup.py build

And the compilation crash with the following message : the file
python25.lib does not exist (it is normal, because only python25_d.lib
exist !)

I opened the source file which include Python.h, which include
pyconfig.h.located in the directory PC. Then, I found this :

#ifdef MS_COREDLL
# ifndef Py_BUILD_CORE /* not building the core - must be an ext */
# if defined(_MSC_VER) /* So MSVC users need not specify
the .lib file in their Makefile (other compilers are generally taken
care of by distutils.) */
# ifdef _DEBUG
# pragma comment(lib,"python25_d.lib")
# else
# pragma comment(lib,"python25.lib")
# endif /* _DEBUG */
# endif /* _MSC_VER */
# endif /* Py_BUILD_CORE */
#endif /* MS_COREDLL */

Then, the symbol _DEBUG need to be define... (I added at the beginning
of the file: it seems to be the solution) to import the debug version
instead of the release version.

But, how can I run the compilation (options on the comand line maybe)
which use the python25_d.lib, i.e. how the symbol _DEBUG can be defined
when I write 'python_d setup.py build' ? In other words, with a Python
in debug, I would generate packages in debug too and propagate the debug
mode from Python to the packages...

Thanks
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,778
Messages
2,569,605
Members
45,238
Latest member
Top CryptoPodcasts

Latest Threads

Top