Hi,

I have attempted to install the SAP DB v7.4 drivers on one of our systems,
but encountered errors in the sqltypes.h file.

System:
Red Hat Linux 7.3 2.96-110
gcc 2.96
Perl v5.6.1

Other components installed:
DBI-1.38
DBD-ODBC-1.06
unixODBC-2.2.7


The errors were encountered with both of the following:
sapdb-odbc-linux-i386-7.4.3.pre20
sapdb-odbc-linux-i386-7.4.03.pre11


When the using the header and library files from the
sapdb-odbc-linux-i386-7.4* distributions ( and after fixing the
'Makefile:306: *** missing separator.  Stop.' in the DBD::ODBC Makefile ), I
get the following:


[DBD-ODBC-1.06]# make
/bin/sh -c true
/bin/sh -c true
gcc -c -I/opt/sapdb/unixODBC/include -I. -I/usr/lib/perl5/site_perl/5.6.1/i3
86-linux/auto/DBI -fno-strict-aliasing -I/usr/local/include -O2 -march=i386 
-mcpu=i686   -DVERSION=\"1.06\" -DXS_VERSION=\"1.06\" -fPIC -I/usr/lib/perl5
/5.6.1/i386-linux/CORE -I/opt/sapdb/unixODBC/include ODBC.c
In file included from /opt/sapdb/unixODBC/include/sql.h:33,
                 from dbdodbc.h:6,
                 from ODBC.h:9,
                 from ODBC.xs:1:
/opt/sapdb/unixODBC/include/sqltypes.h:297: parse error before `WORD'
/opt/sapdb/unixODBC/include/sqltypes.h:297: warning: no semicolon at end of
struct or union
/opt/sapdb/unixODBC/include/sqltypes.h:298: warning: data definition has no
type or storage class
/opt/sapdb/unixODBC/include/sqltypes.h:299: parse error before `Data4'
/opt/sapdb/unixODBC/include/sqltypes.h:299: warning: data definition has no
type or storage class
/opt/sapdb/unixODBC/include/sqltypes.h:300: parse error before `}'
/opt/sapdb/unixODBC/include/sqltypes.h:300: warning: data definition has no
type or storage class
make: *** [ODBC.o] Error 1


The error is reported as being associated with the following section of
code:

#if (ODBCVER >= 0x0350)
#ifdef GUID_DEFINED
typedef GUID    SQLGUID;
#else
/* size is 16 */
typedef struct  tagSQLGUID
{
    DWORD Data1;
    WORD Data2;
    WORD Data3;
    BYTE Data4[ 8 ];
} SQLGUID;
#endif  /* GUID_DEFINED */
#endif  /* ODBCVER >= 0x0350 */


A colleague and myself amended the data types but then get the following
errors (probably from DBD::ODBC):

[DBD-ODBC-1.06]# make
/bin/sh -c true
/bin/sh -c true
gcc -c -I/opt/sapdb/unixODBC/include -I. -I/usr/lib/perl5/site_perl/5.6.1/i3
86-linux/auto/DBI -fno-strict-aliasing -I/usr/local/include -O2 -march=i386 
-mcpu=i686   -DVERSION=\"1.06\" -DXS_VERSION=\"1.06\" -fPIC -I/usr/lib/perl5
/5.6.1/i386-linux/CORE -I/opt/sapdb/unixODBC/include ODBC.c
gcc -c -I/opt/sapdb/unixODBC/include -I. -I/usr/lib/perl5/site_perl/5.6.1/i3
86-linux/auto/DBI -fno-strict-aliasing -I/usr/local/include -O2 -march=i386 
-mcpu=i686   -DVERSION=\"1.06\" -DXS_VERSION=\"1.06\" -fPIC -I/usr/lib/perl5
/5.6.1/i386-linux/CORE -I/opt/sapdb/unixODBC/include dbdimp.c
dbdimp.c: In function `build_results':
dbdimp.c:261: warning: passing arg 2 of `SQLRowCount' from incompatible
pointer type
dbdimp.c: In function `dbd_db_execdirect':
dbdimp.c:332: warning: passing arg 2 of `SQLRowCount' from incompatible
pointer type
dbdimp.c: In function `odbc_describe':
dbdimp.c:1575: warning: passing arg 7 of `SQLDescribeCol' from incompatible
pointer type
dbdimp.c:1593: warning: passing arg 7 of `SQLColAttributes' from
incompatible pointer type
dbdimp.c:1607: warning: passing arg 7 of `SQLColAttributes' from
incompatible pointer type
dbdimp.c:1726: warning: passing arg 7 of `SQLDescribeCol' from incompatible
pointer type
dbdimp.c:1763: warning: passing arg 6 of `SQLBindCol' from incompatible
pointer type
dbdimp.c: In function `odbc_st_execute':
dbdimp.c:1958: warning: passing arg 2 of `SQLRowCount' from incompatible
pointer type
dbdimp.c: In function `_dbd_get_param_type':
dbdimp.c:2366: warning: passing arg 4 of `SQLDescribeParam' from
incompatible pointer type
dbdimp.c: In function `_dbd_rebind_ph':
dbdimp.c:2655: warning: passing arg 10 of `SQLBindParameter' from
incompatible pointer type
dbdimp.c: In function `odbc_st_blob_read':
dbdimp.c:2822: warning: passing arg 6 of `SQLGetData' from incompatible
pointer type
dbdimp.c: In function `odbc_describe_col':
dbdimp.c:3769: warning: passing arg 7 of `SQLDescribeCol' from incompatible
pointer type
dbdimp.c: In function `odbc_col_attributes':
dbdimp.c:3888: warning: passing arg 7 of `SQLColAttributes' from
incompatible pointer type
Running Mkbootstrap for DBD::ODBC ()
chmod 644 ODBC.bs
rm -f blib/arch/auto/DBD/ODBC/ODBC.so
LD_RUN_PATH="/opt/sapdb/unixODBC/lib" gcc  -shared -L/usr/local/lib ODBC.o
dbdimp.o  -o
blib/arch/auto/DBD/ODBC/ODBC.so   -L/opt/sapdb/unixODBC/lib -lodbc
chmod 755 blib/arch/auto/DBD/ODBC/ODBC.so
cp ODBC.bs blib/arch/auto/DBD/ODBC/ODBC.bs
chmod 644 blib/arch/auto/DBD/ODBC/ODBC.bs
Manifying blib/man3/DBD::ODBC.3pm
[DBD-ODBC-1.06]#
[DBD-ODBC-1.06]#
[DBD-ODBC-1.06]#
[DBD-ODBC-1.06]# make install
/bin/sh -c true
/bin/sh -c true
Installing /usr/lib/perl5/site_perl/5.6.1/i386-linux/auto/DBD/ODBC/ODBC.so
Installing /usr/lib/perl5/site_perl/5.6.1/i386-linux/auto/DBD/ODBC/ODBC.bs
Files found in blib/arch: installing files in blib/lib into architecture
dependent library tree
Installing /usr/lib/perl5/site_perl/5.6.1/i386-linux/DBD/ODBC.pm
Installing /usr/lib/perl5/site_perl/5.6.1/i386-linux/DBD/ODBC/Changes.pm
Installing /usr/share/man/man3/DBD::ODBC.3pm
Writing /usr/lib/perl5/site_perl/5.6.1/i386-linux/auto/DBD/ODBC/.packlist
Appending installation info to /usr/lib/perl5/5.6.1/i386-linux/perllocal.pod
[DBD-ODBC-1.06]# make test
/bin/sh -c true
/bin/sh -c true
PERL_DL_NONLAZY=1
/usr/bin/perl -Iblib/arch -Iblib/lib -I/usr/lib/perl5/5.6.1/i386-linux -I/us
r/lib/perl5/5.6.1 -e 'use Test::Harness qw(&runtests $verbose); $verbose=0;
runtests @ARGV;' t/*.t
t/01base............ok
t/02simple..........ok
t/03dbatt...........ok
t/05meth............ok
t/07bind............ok
t/08bind2...........ok
t/09multi...........skipped: multiple statements not supported using SAP DB
t/20SqlServer......."my" variable $output masks earlier declaration in same
scope at t/20SqlServer.t line 391.
skipped: Microsoft SQL Server tests not supported using SAP DB
t/30Oracle..........skipped: Oracle tests not supported using SAP DB
All tests successful, 3 tests skipped.
Files=9, Tests=61,  9 wallclock secs ( 2.12 cusr +  0.28 csys =  2.40 CPU)


Has anyone else see this, and is it possible that the hearder file is
incorrect?


Regards.


John Lynch



This email has been scanned for viruses.


-- 
MaxDB Discussion Mailing List
For list archives: http://lists.mysql.com/maxdb
To unsubscribe:    http://lists.mysql.com/[EMAIL PROTECTED]

Reply via email to