From: Martin Stannard Date: 2002-01-10T21:33:56+09:00 Subject: Re: Fixing RUDL C extension and Ruby for Visual C Hello Danny, Thursday, January 10, 2002, 11:03:06 PM, you wrote: DvB> Hello all, DvB> A few days ago I've tried to get my extension library to work with Visual DvB> C (on win98). Here are a few things that went wrong: .... DvB> ... the results can be found on http://rudl.froukepc.dhs.org/ including DvB> the VC Ruby 1.6.6 build and a log of what I did to compile everything. DvB> Danny I built RUDL a couple of months ago with Ruby1.6.5 on win2k with vc6.0. It works really well. If anyone wants to have a play around with the SDL library I'd recommend RUDL - it's lot's of fun. Here's a transcript of the build process: ############################################# E:\otherscode\ruby\thirdparty\rudl-0.5.1>vcvars32.bat Setting environment for using Microsoft Visual C++ tools. E:\otherscode\ruby\thirdparty\rudl-0.5.1>ruby extconf.rb checking for main() in -lpthread... yes checking for Mix_OpenAudio() in -lSDL_mixer... yes checking for SDL_mixer.h... yes checking for IMG_Load() in -lSDL_image... yes checking for SDL_image.h... yes checking for FT_Init_FreeType() in -lfreetype... yes checking for TTF_Init() in -lSDL_ttf... yes checking for SDL_ttf.h... yes checking for SDL_Quit() in -lSDL... yes checking for main() in -lSDLmain... yes checking for SDL.h... yes creating Makefile E:\otherscode\ruby\thirdparty\rudl-0.5.1>nmake Microsoft (R) Program Maintenance Utility Version 6.00.8168.0 Copyright (C) Microsoft Corp 1988-1998. All rights reserved. cl -DIMPORT -nologo -DNT=1 -Zi -MD -O2b2x -G5 -I. -Id:/rubywin32/lib/ruby/1.6/i586-mswin32 -I. -Id:/rubywin32/include -DHAVE_SDL_MIXER_H -DHAVE_SDL_ IMAGE_H -DHAVE_SDL_TTF_H -DHAVE_SDL_H -c rudl.c rudl.c ########## Snipped out lots of warnings and build info.... ########## cl -DIMPORT -nologo -DNT=1 -Zi -MD -O2b2x -G5 -Id:/rubywin32/lib/ruby/1.6/i586-mswin32 -I. -Id:/rubywin32/include -DHAVE_SDL_MIXER_H -DHAVE_SDL_IMAG E_H -DHAVE_SDL_TTF_H -DHAVE_SDL_H -c SDLMappy.cpp SDLMappy.cpp set LIB=d:\rubywin32\lib;D:\MICROS~1\VC98\LIB;D:\MICROS~1\VC98\MFC\LIB;D:\Microsoft Visual Studio\VC98\lib cl -LD -DIMPORT -nologo -DNT=1 -Zi -MD -O2b2x -G5 -o RUDL.so rudl.obj rudl_audio.obj rudl_cdrom.obj rudl_events.obj rudl_joystick.obj rudl_keyboard. obj rudl_mouse.obj rudl_rect.obj rudl_sfont.obj rudl_timer.obj rudl_ttf.obj rudl_video.obj SDL_gfxPrimitives.obj SDL_rotozoom.obj SFont.obj rudl_mappy.obj S DLMappy.obj mswin32-ruby16.lib SDLmain.lib SDL.lib SDL_ttf.lib freetype.lib SDL_image.lib SDL_mixer.lib pthread.lib -link /INCREMENTAL:no /EXPORT:Init_RUDL Creating library RUDL.lib and object RUDL.exp E:\otherscode\ruby\thirdparty\rudl-0.5.1>nmake install Microsoft (R) Program Maintenance Utility Version 6.00.8168.0 Copyright (C) Microsoft Corp 1988-1998. All rights reserved. RUDL.so -> d:/rubywin32/lib/ruby/1.6/i586-mswin32/RUDL.so chmod 0555 d:/rubywin32/lib/ruby/1.6/i586-mswin32/RUDL.so E:\otherscode\ruby\thirdparty\rudl-0.5.1> ##################################################### I've got the following libs in the rudl dir: freetype.lib pthread.lib SDL.lib SDLmain.lib SDL_image.lib SDL_mixer.lib SDL_ttf.lib SGE.lib -- Best regards, Martin mailto:martin@optushome.com.au