Error installing DBD::Sybase

Error installing DBD::Sybase

am 11.09.2007 18:39:03 von asmita.joshi

Hi
I tried installing DBD Sybase but encountered many errors along the
installation process. Please let me know if anyone has seen the errors
below. Am I missing some other dependency module?

Attempting to install DBD Sybase from cpan sheel fails. Manual install
also fails. (I use perl 5.8.5.)
1. In the CPAN shell, type in install DBD::Sybase.
Module DBD::Sybase should install without errors and without me having
to tinker with CONFIG, environment variables, #ifdef in .c files. That
is not the case though

Part of Error Log:
==============================================
CPAN.pm: Going to build M/ME/MEWP/DBD-Sybase-1.08.tar.gz

Please set SYBASE in CONFIG, or set the $SYBASE environment variable
at Makefile.PL line 103, line 44.
Warning: No success on command[/usr/bin/perl Makefile.PL]
Warning (usually harmless): 'YAML' not installed, will not store
persistent state
MEWP/DBD-Sybase-1.08.tar.gz
/usr/bin/perl Makefile.PL -- NOT OK
Running make test
Make had some problems, won't test
Running make install
Make had some problems, won't install
Could not read '/root/.cpan/build/DBD-Sybase-1.08-Idbkj2/META.yml'.
Falling back to other methods to determine prerequisites
Failed during this command:
MEWP/DBD-Sybase-1.08.tar.gz : writemakefile NO '/usr/
bin/perl Makefile.PL' returned status 512
==============================================
If I do add $SYBASE as say /usr/local/sybase, the next error that is
seen is this:
==============================================
gcc -c -I/usr/local/sybase/include -I/usr/lib/perl5/site_perl/5.8.5/
i386-linux-thread-multi/auto/DBI -D_REENTRANT -D_GNU_SOURCE -
DDEBUGGING -fno-strict-aliasing -pipe -I/usr/local/include -
D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -I/usr/include/gdbm -O2 -g -
pipe -m32 -march=i386 -mtune=pentium4 -DVERSION=\"1.08\" -
DXS_VERSION=\"1.08\" -fPIC "-I/usr/lib/perl5/5.8.5/i386-linux-thread-
multi/CORE" dbdimp.c
dbdimp.c: In function `alloc_datatype':
dbdimp.c:3490: error: `CS_USHORT_TYPE' undeclared (first use in this
function)
dbdimp.c:3490: error: (Each undeclared identifier is reported only
once
dbdimp.c:3490: error: for each function it appears in.)
make: *** [dbdimp.o] Error 1
MEWP/DBD-Sybase-1.08.tar.gz
/usr/bin/make -- NOT OK
==============================================

If I add a #if defined block around this variable in dbdimp.c file,
the install process moves on till it encounters this error.

==============================================
gcc -L/usr/local/sybase/lib -shared -L/usr/local/lib Sybase.o
dbdimp.o -o blib/arch/auto/DBD/Sybase/Sybase.so \
-L/usr/local/sybase/lib -lct -lcs -lsybtcl -lcomn -lintl -lblk -ldl
-lm \

/usr/local/sybase/lib/libsybtcl.a(psx_sigs.o)(.text+0x123):p sx_sigs.o:
undefined reference to `errno'
/usr/local/sybase/lib/libsybtcl.a(psx_sigs.o)(.text+0x241):p sx_sigs.o:
undefined reference to `errno'
/usr/local/sybase/lib/libsybtcl.a(psx_sigs.o)(.text+0x37c):p sx_sigs.o:
undefined reference to `errno'
/usr/local/sybase/lib/libsybtcl.a(psx_sigs.o)(.text+0x47f):p sx_sigs.o:
undefined reference to `errno'
/usr/local/sybase/lib/libsybtcl.a(psx_sigs.o)(.text+0x4f0):p sx_sigs.o:
undefined reference to `errno'
/usr/local/sybase/lib/libsybtcl.a(psx_sigs.o)(.text+0x521):p sx_sigs.o:
more undefined references to `errno' follow
/usr/local/sybase/lib/libblk.a(blkinit.o)(.text+0x12a5):blki nit.o:
undefined reference to `ct_poll'
/usr/local/sybase/lib/libblk.a(blkinit.o)(.text+0x13a6):blki nit.o:
undefined reference to `ct_cmd_props'
/usr/local/sybase/lib/libblk.a(blkautil.o)(.text+0x264):blka util.o:
undefined reference to `ct_cmd_props'
/usr/local/sybase/lib/libblk.a(blkautil.o)(.text+0x457):blka util.o:
undefined reference to `ct_wakeup'
/usr/local/sybase/lib/libblk.a(blksutil.o)(.text+0x58):blksu til.o:
undefined reference to `com_st_ver'
/usr/local/sybase/lib/libblk.a(blksutil.o)(.text+0x179):blks util.o:
undefined reference to `com_ns_trans'
/usr/local/sybase/lib/libblk.a(blksutil.o)(.text+0x5b9):blks util.o:
undefined reference to `com_ns_trans'
/usr/local/sybase/lib/libsybtcl.a(sim_drvs.o)(.data+0x14):si m_drvs.o:
undefined reference to `bsd_tcp'
collect2: ld returned 1 exit status
make: *** [blib/arch/auto/DBD/Sybase/Sybase.so] Error 1
MEWP/DBD-Sybase-1.08.tar.gz
/usr/bin/make -- NOT OK
==============================================
The above error happens during make test. So I thought I could go on
without it to install. But install fails with an error that it cannot
link libperl.a

Has anyone faced these errors and how have you solved them?

Thanks.
AJ