[Rubyinstaller-devel] Ruby MinGW on Vista

David Leal dgleal at gmail.com
Thu Apr 10 11:35:27 EDT 2008


On Thu, Apr 10, 2008 at 1:13 PM, Luis Lavena <luislavena at gmail.com> wrote:
> Fir of all, thank you for your interest and the time you took to
> report this. I'm glad the update "partially" worked :-)

:) Actually, thank you for all your work and patience. Working with
Ruby in Windows is a nightmare right now, I'm glad you're set to
change that.

> It seems that building of zlib extension failed. you can check if the
> extension got build in ruby_build/ext/zlib (look for mkmf.log and
> leftovers like .o files).

Ok, I recompiled everything and got the same thing. There is a
mkmf.log, which I'm pasting below. I hope it helps.

have_library: checking for deflateReset() in -lz... -------------------- no

"gcc -o conftest -I../.. -I../../../ruby_1_8
-I../../../ruby_1_8/ext/zlib  -g -O2  conftest.c  -L"." -L"../.." -L.
    -lmsvcrt-ruby18-static -lz  -lws2_32  "
conftest.c: In function `t':
conftest.c:6: error: `deflateReset' undeclared (first use in this function)
conftest.c:6: error: (Each undeclared identifier is reported only once
conftest.c:6: error: for each function it appears in.)
checked program was:
/* begin */
1: #include <windows.h>
2: #include <winsock.h>
3:
4: /*top*/
5: int main() { return 0; }
6: int t() { void ((*volatile p)()); p = (void ((*)()))deflateReset; return 0; }
/* end */

"gcc -o conftest -I../.. -I../../../ruby_1_8
-I../../../ruby_1_8/ext/zlib  -g -O2  conftest.c  -L"." -L"../.." -L.
    -lmsvcrt-ruby18-static -lz  -lws2_32  "
\mingw\lib\gcc\mingw32\3.4.5\..\..\..\..\mingw32\bin\ld.exe: cannot find -lz
collect2: ld returned 1 exit status
checked program was:
/* begin */
1: /*top*/
2: int main() { return 0; }
3: int t() { deflateReset(); return 0; }
/* end */

--------------------

have_library: checking for deflateReset() in -llibz... -------------------- no

"gcc -o conftest -I../.. -I../../../ruby_1_8
-I../../../ruby_1_8/ext/zlib  -g -O2  conftest.c  -L"." -L"../.." -L.
    -lmsvcrt-ruby18-static -llibz  -lws2_32  "
conftest.c: In function `t':
conftest.c:6: error: `deflateReset' undeclared (first use in this function)
conftest.c:6: error: (Each undeclared identifier is reported only once
conftest.c:6: error: for each function it appears in.)
checked program was:
/* begin */
1: #include <windows.h>
2: #include <winsock.h>
3:
4: /*top*/
5: int main() { return 0; }
6: int t() { void ((*volatile p)()); p = (void ((*)()))deflateReset; return 0; }
/* end */

"gcc -o conftest -I../.. -I../../../ruby_1_8
-I../../../ruby_1_8/ext/zlib  -g -O2  conftest.c  -L"." -L"../.." -L.
    -lmsvcrt-ruby18-static -llibz  -lws2_32  "
\mingw\lib\gcc\mingw32\3.4.5\..\..\..\..\mingw32\bin\ld.exe: cannot find -llibz
collect2: ld returned 1 exit status
checked program was:
/* begin */
1: /*top*/
2: int main() { return 0; }
3: int t() { deflateReset(); return 0; }
/* end */

--------------------

have_library: checking for deflateReset() in -lzlib... -------------------- no

"gcc -o conftest -I../.. -I../../../ruby_1_8
-I../../../ruby_1_8/ext/zlib  -g -O2  conftest.c  -L"." -L"../.." -L.
    -lmsvcrt-ruby18-static -lzlib  -lws2_32  "
conftest.c: In function `t':
conftest.c:6: error: `deflateReset' undeclared (first use in this function)
conftest.c:6: error: (Each undeclared identifier is reported only once
conftest.c:6: error: for each function it appears in.)
checked program was:
/* begin */
1: #include <windows.h>
2: #include <winsock.h>
3:
4: /*top*/
5: int main() { return 0; }
6: int t() { void ((*volatile p)()); p = (void ((*)()))deflateReset; return 0; }
/* end */

"gcc -o conftest -I../.. -I../../../ruby_1_8
-I../../../ruby_1_8/ext/zlib  -g -O2  conftest.c  -L"." -L"../.." -L.
    -lmsvcrt-ruby18-static -lzlib  -lws2_32  "
\mingw\lib\gcc\mingw32\3.4.5\..\..\..\..\mingw32\bin\ld.exe: cannot find -lzlib
collect2: ld returned 1 exit status
checked program was:
/* begin */
1: /*top*/
2: int main() { return 0; }
3: int t() { deflateReset(); return 0; }
/* end */

--------------------

have_library: checking for deflateReset() in -lzdll... -------------------- no

"gcc -o conftest -I../.. -I../../../ruby_1_8
-I../../../ruby_1_8/ext/zlib  -g -O2  conftest.c  -L"." -L"../.." -L.
    -lmsvcrt-ruby18-static -lzdll  -lws2_32  "
conftest.c: In function `t':
conftest.c:6: error: `deflateReset' undeclared (first use in this function)
conftest.c:6: error: (Each undeclared identifier is reported only once
conftest.c:6: error: for each function it appears in.)
checked program was:
/* begin */
1: #include <windows.h>
2: #include <winsock.h>
3:
4: /*top*/
5: int main() { return 0; }
6: int t() { void ((*volatile p)()); p = (void ((*)()))deflateReset; return 0; }
/* end */

"gcc -o conftest -I../.. -I../../../ruby_1_8
-I../../../ruby_1_8/ext/zlib  -g -O2  conftest.c  -L"." -L"../.." -L.
    -lmsvcrt-ruby18-static -lzdll  -lws2_32  "
\mingw\lib\gcc\mingw32\3.4.5\..\..\..\..\mingw32\bin\ld.exe: cannot find -lzdll
collect2: ld returned 1 exit status
checked program was:
/* begin */
1: /*top*/
2: int main() { return 0; }
3: int t() { deflateReset(); return 0; }
/* end */

--------------------

So it seems lzdll cannot be found, but it's there, inside
extract_utils and inside mingw/bin.Could this be another Vista related
bug in mingw?

Again, thanks for your work, Luis.

Cheers,

David


More information about the Rubyinstaller-devel mailing list