Re: LDAP from ruby

-----Original Message-----
From: gregarican [mailto:[email protected]]
Sent: Thursday, December 15, 2005 8:38 AM
To: ruby-talk ML
Subject: Re: LDAP from ruby

Personally I ran into problems getting Ruby’s LDAP package to
compile in my Win32 environment. I tried using MSVC, Borland,
etc. to no avail. So I abandoned trying at the point of
getting myself tangled up in all of the extconf/mkmf stuff
that was over my head.

Perhaps there are others who have succeeded in this area. If
so I’d love to hear from them :slight_smile:

I just tried. First, pass “–with-wldap32” to extconf.rb. If you get a
an error regarding dlltool along the lines of “no such file or
directory”, go to line 168 and put the word ‘lib’ in front of dll tool,
so that the command looks like:

lib dlltool --dllname ...

However, after trying that, I ended up with these errors:


Microsoft ® Program Maintenance Utility Version 7.10.3077
Copyright © Microsoft Corporation. All rights reserved.

    cl -nologo -MD -Zi -O2b2xg- -G6 -DUSE_WLDAP32 -I./win

-I/usr/local/include -I. -Ic:/ruby/lib
/ruby/1.8/i386-mswin32 -Ic:/ruby/lib/ruby/1.8/i386-mswin32 -I.
-I./… -I./…/missing -c -Tcconn
win\winldap.h(188) : error C2059: syntax error : ‘}’
win\winldap.h(199) : error C2059: syntax error : ‘}’
win\winldap.h(230) : error C2059: syntax error : ‘}’
win\winldap.h(236) : error C2011: ‘timeval’ : ‘struct’ type redefinition
C:\Program Files\Microsoft Platform SDK for Windows XP
SP2\Include\WinSock.h(97) : see decla
ration of ‘timeval’
conn.c(8) : fatal error C1083: Cannot open include file: ‘sys/time.h’:
No such file or directory
NMAKE : fatal error U1077: ‘cl’ : return code ‘0x2’

Looking at win\winldap.h I don’t understand why those are syntax errors.
The timeval struct definition can be removed altogether I think. An
#ifdef check needs to be added to conn.c for sys/time.h.

In short, ruby-ldap needs some TLC. If you can solve those issues, it
should work.



This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs