I am trying to test DBI/DBD with Sybase 15. The system currently works with Perl 5.8.5 and a similarly old DBD.

First, I built 5.8.9, the last saved version of the 5.8 tree, and 5.12.1, the most recent (64 bit) version. Each is in its own directory:

/opt/tools/perl5.8.9

/opt/tools/perl5.12.1

setting the path to /opt/tools/perl5.8.9/bin, I installed DBI-1.613_70 that worked no problem. Same with perl5.12.1

Then, with gcc-3.4.6 on RedHat AS 4, or Sun's compiler on Solaris, I get the following error, with either version. I'm an experienced C++ programmer, I just don't have enough experience with perl interfacing to C, can anyone tell me what to do?

cc -c -I/opt/tools/sybase_oc/OCS-15_0/include -DSYB_LP64 -I/opt/tools +/perl5.12.1/lib/site_perl/5.12.1/x86_64-linux/auto/DBI -fno-strict-al +iasing -pipe -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_ +BITS=64 -O2 -DVERSION=\"1.10\" -DXS_VERSION=\"1.10\" -fPIC "-I/opt/ +tools/perl5.12.1/lib/5.12.1/x86_64-linux/CORE" Sybase.c Sybase.xs: In function `XS_DBD__Sybase__db__date_fmt': Sybase.xs:76: error: `sv_yes' undeclared (first use in this function) Sybase.xs:76: error: (Each undeclared identifier is reported only once Sybase.xs:76: error: for each function it appears in.) Sybase.xs:76: error: `sv_no' undeclared (first use in this function)
Here's the line of code:
void _date_fmt(dbh, fmt) SV * dbh char * fmt ALIAS: syb_date_fmt = 1 CODE: D_imp_dbh(dbh); ST(0) = syb_db_date_fmt(dbh, imp_dbh, fmt) ? &sv_yes : &sv_no;

In reply to Compiler Errors building DBD against Sybase 15 OpenClient by hydracat

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.