Code::Blocks

User forums => Help => Topic started by: grv575 on August 08, 2005, 03:26:01 am

Title: dllwrap.exe problem
Post by: grv575 on August 08, 2005, 03:26:01 am
This applies only to rc1 and not the newer rc1-1 unless you install rc1-1 over rc1 instead of downloading mingw32 seperately.  So using the codeblocks mingw32 compiler (c:\program files\codeblocks\bin) to compile python modules gives for the link step:

C:\Program Files\CodeBlocks\bin\dllwrap.exe -mno-cygwin -mdll -static --entry [email protected] --output-lib build\temp.win32-2.4\Release\c_code\libc_file.a --def build\temp.win32-2.4\Release\c_code\c_file.def -s build\temp.win32-2.4\Release\c_code\c_file.o build\temp.win32-2.4\Release\c_code\c_utility.o build\temp.win32-2.4\Release\c_code\c_debug.o -L/usr/local/lib -LC:\Python24\libs -LC:\Python24\PCBuild -lpython24 -lmsvcr71 -o build\lib.win32-2.4\c_code\c_file.pyd -s

Using c:\dev-cpp or c:\mingw32 gives:

c:\Dev-Cpp\bin\gcc.exe -mno-cygwin -shared -s build\temp.win32-2.4\Release\c_code\c_file.o build\temp.win32-2.4\Release\c_code\c_utility.o build\temp.win32-2.4\Release\c_code\c_debug.o build\temp.win32-2.4\Release\c_code\c_file.def -L/usr/local/lib -LC:\Python24\libs -LC:\Python24\PCBuild -lpython24 -lmsvcr71 -o build\lib.win32-2.4\c_code\c_file.pyd -s

which works correctly.  The codeblocks dllwrap.exe command errors out complaining it cannot find an import __Py_IOError or something, but it's not important (import in python24.dll).  If I remove the -mdll -static flags from the dllimport.exe command it goes ok.  Not sure why the standalone mingw32 and devcpp both call gcc.exe to do the dllwrap invocation while the codeblocks one seems to call dllwrap directly (and incorrectly on windows as far as I can tell).
Title: Re: dllwrap.exe problem
Post by: mandrav on August 18, 2005, 08:33:25 pm
C::B doesn't use dllwrap.exe by itself. Instead it uses "gcc -shared".
You 'd have to tell us more on how you configured C::B and how you created your project...

Yiannis.
Title: Re: dllwrap.exe problem
Post by: grv575 on August 19, 2005, 06:19:50 am
It's a python 2.4 modutils project (C modules called by python scripts).  The setup.py compilation script tells modutils how to compile (-O flags, libs, etc), but I guess python handles the actual gcc, etc calls.  Couldn't figure out why the bundled mingw behaved differently than a seperate mingw installation.

But it's not a bit deal.  It would be good to figure out how to make installing a seperate mingw compiler more convenient though (right now, it's a matter of matching up the ming source code links version numbers with the same binary packages on the mingw download page and extracting 7-8 of these packages to a directory).