Hello community,
here is the log from the commit of package perl-DBD-ODBC for openSUSE:Factory
checked in at Wed Apr 29 01:56:39 CEST 2009.
--------
--- perl-DBD-ODBC/perl-DBD-ODBC.changes 2009-04-06 14:05:06.000000000 +0200
+++ perl-DBD-ODBC/perl-DBD-ODBC.changes 2009-04-28 13:53:09.000000000 +0200
@@ -1,0 +2,6 @@
+Tue Apr 28 13:52:29 CEST 2009 - anicka(a)suse.cz
+
+- update to 1.20
+* bugfixes, test fixes
+
+-------------------------------------------------------------------
calling whatdependson for head-i586
Old:
----
DBD-ODBC-1.19.tar.bz2
perl-DBD-ODBC-1.19-Makefile.diff
New:
----
DBD-ODBC-1.20.tar.bz2
perl-DBD-ODBC-1.20-Makefile.diff
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ perl-DBD-ODBC.spec ++++++
--- /var/tmp/diff_new_pack.f23452/_old 2009-04-29 01:55:33.000000000 +0200
+++ /var/tmp/diff_new_pack.f23452/_new 2009-04-29 01:55:33.000000000 +0200
@@ -1,5 +1,5 @@
#
-# spec file for package perl-DBD-ODBC (Version 1.19)
+# spec file for package perl-DBD-ODBC (Version 1.20)
#
# Copyright (c) 2009 SUSE LINUX Products GmbH, Nuernberg, Germany.
#
@@ -27,7 +27,7 @@
Requires: perl-DBI unixODBC
Requires: perl = %{perl_version}
Summary: Perl DBD module for interfacing with ODBC databases
-Version: 1.19
+Version: 1.20
Release: 1
Source: DBD-ODBC-%{version}.tar.bz2
Patch: %{name}-%{version}-Makefile.diff
@@ -76,6 +76,9 @@
/var/adm/perl-modules/%{name}
%changelog
+* Tue Apr 28 2009 anicka(a)suse.cz
+- update to 1.20
+ * bugfixes, test fixes
* Mon Apr 06 2009 anicka(a)suse.cz
- update to 1.19
* test fixes
++++++ DBD-ODBC-1.19.tar.bz2 -> DBD-ODBC-1.20.tar.bz2 ++++++
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/DBD-ODBC-1.19/Changes new/DBD-ODBC-1.20/Changes
--- old/DBD-ODBC-1.19/Changes 2009-04-02 12:54:58.000000000 +0200
+++ new/DBD-ODBC-1.20/Changes 2009-04-20 17:21:34.000000000 +0200
@@ -2,7 +2,7 @@
DBD::ODBC::Changes - Log of significant changes to the DBD::ODBC
-(As of $LastChangedDate: 2009-04-02 11:54:56 +0100 (Thu, 02 Apr 2009) $ $Revision: 10667 $)
+(As of $LastChangedDate: 2009-04-20 16:21:32 +0100 (Mon, 20 Apr 2009) $ $Revision: 10667 $)
=cut
@@ -43,6 +43,35 @@
=head1 CHANGES
+=head2 Changes in DBD::ODBC 1.20 April 7, 2009
+
+Fix bug in handling of SQL_WLONGVARCHAR when not built with unicode
+support. The column was not identified as a long column and hence the
+size of the column was not restricted to LongReadLen. Can cause
+DBD::ODBC to attempt to allocate a huge amount of memory.
+
+Minor changes to Makefile.PL to help diagnose how it decided which
+driver manager to use and where it was found.
+
+Offer suggestion to debian-based systems when some of unixODBC is
+found (the bin part) but the development part is missing.
+
+In 20SqlServer.t attempt to drop any procedures we created if they
+still exist at the end of the test. Reported by Michael Higgins.
+
+In 12blob.t separate code to delete test table into sub and call at
+being and end, handle failures from prepare there were two ENDs.
+
+In ODBCTEST.pm when no acceptable test column type is found output all
+the found types and BAIL_OUT the entire test.
+
+Skip rt_39841.t unless actually using the SQL Server ODBC driver or
+native client.
+
+Handle drivers which return 0 for SQL_MAX_COLUMN_NAME_LEN.
+
+Double the buffer size used for column names if built with unicode.
+
=head2 Changes in DBD::ODBC 1.19 April 2, 2009
Some minor diagnostic output during tests when running against freeTDS
@@ -60,10 +89,10 @@
In 02simple.t cope with ODBC drivers or databases that do not need a
username or password (MS Access).
-In 20SqlServer.t fix skip count and an erroneouse assignement for
+In 20SqlServer.t fix skip count and an erroneous assignment for
driver_name.
-Changes some if tests to Test::More->is tests in 02simple.t.
+Change some if tests to Test::More->is tests in 02simple.t.
Fix "invalid precision" error during tests with the new ACEODBC.DLL MS
Access driver. Same workaround applied for the old MS Access driver
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/DBD-ODBC-1.19/dbdimp.c new/DBD-ODBC-1.20/dbdimp.c
--- old/DBD-ODBC-1.19/dbdimp.c 2009-04-02 12:54:58.000000000 +0200
+++ new/DBD-ODBC-1.20/dbdimp.c 2009-04-20 17:21:34.000000000 +0200
@@ -1,4 +1,4 @@
-/* $Id: dbdimp.c 12667 2009-04-02 10:54:56Z mjevans $
+/* $Id: dbdimp.c 12710 2009-04-20 15:21:32Z mjevans $
*
* portions Copyright (c) 1994,1995,1996,1997 Tim Bunce
* portions Copyright (c) 1997 Thomas K. Wenrich
@@ -1942,7 +1942,7 @@
dbd_error(h, rc, "dbd_describe/SQLNumResultCols");
return 0;
} else if (DBIc_TRACE(imp_sth, 0, 0, 4))
- TRACE1(imp_sth, " dbd_describe SQLNumResultCols=0 (rows=%d)\n",
+ TRACE1(imp_sth, " dbd_describe SQLNumResultCols=0 (columns=%d)\n",
num_fields);
/*
@@ -2043,8 +2043,9 @@
(SQLSMALLINT)imp_dbh->max_column_name_len,
&fbh->ColNameLen,
&fbh->ColSqlType,
+ /* column size or precision depending on type */
&fbh->ColDef,
- &fbh->ColScale,
+ &fbh->ColScale, /* decimal digits */
&fbh->ColNullable);
#endif /* WITH_UNICODE */
if (!SQL_SUCCEEDED(rc)) { /* should never fail */
@@ -2056,14 +2057,15 @@
cur_col_name += fbh->ColNameLen * sizeof(SQLWCHAR);
#else
cur_col_name += fbh->ColNameLen + 1;
- cur_col_name[fbh->ColNameLen] = '\0';
+ cur_col_name[fbh->ColNameLen] = '\0'; /* should not be necessary */
#endif
#ifdef SQL_COLUMN_DISPLAY_SIZE
if (DBIc_TRACE(imp_sth, 0, 0, 8))
PerlIO_printf(DBIc_LOGPIO(imp_dbh),
" DescribeCol column = %d, name = %s, "
- "len = %d, type = %s(%d), "
- "column size = %ld, scale = %d, nullable = %d\n",
+ "namelen = %d, type = %s(%d), "
+ "precision/column size = %ld, scale = %d, "
+ "nullable = %d\n",
i+1, fbh->ColName,
fbh->ColNameLen,
S_SqlTypeToString(fbh->ColSqlType),
@@ -2200,9 +2202,11 @@
/* MS SQL returns bytes, Oracle returns characters ... */
fbh->ColLength*=sizeof(SQLWCHAR);
fbh->ColDisplaySize = DBIc_LongReadLen(imp_sth)+1;
- break;
+# else
+ fbh->ColDisplaySize = DBIc_LongReadLen(imp_sth) + 1;
# endif /* WITH_UNICODE */
-#endif
+ break;
+#endif /* SQL_WLONGVARCHAR */
case SQL_VARCHAR:
if (fbh->ColDef == 0) {
fbh->ColDisplaySize = DBIc_LongReadLen(imp_sth)+1;
@@ -2284,6 +2288,11 @@
sizeof(int))) % sizeof(int);
/* Bind output column variables */
+ if (DBIc_TRACE(imp_sth, 0, 0, 4))
+ PerlIO_printf(DBIc_LOGPIO(imp_dbh),
+ "Bind %d: type = %s(%d), buf=%p, buflen=%ld\n",
+ i+1, S_SqlTypeToString(fbh->ftype), fbh->ftype,
+ fbh->data, fbh->ColDisplaySize);
rc = SQLBindCol(imp_sth->hstmt,
(SQLSMALLINT)(i+1),
fbh->ftype, fbh->data,
@@ -2748,7 +2757,7 @@
if (DBIc_TRACE(imp_sth, 0, 0, 4))
PerlIO_printf(
DBIc_LOGPIO(imp_dbh), " fetch col#%d %s datalen=%d displ=%d\n",
- i, fbh->ColName, fbh->datalen, fbh->ColDisplaySize);
+ i+1, fbh->ColName, fbh->datalen, fbh->ColDisplaySize);
if (fbh->datalen == SQL_NULL_DATA) { /* NULL value */
SvOK_off(sv);
@@ -5211,6 +5220,8 @@
imp_dbh->driver_type = DT_MS_ACCESS_JET;
} else if (strcmp(imp_dbh->odbc_driver_name, "ACEODBC.DLL") == 0) {
imp_dbh->driver_type = DT_MS_ACCESS_ACE;
+ } else if (strcmp(imp_dbh->odbc_driver_name, "esoobclient") == 0) {
+ imp_dbh->driver_type = DT_ES_OOB;
} else {
imp_dbh->driver_type = DT_DONT_CARE;
}
@@ -5236,16 +5247,22 @@
if (!SQL_SUCCEEDED(rc)) {
dbd_error(dbh, rc, "post_connect/SQLGetInfo(MAX_COLUMN_NAME_LEN)");
imp_dbh->max_column_name_len = 256;
+ } else if (imp_dbh->max_column_name_len == 0) {
+ imp_dbh->max_column_name_len = 256;
} else {
if (DBIc_TRACE(imp_dbh, 0x04000000, 0, 0))
TRACE1(imp_dbh, "MAX_COLUMN_NAME_LEN = %d\n",
imp_dbh->max_column_name_len);
}
- if (imp_dbh->max_column_name_len > 256) {
- imp_dbh->max_column_name_len = 256;
+#ifdef WITH_UNICODE
+ imp_dbh->max_column_name_len = imp_dbh->max_column_name_len *
+ sizeof(SQLWCHAR) + 2;
+#endif
+ if (imp_dbh->max_column_name_len > 512) {
+ imp_dbh->max_column_name_len = 512;
DBIh_SET_ERR_CHAR(
dbh, (imp_xxh_t*)imp_drh, "0", 1,
- "Max column name length pegged at 256", Nullch, Nullch);
+ "Max column name length pegged at 512", Nullch, Nullch);
}
/* default ignoring named parameters to false */
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/DBD-ODBC-1.19/dbdimp.h new/DBD-ODBC-1.20/dbdimp.h
--- old/DBD-ODBC-1.19/dbdimp.h 2009-04-02 12:54:58.000000000 +0200
+++ new/DBD-ODBC-1.20/dbdimp.h 2009-04-20 17:21:34.000000000 +0200
@@ -1,5 +1,5 @@
/*
- * $Id: dbdimp.h 12667 2009-04-02 10:54:56Z mjevans $
+ * $Id: dbdimp.h 12710 2009-04-20 15:21:32Z mjevans $
* portions Copyright (c) 2007-2008 Martin J. Evans
* Copyright (c) 1997-2001 Jeff Urlwin
* portions Copyright (c) 1997 Thomas K. Wenrich
@@ -83,7 +83,8 @@
DT_SQL_SERVER, /* SQLSRV32.DLL */
DT_SQL_SERVER_NATIVE_CLIENT, /* sqlncli10.dll | SQLNCLI.DLL */
DT_MS_ACCESS_JET, /* odbcjt32.dll */
- DT_MS_ACCESS_ACE /* ACEODBC.DLL */
+ DT_MS_ACCESS_ACE, /* ACEODBC.DLL */
+ DT_ES_OOB /* Easysoft OOB */
} driver_type;
char odbc_driver_name[80];
char odbc_driver_version[20];
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/DBD-ODBC-1.19/Makefile.PL new/DBD-ODBC-1.20/Makefile.PL
--- old/DBD-ODBC-1.19/Makefile.PL 2009-04-02 12:54:58.000000000 +0200
+++ new/DBD-ODBC-1.20/Makefile.PL 2009-04-20 17:21:34.000000000 +0200
@@ -1,6 +1,6 @@
#!/usr/local/bin/perl -w
#
-# $Id: Makefile.PL 12667 2009-04-02 10:54:56Z mjevans $
+# $Id: Makefile.PL 12710 2009-04-20 15:21:32Z mjevans $
#
# You may distribute under the terms of either the GNU General Public
# License or the Artistic License, as specified in the Perl README file.
@@ -242,33 +242,43 @@
# exist until 2.2.11 and it was broken wrt --cflags in 2.2.11/2.2.12
# i.e. --cflags did not include -I/xxx/yyy
my $odbc_config_v = `odbc_config --version 2>&1`;
+ print "Looking for odbc_config\n";
if ($odbc_config_v && ($odbc_config_v =~ /^(\d\.)+/)) {
+ print " Found odbc_config versions $odbc_config_v\n";
$odbchome = `odbc_config --prefix 2>&1`;
+ print " odbc_config reports --prefix=$odbchome\n";
chomp $odbchome;
if ((-e $odbchome) && (-e "$odbchome/include") &&
(-f "$odbchome/include/sql.h") &&
(-f "$odbchome/include/sqlext.h") &&
(-f "$odbchome/include/sqltypes.h")) {
- print "Set ODBCHOME to $odbchome from odbc_config\n";
+ print " Set ODBCHOME to $odbchome from odbc_config\n";
} else {
+ print " but cannot find header files in that path so ignoring\n";
$odbchome = '';
}
+ } else {
+ print " odbc_config not found - ok, there are other things I can do\n";
}
if (!$odbchome) {
+ print "Still trying to guess ODBCHOME - looking for headers now\n";
if (-f '/usr/include/sql.h' &&
-f '/usr/include/sqlext.h' &&
-f '/usr/include/sqltypes.h') {
+ print " Found sql header files in /use/include\n";
$odbchome = '/usr';
} elsif (-f '/usr/local/include/sql.h' &&
-f '/usr/local/include/sqlext.h' &&
-f '/usr/local/include/sqltypes.h') {
+ print " Found sql header files in /use/local/include\n";
$odbchome = '/usr/local';
} elsif (-d '/usr/local/easysoft/unixODBC') {
+ print " Found sql header files in /use/local/easysoft/include\n";
$odbchome = '/usr/local/easysoft/unixODBC';
}
}
}
- print "Found what looks like a driver manager in $odbchome\n"
+ print "Found what looks like a driver manager files in $odbchome\n"
if $odbchome;
}
@@ -304,7 +314,7 @@
my @lines = <$fh>;
my @found = grep(/iODBC driver manager/i, @lines);
if (scalar(@found)) {
- die "\n\nDBD::ODBC does not support unicode on darwin with iODBC and this looks like iODBC. The iODBC driver manager expects wide characters to be 4 bytes long and DBD::ODBC wants wide characters to be UTF16.\nEither\no) Rerun without the -u switch\no) complain to the producer of your ODBC driver manager\no) get another ODBC driver manager (like unixODBC).\n\n";
+ die "\n\nDBD::ODBC does not support unicode with iODBC and this looks like iODBC. The iODBC driver manager expects wide characters to be 4 bytes long and DBD::ODBC wants wide characters to be UTF16.\nEither\no) Rerun without the -u switch\no) complain to the producer of your ODBC driver manager\no) get another ODBC driver manager (like unixODBC).\n\n";
}
close $fh;
}
@@ -430,14 +440,18 @@
elsif ($myodbc eq 'unixodbc') {
# if we find odbcinst, output useful info about this version of unixODBC
# and store unixODBC version
+ print "Look for odbcinst\n";
if (-x "$odbchome/bin/odbcinst") {
my $j = `$odbchome/bin/odbcinst -j 2>&1`;
- print "odbcinst -j reports:\n\n$j\n" if $j;
+ print " odbcinst -j reports:\n\n$j\n" if $j;
if ($j =~ /^unixODBC ([\d\.]+).*/ ) {
$myodbc_version = $1;
}
+ } else {
+ print " odbcinst not found - ok, I can deal with that.\n";
}
# if we find odbc_config add --cflags output to CC line
+ print "Looking for odbc_config\n";
if (-x "$odbchome/bin/odbc_config") {
my @args = qw(--prefix --include-prefix --lib-prefix --version --odbcversion);
for my $oca (@args) {
@@ -455,10 +469,17 @@
print qq/Adding odbc_config --cflags "$cf" to CC line\n/;
$opts{DEFINE} .= " $cf";
}
+ } else {
+ print " odbc_config not found - ok\n";
+ }
+ my @libs = glob "$odbchome/lib/libodbc.*";
+ my @ilibs = grep { /\.($Config{so}|$Config{dlext}|a)$/ } @libs;
+ if (scalar(@ilibs) == 0) {
+ die "That's odd, I can't see any unixodbc libs in $odbchome." .
+ "This is all I found:\n" . join(",", @libs) . "\n" .
+ "Perhaps you need to install the unixODBC development " .
+ "package, often called unixodbc-dev.";
}
- my @ilibs = glob "$odbchome/lib/libodbc.*";
- @ilibs = grep { /\.($Config{so}|$Config{dlext}|a)$/ } @ilibs;
- die "That's odd, I can't see any unixodbc libs in $odbchome" unless @ilibs;
print << "EOT";
We expect to find the sql.h, sqlext.h, sqltypes.h and sqlucode.h (which were
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/DBD-ODBC-1.19/META.yml new/DBD-ODBC-1.20/META.yml
--- old/DBD-ODBC-1.19/META.yml 2009-04-02 12:45:00.000000000 +0200
+++ new/DBD-ODBC-1.20/META.yml 2009-04-07 10:54:21.000000000 +0200
@@ -1,7 +1,7 @@
--- #YAML:1.0
name: DBD-ODBC
abstract: ODBC DBD for Perl DBI
-version: 1.19
+version: 1.20
version_from: ODBC.pm
author:
- Tim Bunce
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/DBD-ODBC-1.19/ODBC.pm new/DBD-ODBC-1.20/ODBC.pm
--- old/DBD-ODBC-1.19/ODBC.pm 2009-04-02 12:54:58.000000000 +0200
+++ new/DBD-ODBC-1.20/ODBC.pm 2009-04-07 11:04:11.000000000 +0200
@@ -1,4 +1,4 @@
-# $Id: ODBC.pm 12667 2009-04-02 10:54:56Z mjevans $
+# $Id: ODBC.pm 12674 2009-04-07 09:04:09Z mjevans $
#
# Copyright (c) 1994,1995,1996,1998 Tim Bunce
# portions Copyright (c) 1997-2004 Jeff Urlwin
@@ -12,7 +12,7 @@
require 5.006;
-$DBD::ODBC::VERSION = '1.19';
+$DBD::ODBC::VERSION = '1.20';
{
package DBD::ODBC;
@@ -23,7 +23,7 @@
@ISA = qw(Exporter DynaLoader);
- # my $Revision = substr(q$Id: ODBC.pm 12667 2009-04-02 10:54:56Z mjevans $, 13,2);
+ # my $Revision = substr(q$Id: ODBC.pm 12674 2009-04-07 09:04:09Z mjevans $, 13,2);
require_version DBI 1.21;
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/DBD-ODBC-1.19/t/12blob.t new/DBD-ODBC-1.20/t/12blob.t
--- old/DBD-ODBC-1.19/t/12blob.t 2009-04-02 14:29:14.000000000 +0200
+++ new/DBD-ODBC-1.20/t/12blob.t 2009-04-20 17:21:34.000000000 +0200
@@ -1,5 +1,5 @@
#!/usr/bin/perl -w -I./t
-# $Id: 12blob.t 12667 2009-04-02 10:54:56Z mjevans $
+# $Id: 12blob.t 12710 2009-04-20 15:21:32Z mjevans $
#
# blob tests
# currently tests you can insert a clob with various odbc_putdata_start settings
@@ -15,28 +15,42 @@
$tests += 1 if $has_test_nowarnings;
plan tests => $tests;
+my $dbh;
+
# can't seem to get the imports right this way
use DBI qw(:sql_types);
use_ok('ODBCTEST');
-# to help ActiveState's build process along by behaving (somewhat) if a dsn is not provided
+sub tidyup {
+ if ($dbh) {
+ #diag "Tidying up\n";
+ eval {
+ local $dbh->{PrintWarn} = 0;
+ local $dbh->{PrintError} = 0;
+ $dbh->do(q/drop table DBD_ODBC_drop_me/);
+ };
+ }
+}
+
BEGIN {
if (!defined $ENV{DBI_DSN}) {
plan skip_all => "DBI_DSN is undefined";
}
}
END {
+ tidyup();
Test::NoWarnings::had_no_warnings()
if ($has_test_nowarnings);
}
my $ev;
-my $dbh = DBI->connect();
+$dbh = DBI->connect();
unless($dbh) {
BAIL_OUT("Unable to connect to the database $DBI::errstr\nTests skipped.\n");
exit 0;
}
+tidyup();
my $putdata_start = $dbh->{odbc_putdata_start};
is($putdata_start, 32768, 'default putdata_start');
@@ -92,14 +106,19 @@
$sth = $dbh->prepare(q/insert into DBD_ODBC_drop_me values(?)/);
ok($sth, "prepare for insert");
- $rc = $sth->execute($val);
- ok($rc, "insert clob");
SKIP: {
- skip "insert failed - skipping the retrieval test", 2 unless $rc;
+ skip "prepare failed", 3 unless $sth;
- test_value($dbh, $val);
- };
+ $rc = $sth->execute($val);
+ ok($rc, "insert clob");
+
+ SKIP: {
+ skip "insert failed - skipping the retrieval test", 2 unless $rc;
+ test_value($dbh, $val);
+ };
+ };
+ $sth = undef;
eval {$dbh->do(q/delete from DBD_ODBC_drop_me/); };
$ev = $@;
diag($ev) if $ev;
@@ -126,11 +145,3 @@
return;
}
-
-END {
- if ($dbh) {
- local $dbh->{PrintError} = 0;
- local $dbh->{PrintWarn} = 0;
- eval {$dbh->do(q/drop table DBD_ODBC_drop_me/);};
- };
-};
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/DBD-ODBC-1.19/t/20SqlServer.t new/DBD-ODBC-1.20/t/20SqlServer.t
--- old/DBD-ODBC-1.19/t/20SqlServer.t 2009-03-31 16:08:56.000000000 +0200
+++ new/DBD-ODBC-1.20/t/20SqlServer.t 2009-04-07 10:59:18.000000000 +0200
@@ -1,5 +1,5 @@
#!/usr/bin/perl -w -I./t
-# $Id: 20SqlServer.t 12639 2009-03-27 20:23:07Z mjevans $
+# $Id: 20SqlServer.t 12672 2009-04-07 08:59:17Z mjevans $
use Test::More;
use strict;
@@ -13,6 +13,8 @@
$tests += 1 if $has_test_nowarnings;
plan tests => $tests;
+my $dbh;
+
# use_ok('DBI', qw(:sql_types));
# can't seem to get the imports right this way
use DBI qw(:sql_types);
@@ -24,6 +26,14 @@
if (!defined $ENV{DBI_DSN});
}
END {
+ if ($dbh) {
+ local $dbh->{PrintError} = 0;
+ local $dbh->{PrintWarn} = 0;
+ eval {
+ $dbh->do(q/drop procedure PERL_DBD_PROC1/);
+ $dbh->do(q/drop procedure PERL_DBD_PROC2/);
+ };
+ }
Test::NoWarnings::had_no_warnings()
if ($has_test_nowarnings);
}
@@ -205,7 +215,7 @@
return 1;
}
-my $dbh = DBI->connect();
+$dbh = DBI->connect();
unless($dbh) {
BAIL_OUT("Unable to connect to the database $DBI::errstr\nTests skipped.\n");
exit 0;
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/DBD-ODBC-1.19/t/ODBCTEST.pm new/DBD-ODBC-1.20/t/ODBCTEST.pm
--- old/DBD-ODBC-1.19/t/ODBCTEST.pm 2009-03-31 15:10:10.000000000 +0200
+++ new/DBD-ODBC-1.20/t/ODBCTEST.pm 2009-04-09 20:46:06.000000000 +0200
@@ -51,6 +51,7 @@
my @row;
my $sth;
foreach $type (@{ $TestFieldInfo{$column} }) {
+ #diag("Looking for type $type\n");
$sth = $dbh->func($type, GetTypeInfo);
# may not be correct behavior, but get the first compat type
if ($sth) {
@@ -61,8 +62,14 @@
# warn "Unable to get type for type $type\n";
}
}
- die "Unable to find a suitable test type for field $column"
- unless @row;
+ if (scalar(@row) == 0) {
+ my $types = $dbh->type_info_all;
+ foreach my $t (@$types) {
+ next if ref($t) ne 'ARRAY';
+ diag(join(",", map{$_ ? $_ : "undef"} @$t). "\n");
+ }
+ BAIL_OUT("Unable to find a suitable test type for field $column");
+ }
# warn join(", ",@row);
return @row;
}
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/DBD-ODBC-1.19/t/rt_38977.t new/DBD-ODBC-1.20/t/rt_38977.t
--- old/DBD-ODBC-1.19/t/rt_38977.t 2009-03-06 18:24:45.000000000 +0100
+++ new/DBD-ODBC-1.20/t/rt_38977.t 2009-04-20 17:21:34.000000000 +0200
@@ -1,5 +1,5 @@
#!/usr/bin/perl -w -I./t
-# $Id: rt_38977.t 12185 2008-12-19 19:39:22Z mjevans $
+# $Id: rt_38977.t 12710 2009-04-20 15:21:32Z mjevans $
#
# test varbinary(MAX) and varchar(MAX) types in SQL Server
#
@@ -58,6 +58,7 @@
SKIP: {
skip "not SQL Server", 6 if $dbms_name !~ /Microsoft SQL Server/;
+ skip "Easysoft OOB", 6 if $driver_name =~ /esoobclient/;
my $major_version = $dbms_version;
$major_version =~ s/^(\d+)\..*$/$1/;
#diag("Major Version: $major_version\n");
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/DBD-ODBC-1.19/t/rt_39841.t new/DBD-ODBC-1.20/t/rt_39841.t
--- old/DBD-ODBC-1.19/t/rt_39841.t 2008-12-19 20:39:23.000000000 +0100
+++ new/DBD-ODBC-1.20/t/rt_39841.t 2009-04-20 17:21:34.000000000 +0200
@@ -1,5 +1,5 @@
#!/usr/bin/perl -w -I./t
-# $Id: rt_39841.t 12185 2008-12-19 19:39:22Z mjevans $
+# $Id: rt_39841.t 12710 2009-04-20 15:21:32Z mjevans $
#
# Test fix for rt 39841 - problem with SQLDecribeParam in MS SQL Server
#
@@ -53,11 +53,17 @@
my $dbms_version = $dbh->get_info(18);
#3
ok($dbms_version, "got DBMS version: $dbms_version");
+my $driver_name = DBI::neat($dbh->get_info(6));
my ($ev, $sth);
SKIP: {
skip "not SQL Server", 25 if $dbms_name !~ /Microsoft SQL Server/;
+ skip "not SQL Server ODBC or native client driver", 25
+ if ($driver_name !~ /SQLSRV32.DLL/oi) &&
+ ($driver_name !~ /sqlncli10.dll/oi) &&
+ ($driver_name !~ /SQLNCLI>DLL/oi);
+
my $major_version = $dbms_version;
eval {
++++++ perl-DBD-ODBC-1.19-Makefile.diff -> perl-DBD-ODBC-1.20-Makefile.diff ++++++
--- perl-DBD-ODBC/perl-DBD-ODBC-1.19-Makefile.diff 2009-01-20 17:30:16.000000000 +0100
+++ perl-DBD-ODBC/perl-DBD-ODBC-1.20-Makefile.diff 2009-04-28 13:51:30.000000000 +0200
@@ -8,7 +8,7 @@
DEFINE => ''
);
my $eumm = $ExtUtils::MakeMaker::VERSION;
-@@ -218,6 +219,7 @@
+@@ -223,6 +224,7 @@
print "Overriding ODBC Directory with command line option: $opt_o\n" if $opt_o ;
my $odbchome= $opt_o || $ENV{ODBCHOME};
@@ -16,7 +16,7 @@
$odbchome = VMS::Filespec::unixify($odbchome) if $^O eq 'VMS';
-@@ -230,7 +232,7 @@
+@@ -235,7 +237,7 @@
$tmp_odbchome =~ s/^([A-Za-z]):*$/\/\/$1/;
$tmp_odbchome =~ s/\\/\//g;
$odbchome = $tmp_odbchome if (-e "$tmp_odbchome/odbc.ini")
@@ -25,7 +25,7 @@
$odbchome = '/opt/sapdb/interfaces/odbc/';
} elsif ($^O !~ /MSWin/) {
# unixODBC - would have liked to use odbc_config but it did not
-@@ -313,7 +315,7 @@
+@@ -328,7 +330,7 @@
# Try to work out which driver manager is being used.
# Feel free to come up with neat (or un-neat) hacks to get your's to build!
@@ -34,7 +34,7 @@
my $lib_d2 = "$odbchome/dlls";
my $libs = "odbc";
$opts{LIBS} = " -L$lib_d1 -R$lib_d1 -L$lib_d2 -R$lib_d2 -l$libs";
-@@ -332,36 +334,36 @@
+@@ -347,36 +349,36 @@
$arext =~ s/^\.//;
$myodbc = 'unixodbc'
@@ -78,7 +78,7 @@
if (!$myodbc) {
local($") = ", ";
-@@ -387,7 +389,7 @@
+@@ -402,7 +404,7 @@
$opts{dynamic_lib} = {OTHERLDFLAGS => "-lodbc32"};
}
elsif ($myodbc eq 'iodbc') {
@@ -87,7 +87,7 @@
my @ilibs = glob "$ilibdir/*iodbc*.*";
@ilibs = grep { /\.($Config{so}|$Config{dlext}|a)$/ } @ilibs;
die "That's odd, I can't see any iodbc libs in $ilibdir" unless @ilibs;
-@@ -412,7 +414,7 @@
+@@ -427,7 +429,7 @@
# changed /\Q$ilibpath/ to /\Q$ilibdir/ per recommendation
# by Ron Savage
@@ -96,16 +96,16 @@
unless $ENV{LD_LIBRARY_PATH} =~ /\Q$ilibdir/;
}
#print $sqlhfh qq{#define FAR \n#define EXPORT \n#define CALLBACK \n};
-@@ -451,7 +453,7 @@
- $opts{DEFINE} .= " $cf";
- }
+@@ -472,7 +474,7 @@
+ } else {
+ print " odbc_config not found - ok\n";
}
-- my @ilibs = glob "$odbchome/lib/libodbc.*";
-+ my @ilibs = glob "$odbchome/$lib/libodbc.*";
- @ilibs = grep { /\.($Config{so}|$Config{dlext}|a)$/ } @ilibs;
- die "That's odd, I can't see any unixodbc libs in $odbchome" unless @ilibs;
- print << "EOT";
-@@ -471,10 +473,10 @@
+- my @libs = glob "$odbchome/lib/libodbc.*";
++ my @libs = glob "$odbchome/$lib/libodbc.*";
+ my @ilibs = grep { /\.($Config{so}|$Config{dlext}|a)$/ } @libs;
+ if (scalar(@ilibs) == 0) {
+ die "That's odd, I can't see any unixodbc libs in $odbchome." .
+@@ -497,10 +499,10 @@
else {
# remove lib prefix and .so suffix so "-l" style link can be used
$ilibname =~ s/^lib(odbc.*?)\.\w+$/$1/;
@@ -118,7 +118,7 @@
}
print $sqlhfh qq{#include <sql.h>\n};
print $sqlhfh qq{#include <sqlucode.h>\n};
-@@ -546,7 +548,7 @@
+@@ -572,7 +574,7 @@
#$opts{DEFINE} .= "";
print $sqlhfh qq{#include <odbcsys.h>\n};
print $sqlhfh qq{#include <sql.h>\n#include <sqlext.h>\n};
@@ -127,7 +127,7 @@
}
elsif ($myodbc eq 'sapdb') {
print $sqlhfh "#include <WINDOWS.H>\n";
-@@ -559,7 +561,11 @@
+@@ -585,7 +587,11 @@
print $sqlhfh qq{#define DBD_ODBC_NO_DATASOURCES\n}; # unless ($^O eq 'MSWin32');
$opts{INC} .= " -I$odbchome/incl";
@@ -140,7 +140,7 @@
}
elsif ($myodbc eq 'adabas') {
print $sqlhfh "#define FAR \n#define EXPORT \n#define CALLBACK \n";
-@@ -567,23 +573,23 @@
+@@ -593,23 +599,23 @@
print $sqlhfh "#include <sql.h>\n";
print $sqlhfh "#include <sqlext.h>\n";
$opts{INC} .= " -I$odbchome/incl";
@@ -169,7 +169,7 @@
# Solid does not support DataSources
print $sqlhfh qq{#define DBD_ODBC_NO_DATASOURCES\n};
# Solid does not support DataSources
-@@ -593,7 +599,7 @@
+@@ -619,7 +625,7 @@
elsif ($myodbc eq 'informix') {
# JL 2002-12-16: See comments above for environment details.
$opts{INC} = "-I$odbchome/incl/cli $opts{INC}";
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Remember to have fun...
--
To unsubscribe, e-mail: opensuse-commit+unsubscribe(a)opensuse.org
For additional commands, e-mail: opensuse-commit+help(a)opensuse.org