That patch is broken. You need to do s/NA/na/g to get it to apply properly. This will work:

*** typemap.orig Thu Feb 7 11:36:46 2002 --- typemap Thu Feb 7 11:37:35 2002 *************** *** 54,64 **** ######### INPUT T_timeval ! $var.tv_sec = atof((char *)SvPV($arg,na)); $var.tv_usec = 0 T_berval ! $var.bv_val = (char *)SvPV($arg,na); ! $var.bv_len = na T_charptrptr $var = (char **)avref2charptrptr($arg) T_bervalptrptr --- 54,64 ---- ######### INPUT T_timeval ! $var.tv_sec = atof((char *)SvPV($arg,PL_na)); $var.tv_usec = 0 T_berval ! $var.bv_val = (char *)SvPV($arg,PL_na); ! $var.bv_len = PL_na T_charptrptr $var = (char **)avref2charptrptr($arg) T_bervalptrptr *** API.xs.orig Thu Feb 7 11:02:26 2002 --- API.xs Thu Feb 7 11:48:20 2002 *************** *** 194,200 **** for (ix_av = 0;ix_av <= avref_arraylen;ix_av++) { current_val = av_fetch((AV *)SvRV(avref),ix_av,0); ! tmp_cpp[ix_av] = StrDup(SvPV(*current_val,na)); } tmp_cpp[ix_av] = NULL; --- 194,200 ---- for (ix_av = 0;ix_av <= avref_arraylen;ix_av++) { current_val = av_fetch((AV *)SvRV(avref),ix_av,0); ! tmp_cpp[ix_av] = StrDup(SvPV(*current_val,PL_na)); } tmp_cpp[ix_av] = NULL; *************** *** 224,230 **** New(1,tmp_ber[ix_av],1,struct berval); current_val = av_fetch((AV *)SvRV(avref),ix_av,0); ! tmp_char = SvPV(*current_val,na); val_len = SvCUR(*current_val); Newz(1,tmp2,val_len+1,char); --- 224,230 ---- New(1,tmp_ber[ix_av],1,struct berval); current_val = av_fetch((AV *)SvRV(avref),ix_av,0); ! tmp_char = SvPV(*current_val,PL_na); val_len = SvCUR(*current_val); Newz(1,tmp2,val_len+1,char); *************** *** 366,372 **** } else { if (cont) return NULL; ! if (strcmp(SvPV(ldap_value_ref,na),"") == 0) { if (ldap_add_func != 1) { --- 366,372 ---- } else { if (cont) return NULL; ! if (strcmp(SvPV(ldap_value_ref,PL_na),"") == 0) { if (ldap_add_func != 1) { *************** *** 383,389 **** ldap_current_mod->mod_op = LDAP_MOD_REPLACE; } New(1,ldap_current_mod->mod_values,2,char *); ! ldap_current_mod->mod_values[0] = StrDup(SvPV(ldap_value_re +f,na)); ldap_current_mod->mod_values[1] = NULL; } } --- 383,389 ---- ldap_current_mod->mod_op = LDAP_MOD_REPLACE; } New(1,ldap_current_mod->mod_values,2,char *); ! ldap_current_mod->mod_values[0] = StrDup(SvPV(ldap_value_re +f,PL_na)); ldap_current_mod->mod_values[1] = NULL; } } *************** *** 1716,1722 **** hv_store(FullHash,options_key,strlen(options_key),option +s,0); ldap_free_urldesc(realcomp); } else { ! RETVAL = &sv_undef; } } OUTPUT: --- 1716,1722 ---- hv_store(FullHash,options_key,strlen(options_key),option +s,0); ldap_free_urldesc(realcomp); } else { ! RETVAL = &PL_sv_undef; } } OUTPUT:

cheers

tachyon


In reply to Re^2: Help compiling perldap1.4 by tachyon
in thread Help compiling perldap1.4 by Anonymous Monk

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.