From: Luis Lavena Date: 2007-12-24T00:15:00+09:00 Subject: Re: Problem building Ruby addon with Vista On 23 dic, 11:11, "Julian Harnath" wrote: > Hello! > > I'm currently looking into developing Ruby addons. I'd like to use Windows > Vista with VC++ 2005 as development platform. But I have a problem which > seems to be related to some DLL incompatibility. > My addon is currently empty, it only contains an empty init function. But > as soon as I try to use it I get the following error when trying to run it: > > "The procedure entry point "_except_handler4_common" could not be located > in > the dynamic link library MSVCR80.dll" > > Searching google for "_execpt_handler4_common" results in various pages > describing similiar problems (although none of them is related to Ruby). > It seems to be some internal execption handler function which is only > present in Vista. I suspect that the "msvcrt-ruby18.dll" which comes with > the Windows build of Ruby is incompatible with the libraries used by > Visual Studio 2005 (SP1) on Vista. > Yes, msvcrt-ruby18 is build with VC6, which link to MSVCRT.dll (version 6.0). to make Ruby MSVCR80.dll -compatible, you need to build ruby by yourself, also compiling all the ruby dependencies with it, since you can ran into cross-runtime malloc/free issues and random crashes. There are a few looong threads you can search on google groups about this (ruby-talk and ruby-core). > Does anyone have an idea how to fix this? Did anyone successfully compile > a Ruby addon with Vista, and if yes, how? There is a lot of manual hacking in rbconfig.rb to make it work. I suggest avoid it and use the path I described earlier, or just drop VC + 2005 and use MinGW. Regards, Luis Lavena