[Rubyinstaller-devel] Buildinf OCI and Ruby-ODBC problems?

Curt Hibbs curt.hibbs at gmail.com
Tue Oct 9 07:00:56 EDT 2007


When I gt the error I commented it out of the rake file just to move on and
see if I was going to have any other problems -- I hadn't gone back yet to
take a closer look at ruby-odbc. But, I'm pretty sure this is the same
error.

I upgraded ruby-ocbc for this build to version 0.9995. I haven't tried yet
going back to 0.9994, but I'll bet this problem was introduced in 0.9995. I
build ruby-odbc 0.9994 six months ago for the last release of OCI without
any problems.

Curt

On 10/8/07, Luis Lavena <luislavena at gmail.com> wrote:
>
> Curt,
>
> I'm in the middle of the rebuild process (with p111) and found the
> issue you're getting with ruby-odbc (0.9995).
>
> The following error, is part of the mkmf.log file:
>
> have_library_ex: checking for SQLAllocConnect() in -lodbc32...
> -------------------- no
>
> "cl -nologo -Feconftest -I.
>
> -ID:/Users/Developer/code/OpenSource/installer-trunk/ruby/lib/ruby/1.8/i386-mswin32
> -ID:/Users/Developer/code/OpenSource/installer-trunk/downloads/ruby-
> odbc-0.9995
>
> -ID:/Users/Developer/code/OpenSource/installer-trunk/ruby/lib/ruby/1.8/i386-mswin32
> -MD -Zi -O2b2xg- -G6 conftest.c   msvcrt-ruby18-static.lib odbc32.lib
> oldnames.lib user32.lib advapi32.lib ws2_32.lib   -link
> -libpath:"."
> -libpath:"D:/Users/Developer/code/OpenSource/installer-trunk/ruby/lib"
> -stack:0x2000000"
> conftest.c
> conftest.obj : error LNK2001: unresolved external symbol _SQLAllocConnect
> conftest.exe : fatal error LNK1120: 1 unresolved externals
> checked program was:
> /* begin */
> 1: #define WIN32_LEAN_AND_MEAN
> 2: #include <winsock2.h>
> 3: #include <windows.h>
> 4: #include <sql.h>
> 5:
> 6: /*top*/
> 7: int main() { return 0; }
> 8: int t() { void ((*volatile p)()); p = (void
> ((*)()))SQLAllocConnect; return 0; }
> /* end */
>
> "cl -nologo -Feconftest -I.
>
> -ID:/Users/Developer/code/OpenSource/installer-trunk/ruby/lib/ruby/1.8/i386-mswin32
> -ID:/Users/Developer/code/OpenSource/installer-trunk/downloads/ruby-
> odbc-0.9995
>
> -ID:/Users/Developer/code/OpenSource/installer-trunk/ruby/lib/ruby/1.8/i386-mswin32
> -MD -Zi -O2b2xg- -G6 conftest.c   msvcrt-ruby18-static.lib odbc32.lib
> oldnames.lib user32.lib advapi32.lib ws2_32.lib   -link
> -libpath:"."
> -libpath:"D:/Users/Developer/code/OpenSource/installer-trunk/ruby/lib"
> -stack:0x2000000"
> conftest.c
> C:\VC\PSDK-preR2\Include\sqltypes.h(275) : error C2061: syntax error :
> identifier 'DWORD'
> C:\VC\PSDK-preR2\Include\sqltypes.h(276) : error C2061: syntax error :
> identifier 'Data2'
> C:\VC\PSDK-preR2\Include\sqltypes.h(276) : error C2059: syntax error : ';'
> C:\VC\PSDK-preR2\Include\sqltypes.h(277) : error C2061: syntax error :
> identifier 'Data3'
> C:\VC\PSDK-preR2\Include\sqltypes.h(277) : error C2059: syntax error : ';'
> C:\VC\PSDK-preR2\Include\sqltypes.h(278) : error C2061: syntax error :
> identifier 'Data4'
> C:\VC\PSDK-preR2\Include\sqltypes.h(278) : error C2059: syntax error : ';'
> C:\VC\PSDK-preR2\Include\sqltypes.h(278) : error C2059: syntax error : '['
> C:\VC\PSDK-preR2\Include\sqltypes.h(279) : error C2059: syntax error : '}'
> conftest.c(5) : error C2198: 'SQLAllocConnect' : too few actual parameters
> checked program was:
> /* begin */
> 1: #include <sql.h>
> 2:
> 3: /*top*/
> 4: int main() { return 0; }
> 5: int t() { SQLAllocConnect(); return 0; }
> /* end */
>
> --------------------
>
>
> It seems that the test program is including sql.h with its
> pre-requisite: windows.h
>
> Adding it, I'm getting another error:
>
> have_library_ex: checking for SQLAllocConnect() in -lodbc32...
> -------------------- no
>
> "cl -nologo -Feconftest -I.
>
> -ID:/Users/Developer/code/OpenSource/installer-trunk/ruby/lib/ruby/1.8/i386-mswin32
> -ID:/Users/Developer/code/OpenSource/installer-trunk/downloads/ruby-
> odbc-0.9995
>
> -ID:/Users/Developer/code/OpenSource/installer-trunk/ruby/lib/ruby/1.8/i386-mswin32
> -MD -Zi -O2b2xg- -G6 conftest.c   msvcrt-ruby18-static.lib odbc32.lib
> oldnames.lib user32.lib advapi32.lib ws2_32.lib   -link
> -libpath:"."
> -libpath:"D:/Users/Developer/code/OpenSource/installer-trunk/ruby/lib"
> -stack:0x2000000"
> conftest.c
> conftest.obj : error LNK2001: unresolved external symbol _SQLAllocConnect
> conftest.exe : fatal error LNK1120: 1 unresolved externals
> checked program was:
> /* begin */
> 1: #define WIN32_LEAN_AND_MEAN
> 2: #include <winsock2.h>
> 3: #include <windows.h>
> 4: #include <windows.h>
> 5: #include <sql.h>
> 6:
> 7: /*top*/
> 8: int main() { return 0; }
> 9: int t() { void ((*volatile p)()); p = (void
> ((*)()))SQLAllocConnect; return 0; }
> /* end */
>
> "cl -nologo -Feconftest -I.
>
> -ID:/Users/Developer/code/OpenSource/installer-trunk/ruby/lib/ruby/1.8/i386-mswin32
> -ID:/Users/Developer/code/OpenSource/installer-trunk/downloads/ruby-
> odbc-0.9995
>
> -ID:/Users/Developer/code/OpenSource/installer-trunk/ruby/lib/ruby/1.8/i386-mswin32
> -MD -Zi -O2b2xg- -G6 conftest.c   msvcrt-ruby18-static.lib odbc32.lib
> oldnames.lib user32.lib advapi32.lib ws2_32.lib   -link
> -libpath:"."
> -libpath:"D:/Users/Developer/code/OpenSource/installer-trunk/ruby/lib"
> -stack:0x2000000"
> conftest.c
> conftest.c(6) : error C2198: 'SQLAllocConnect' : too few actual parameters
> checked program was:
> /* begin */
> 1: #include <windows.h>
> 2: #include <sql.h>
> 3:
> 4: /*top*/
> 5: int main() { return 0; }
> 6: int t() { SQLAllocConnect(); return 0; }
> /* end */
>
>
> I need to check "too few actual parameters" (the SQLAllocConnect
> signature) and see what I could do to fix it.
>
> But so far, it seems ruby-odbc is too old for latest SDKs... or we are
> doing something wrong.
>
> What was the error you got?
>
> --
> Luis Lavena
> Multimedia systems
> -
> Leaders are made, they are not born. They are made by hard effort,
> which is the price which all of us must pay to achieve any goal that
> is worthwhile.
> Vince Lombardi
> _______________________________________________
> Rubyinstaller-devel mailing list
> Rubyinstaller-devel at rubyforge.org
> http://rubyforge.org/mailman/listinfo/rubyinstaller-devel
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://rubyforge.org/pipermail/rubyinstaller-devel/attachments/20071009/a060420d/attachment-0001.html 


More information about the Rubyinstaller-devel mailing list