DBD::Informix esqltest failure

DBD::Informix esqltest failure

am 02.11.2005 21:44:42 von dkleppinger

I'm trying to install DBD-Informix-2005.02 and "perl Makefile.PL" fails
on esqltest with an undefined symbol. You can see the perl/DBI/OS info
in the output below. Informix version is 9.40.HC5. I've tried to run
with INFORMIXSERVER set to an onsoctcp connection and a onipcshm. Both
failed the same way. I'm using the hp ANSI C compiler (not the K&R).
We do have gcc installed too but I've not tried to use it.
I have successfully compiled/run the esqlbasic program.

Note: I'd love to upgrade our perl but can't because a perl/C module
supplied by our major software vendor doesn't work with perl 5.8.x.

====================================

% perl Makefile.PL
*** ExtUtils::AutoInstall version 0.63
*** Checking for dependencies...
[Core Features]
- DBI ...loaded. (1.48 >= 1.38)
[High Resolution Timing]
- Time::HiRes ...loaded. (1.76)
[POD Format Testing]
- Test::Pod ...loaded. (1.22)
*** ExtUtils::AutoInstall configuration finished.
Subroutine WriteMakefile redefined at
/opt/perl5/6/lib/site_perl/5.6.2/ExtUtils/AutoInstall.pm line 491.

Configuring IBM Informix Database Driver for Perl DBI Version 2005.02
(2005-07-29) (aka DBD::Informix)
You are using DBI version 1.48 and Perl version 5.006002
Remember to actually read the README file!

Perl: perl v5.006002 PA-RISC2.0 dl_hpux.xs
System: hp-ux admin1 b.11.11 u 9000800 139434606 unlimited-user license
*** Ideally, you should upgrade to Perl version 5.008007.

Using INFORMIXDIR=/opt/informix and ESQL/C compiler esql
Using IBM Informix CSDK Version 2.80, IBM Informix-ESQL Version 9.52.HC2
from /opt/informix

Beware: DBD::Informix is not yet aware of all the new IUS data types.

Assert macro will be disabled!

lib/DBD/Informix/Defaults.pm written OK
esqlvrsn.h written OK
esqlinfo.h written OK

Testing whether your Informix test environment will work...
ccflag = <<>>
ccflag = <<-Ae>>
ccflag = <<-D_HPUX_SOURCE>>
ccflag = <<-Wl,+vnocompatwarnings>>
ccflag = <<+Z>>
ccflag = <<-I/usr/local/include>>
ccflag = <<-I/opt/gnu/include>>
ccflag = <<-D_LARGEFILE_SOURCE>>
ccflag = <<-D_FILE_OFFSET_BITS=64>>
cppflag = <<-DESQLC_VERSION=952>>
cppflag = <<-DNDEBUG>>
cppflag = <<-DUSE_REAL_MALLOC>>
execute_command: esql -c -Ae -D_HPUX_SOURCE -Wl,+vnocompatwarnings +Z
-I/usr/local/include -I/opt/gnu/include -D_LARGEFILE_SOURCE
-D_FILE_OFFSET_BITS=64 -DESQLC_VERSION=952 -DNDEBUG -DUSE_REAL_MALLOC
esqltest.ec
+ec+ <>
+ec+ <<-c>>
+ec+ <<>>
+ec+ <<-Ae>>
+ec+ <<-D_HPUX_SOURCE>>
+ec+ <<-Wl,+vnocompatwarnings>>
+ec+ <<+Z>>
+ec+ <<-I/usr/local/include>>
+ec+ <<-I/opt/gnu/include>>
+ec+ <<-D_LARGEFILE_SOURCE>>
+ec+ <<-D_FILE_OFFSET_BITS=64>>
+ec+ <<-DESQLC_VERSION=952>>
+ec+ <<-DNDEBUG>>
+ec+ <<-DUSE_REAL_MALLOC>>
+ec+ <>
+ setenv INFORMIXC = /opt/perl5/6/bin/perl esqlcc
+ setenv ESQLCC = cc
execute_command: esql -c -Ae -D_HPUX_SOURCE -Wl,+vnocompatwarnings +Z
-I/usr/local/include -I/opt/gnu/include -D_LARGEFILE_SOURCE
-D_FILE_OFFSET_BITS=64 -DESQLC_VERSION=952 -DNDEBUG -DUSE_REAL_MALLOC
esqlc_v6.ec
+ec+ <>
+ec+ <<-c>>
+ec+ <<>>
+ec+ <<-Ae>>
+ec+ <<-D_HPUX_SOURCE>>
+ec+ <<-Wl,+vnocompatwarnings>>
+ec+ <<+Z>>
+ec+ <<-I/usr/local/include>>
+ec+ <<-I/opt/gnu/include>>
+ec+ <<-D_LARGEFILE_SOURCE>>
+ec+ <<-D_FILE_OFFSET_BITS=64>>
+ec+ <<-DESQLC_VERSION=952>>
+ec+ <<-DNDEBUG>>
+ec+ <<-DUSE_REAL_MALLOC>>
+ec+ <>
+ setenv INFORMIXC = /opt/perl5/6/bin/perl esqlcc
+ setenv ESQLCC = cc
execute_command: esql -o esqltest esqltest.o esqlc_v6.o
+ec+ <>
+ec+ <<-o>>
+ec+ <>
+ec+ <>
+ec+ <>
+ setenv INFORMIXC = /opt/perl5/6/bin/perl esqlcc
+ setenv ESQLCC = cc
/usr/ccs/bin/ld: Unsatisfied symbols:
dbd_ix_opendatabase (first referenced in esqltest.o) (code)
Failed to link test program esqltest
# Looks like your test died before it could output anything.

Re: DBD::Informix esqltest failure

am 03.11.2005 05:50:40 von jonathan.leffler

------=_Part_13694_2954506.1130993440360
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable
Content-Disposition: inline

On 11/2/05, David Kleppinger wrote:
>
> I'm trying to install DBD-Informix-2005.02 and "perl Makefile.PL" fails
> on esqltest with an undefined symbol. You can see the perl/DBI/OS info
> in the output below. Informix version is 9.40.HC5. I've tried to run
> with INFORMIXSERVER set to an onsoctcp connection and a onipcshm. Both
> failed the same way. I'm using the hp ANSI C compiler (not the K&R).
> We do have gcc installed too but I've not tried to use it.
> I have successfully compiled/run the esqlbasic program.



The problem is not yet with the connection to the database - that's the goo=
d
news.

Given that the Perl you are using was compiled with the HP compiler, you
should not attempt to use GCC.

Note: I'd love to upgrade our perl but can't because a perl/C module
> supplied by our major software vendor doesn't work with perl 5.8.x.



That's only a problem if you need to use both 'their' Perl 5.6.x and 'your'
Perl 5.8.x at the same time - or, more precisely, if you need to use their
Perl/C module at the same time as DBD::Informix.

==================== =====3D=
===========3D
>
> % perl Makefile.PL
> *** ExtUtils::AutoInstall version 0.63
> *** Checking for dependencies...
> [Core Features]
> - DBI ...loaded. (1.48 >=3D 1.38)
> [High Resolution Timing]
> - Time::HiRes ...loaded. (1.76)
> [POD Format Testing]
> - Test::Pod ...loaded. (1.22)
> *** ExtUtils::AutoInstall configuration finished.
> Subroutine WriteMakefile redefined at
> /opt/perl5/6/lib/site_perl/5.6.2/ExtUtils/AutoInstall.pm line 491.
>
> Configuring IBM Informix Database Driver for Perl DBI Version 2005.02
> (2005-07-29) (aka DBD::Informix)
> You are using DBI version 1.48 and Perl version 5.006002
> Remember to actually read the README file!
>
> Perl: perl v5.006002 PA-RISC2.0 dl_hpux.xs
> System: hp-ux admin1 b.11.11 u 9000800 139434606 unlimited-user license
> *** Ideally, you should upgrade to Perl version 5.008007.
>
> Using INFORMIXDIR=3D/opt/informix and ESQL/C compiler esql
> Using IBM Informix CSDK Version 2.80, IBM Informix-ESQL Version 9.52.HC2
> from /opt/informix
>
> Beware: DBD::Informix is not yet aware of all the new IUS data types.
>
> Assert macro will be disabled!
>
> lib/DBD/Informix/Defaults.pm written OK
> esqlvrsn.h written OK
> esqlinfo.h written OK
>
> Testing whether your Informix test environment will work...
> ccflag =3D <<>>
> ccflag =3D <<-Ae>>
> ccflag =3D <<-D_HPUX_SOURCE>>
> ccflag =3D <<-Wl,+vnocompatwarnings>>
> ccflag =3D <<+Z>>
> ccflag =3D <<-I/usr/local/include>>
> ccflag =3D <<-I/opt/gnu/include>>
> ccflag =3D <<-D_LARGEFILE_SOURCE>>
> ccflag =3D <<-D_FILE_OFFSET_BITS=3D64>>
> cppflag =3D <<-DESQLC_VERSION=3D952>>
> cppflag =3D <<-DNDEBUG>>
> cppflag =3D <<-DUSE_REAL_MALLOC>>
> execute_command: esql -c -Ae -D_HPUX_SOURCE -Wl,+vnocompatwarnings +Z
> -I/usr/local/include -I/opt/gnu/include -D_LARGEFILE_SOURCE
> -D_FILE_OFFSET_BITS=3D64 -DESQLC_VERSION=3D952 -DNDEBUG -DUSE_REAL_MALLOC
> esqltest.ec
> +ec+ <>
> +ec+ <<-c>>
> +ec+ <<>>
> +ec+ <<-Ae>>
> +ec+ <<-D_HPUX_SOURCE>>
> +ec+ <<-Wl,+vnocompatwarnings>>
> +ec+ <<+Z>>
> +ec+ <<-I/usr/local/include>>
> +ec+ <<-I/opt/gnu/include>>
> +ec+ <<-D_LARGEFILE_SOURCE>>
> +ec+ <<-D_FILE_OFFSET_BITS=3D64>>
> +ec+ <<-DESQLC_VERSION=3D952>>
> +ec+ <<-DNDEBUG>>
> +ec+ <<-DUSE_REAL_MALLOC>>
> +ec+ <>>
> + setenv INFORMIXC =3D /opt/perl5/6/bin/perl esqlcc
> + setenv ESQLCC =3D cc
> execute_command: esql -c -Ae -D_HPUX_SOURCE -Wl,+vnocompatwarnings +Z
> -I/usr/local/include -I/opt/gnu/include -D_LARGEFILE_SOURCE
> -D_FILE_OFFSET_BITS=3D64 -DESQLC_VERSION=3D952 -DNDEBUG -DUSE_REAL_MALLOC
> esqlc_v6.ec
> +ec+ <>
> +ec+ <<-c>>
> +ec+ <<>>
> +ec+ <<-Ae>>
> +ec+ <<-D_HPUX_SOURCE>>
> +ec+ <<-Wl,+vnocompatwarnings>>
> +ec+ <<+Z>>
> +ec+ <<-I/usr/local/include>>
> +ec+ <<-I/opt/gnu/include>>
> +ec+ <<-D_LARGEFILE_SOURCE>>
> +ec+ <<-D_FILE_OFFSET_BITS=3D64>>
> +ec+ <<-DESQLC_VERSION=3D952>>
> +ec+ <<-DNDEBUG>>
> +ec+ <<-DUSE_REAL_MALLOC>>
> +ec+ <>
> + setenv INFORMIXC =3D /opt/perl5/6/bin/perl esqlcc
> + setenv ESQLCC =3D cc
> execute_command: esql -o esqltest esqltest.o esqlc_v6.o
> +ec+ <>
> +ec+ <<-o>>
> +ec+ <>
> +ec+ <>
> +ec+ <>
> + setenv INFORMIXC =3D /opt/perl5/6/bin/perl esqlcc
> + setenv ESQLCC =3D cc
> /usr/ccs/bin/ld: Unsatisfied symbols:
> dbd_ix_opendatabase (first referenced in esqltest.o) (code)
> Failed to link test program esqltest
> # Looks like your test died before it could output anything.
>
>
The reference to dbd_ix_opendatabase() appears in
esqltest.ec,
and should only be compiled into the code if the ESQL/C version is less tha=
n
600 (and not between 290 and 300). The -DESQLC_VERSION=3D952 option should
mean that is not what's going wrong - yet, apparently, it is.

That function is defined in esqlc_v5.ec; the alternative is dbd_ix_connect(=
)
provided in esqlc_v6.ec. You can confirm this by llisting the symbols in
esqltest.o and observing that dbd_ix_opendatabase is listed and
dbd_ix_connect is not.

So, the question reduces to: how on earth is the code in
esqltest.ecgetting confused?

Can you rerun the test with DBD_INFORMIX_DEBUG_ESQLCC=3Dyes set in the
environment? That may help. We may also be reduced to debugging the esql
script proper - by making a copy, adding set -x at a judicious point, and
then redo the build yet again. What we're looking for is concrete evidence
that the Sun compiler gets given the -DESQLC_VERSION=3D952 argument unmappe=
d.

--
Jonathan Leffler #include
Guardian of DBD::Informix - v2005.02 - http://dbi.perl.org
"I don't suffer from insanity - I enjoy every minute of it."

------=_Part_13694_2954506.1130993440360--