Hello

Thanks, i successful compile .c file, but i get linker error:

D:\tstruby>D:\ruby-1.6.7-mswin\bin\ruby extconf.rb
creating Makefile

D:\tstruby>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 -O2b2xg- -G5 -I. -I. -ID:/ruby-1.6.7-
mswin/lib/ruby/1.6/i586-mswin32 -I. -ID:/ruby-1.6.7-mswin/include -c
tstruby.c
tstruby.c
        set LIB=D:\ruby-1.6.7-mswin\lib;D:\Microsoft Visual Studio
.NET\Framewor
kSDK\Lib\;d:\DevStudio\mfc\lib;d:\DevStudio\lib
        cl -LD -DIMPORT -nologo -DNT=1 -Zi -MD -O2b2xg- -G5 -Fetstruby.so
tstrub
y.obj tstruby.obj mswin32-ruby16.lib -link /INCREMENTAL:no
/EXPORT:Init_tstruby
tstruby.obj : warning LNK4042: object specified more than once; extras
ignored
tstruby.obj : warning LNK4042: object specified more than once; extras
ignored
LINK : error LNK2001: unresolved external symbol Init_tstruby
tstruby.lib : fatal error LNK1120: 1 unresolved externals
LINK : fatal error LNK1141: failure during build of exports file
NMAKE : fatal error U1077: 'cl' : return code '0x2'
Stop.


Anton Kondakov

----- Original Message -----
From: <nobu.nokada / softhome.net>
To: "ruby-talk ML" <ruby-talk / ruby-lang.org>
Sent: Friday, April 12, 2002 12:18 PM
Subject: Re: Ruby and MSVC++


> Hi,
>
> At Fri, 12 Apr 2002 16:03:10 +0900,
> Anton V.Kondakov <anton / webstroy.ru> wrote:
> > When i try compile source from Programming Ruby book, i get error:
> >
> > Compiling...
> > tstruby.cpp
> > d:\tstruby\tstruby.cpp(25) : error C2664: 'rb_define_method' : cannot
> > convert parameter 3 from 'unsigned long (unsigned long)' to 'unsigned
long
> > (__cdecl *)(...)'
>
> Rename tstruby.cpp tstruby.c
>
> --
> Nobu Nakada
>