Install DBD::mysql on Mac 10.3.2

Install DBD::mysql on Mac 10.3.2

am 11.03.2004 17:02:01 von Greg Rice

I'm having some difficulty installing DBD::mysql on a Mac 10.3.2 system
with Perl 5.8.1. I attempted to install with CPAN, but the make
failed. After searching list archives, I edited
/System/Library/Perl/5.8.1/darwin-thread-multi-2level/Config .pm,
changing

ld='MOACOSX_DEPLOYMENT_TARGET=10.3 cc'

to

ld='env MOACOSX_DEPLOYMENT_TARGET=10.3 cc'

then ran perl Makefile.PL, followed by make, apparently successfully.
Running make test, however, still shows a problem:

Homer:~/.cpan/build/DBD-mysql-2.9003 greg$ make test
PERL_DL_NONLAZY=1 /usr/bin/perl "-MExtUtils::Command::MM" "-e"
"test_harness(0, 'blib/lib', 'blib/arch')" t/*.t
t/00base...........ok
t/10dsnlist........ok
t/20createdrop.....ok
t/30insertfetch....ok
t/40bindparam......ok
t/40blobs..........ok
t/40listfields.....ok
t/40nulls..........ok
t/40numrows........ok
t/50chopblanks.....ok
t/50commit.........ok
t/60leaks..........skipped
all skipped: $ENV{SLOW_TESTS} is not set or Proc::ProcessTable
not installed
t/ak-dbd...........ok
t/akmisc...........ok
t/dbdadmin.........ok
t/insertid.........ok
t/mysql............FAILED tests 46-48
Failed 3/68 tests, 95.59% okay
t/mysql2...........ok
Failed Test Stat Wstat Total Fail Failed List of Failed
------------------------------------------------------------ ------------
-------
t/mysql.t 68 3 4.41% 46-48
1 test skipped.
Failed 1/18 test scripts, 94.44% okay. 3/767 subtests failed, 99.61%
okay.
make: *** [test_dynamic] Error 2

I've looked at t/mysql.t, but am unable to recognize which tests are
failing. Is this a problem with the test, with my existing installation
of MySQL or DBI, or with DBD::mysql? How do I tell?

Any hints appreciated.

Greg


--
MySQL Perl Mailing List
For list archives: http://lists.mysql.com/perl
To unsubscribe: http://lists.mysql.com/perl?unsub=gcdmp-msql-mysql-modules@m .gmane.org

Re: Install DBD::mysql on Mac 10.3.2

am 11.03.2004 20:31:33 von Greg Rice

Zitat von Greg Rice :
>
>> I've looked at t/mysql.t, but am unable to recognize which tests are
>> failing. Is this a problem with the test, with my existing
>> installation
>> of MySQL or DBI, or with DBD::mysql? How do I tell?

On Mar 11, 2004, at 2:08 PM, Jochen Wiedmann wrote:

> make test TEST_VERBOSE=1

What I believe is the relevant section of the result is at the bottom
of the message. It shows, as did the more abbreviated version, that
tests 46-48 of mysql.t are failing. I do not, however, know how to
relate this to a specific problem. I think it is arising from this
section of mysql.t :

my($sth_query,$sth_listf,$method);

# So many people have problems using the ListFields method,
# so we finally provide a simple example.
$sth_query = $dbh->query("select * from $firsttable");
$sth_listf = $dbh->listfields($firsttable);
$i = 43;
for $method (qw/name table length type is_not_null is_pri_key/) {
for (0..$sth_query->numfields -1) {
# whatever we do to the one statementhandle, the other one has
# to behave exactly the same way
if ($sth_query->$method()->[$_] eq $sth_listf->$method()->[$_]) {
print "ok $i\n" ;
} else {
print "not ok $i\n";
}
$i++;
}
}

Greg

----------------------------------------------
A portion of the output from make test TEST_VERBOSE=1
All other tests report ok
----------------------------------------------
t/mysql............1..68
ok 1
ok 2
ok 3
Writing some test records.
ok 4
ok 5
Checking numfields.
ok 6
Checking table.
ok 7
ok 8
Checking type.
ok 9
Checking number of rows.
ok 10
ok 11
ok 12
ok 13
ok 14
ok 15
ok 16
ok 17
ok 18
ok 19
ok 20
ok 21
ok 22
ok 23
ok 24
ok 25
ok 26
ok 27
ok 28
ok 29
ok 30
ok 31
ok 32
ok 33
ok 34
ok 35
ok 36
ok 37
ok 38
ok 39
ok 40
ok 41
ok 42
ok 43
ok 44
ok 45
not ok 46
not ok 47
not ok 48
ok 49
ok 50
ok 51
ok 52
ok 53
ok 54
ok 55
ok 56
ok 57
ok 58
ok 59
ok 60
ok 61
ok 62
ok 63
ok 64
ok 65
ok 66
ok 67
ok 68
FAILED tests 46-48
Failed 3/68 tests, 95.59% okay


--
MySQL Perl Mailing List
For list archives: http://lists.mysql.com/perl
To unsubscribe: http://lists.mysql.com/perl?unsub=gcdmp-msql-mysql-modules@m .gmane.org

Re: Install DBD::mysql on Mac 10.3.2

am 11.03.2004 20:31:33 von Greg Rice

Zitat von Greg Rice :
>
>> I've looked at t/mysql.t, but am unable to recognize which tests are
>> failing. Is this a problem with the test, with my existing
>> installation
>> of MySQL or DBI, or with DBD::mysql? How do I tell?

On Mar 11, 2004, at 2:08 PM, Jochen Wiedmann wrote:

> make test TEST_VERBOSE=1

What I believe is the relevant section of the result is at the bottom
of the message. It shows, as did the more abbreviated version, that
tests 46-48 of mysql.t are failing. I do not, however, know how to
relate this to a specific problem. I think it is arising from this
section of mysql.t :

my($sth_query,$sth_listf,$method);

# So many people have problems using the ListFields method,
# so we finally provide a simple example.
$sth_query = $dbh->query("select * from $firsttable");
$sth_listf = $dbh->listfields($firsttable);
$i = 43;
for $method (qw/name table length type is_not_null is_pri_key/) {
for (0..$sth_query->numfields -1) {
# whatever we do to the one statementhandle, the other one has
# to behave exactly the same way
if ($sth_query->$method()->[$_] eq $sth_listf->$method()->[$_]) {
print "ok $i\n" ;
} else {
print "not ok $i\n";
}
$i++;
}
}

Greg

----------------------------------------------
A portion of the output from make test TEST_VERBOSE=1
All other tests report ok
----------------------------------------------
t/mysql............1..68
ok 1
ok 2
ok 3
Writing some test records.
ok 4
ok 5
Checking numfields.
ok 6
Checking table.
ok 7
ok 8
Checking type.
ok 9
Checking number of rows.
ok 10
ok 11
ok 12
ok 13
ok 14
ok 15
ok 16
ok 17
ok 18
ok 19
ok 20
ok 21
ok 22
ok 23
ok 24
ok 25
ok 26
ok 27
ok 28
ok 29
ok 30
ok 31
ok 32
ok 33
ok 34
ok 35
ok 36
ok 37
ok 38
ok 39
ok 40
ok 41
ok 42
ok 43
ok 44
ok 45
not ok 46
not ok 47
not ok 48
ok 49
ok 50
ok 51
ok 52
ok 53
ok 54
ok 55
ok 56
ok 57
ok 58
ok 59
ok 60
ok 61
ok 62
ok 63
ok 64
ok 65
ok 66
ok 67
ok 68
FAILED tests 46-48
Failed 3/68 tests, 95.59% okay


--
MySQL Perl Mailing List
For list archives: http://lists.mysql.com/perl
To unsubscribe: http://lists.mysql.com/perl?unsub=gcdmp-msql-mysql-modules@m .gmane.org

Re: Install DBD::mysql on Mac 10.3.2

am 11.03.2004 22:01:34 von Jochen Wiedmann

Greg Rice wrote:

> What I believe is the relevant section of the result is at the bottom of
> the message. It shows, as did the more abbreviated version, that tests
> 46-48 of mysql.t are failing. I do not, however, know how to relate this
> to a specific problem. I think it is arising from this section of mysql.t :

I think you are right. It seems as if the "type", "is_not_null", and
"is_pri_key" methods are failing.

Could you modify the script and let the loop emit the respective values
that it finds?


Jochen


--
MySQL Perl Mailing List
For list archives: http://lists.mysql.com/perl
To unsubscribe: http://lists.mysql.com/perl?unsub=gcdmp-msql-mysql-modules@m .gmane.org

Re: Install DBD::mysql on Mac 10.3.2

am 11.03.2004 22:01:34 von Jochen Wiedmann

Greg Rice wrote:

> What I believe is the relevant section of the result is at the bottom of
> the message. It shows, as did the more abbreviated version, that tests
> 46-48 of mysql.t are failing. I do not, however, know how to relate this
> to a specific problem. I think it is arising from this section of mysql.t :

I think you are right. It seems as if the "type", "is_not_null", and
"is_pri_key" methods are failing.

Could you modify the script and let the loop emit the respective values
that it finds?


Jochen


--
MySQL Perl Mailing List
For list archives: http://lists.mysql.com/perl
To unsubscribe: http://lists.mysql.com/perl?unsub=gcdmp-msql-mysql-modules@m .gmane.org

Re: Install DBD::mysql on Mac 10.3.2

am 12.03.2004 15:07:51 von Greg Rice

On Mar 11, 2004, at 4:01 PM, Jochen Wiedmann wrote:
>
> Could you modify the script and let the loop emit the respective values
> that it finds?
>
>
> Jochen

Looks like a case mismatch in tests 46-48 of mysql.t. I went ahead and
ran make install. Thanks for your patience.

Greg
------------------------------------------------------------ ------------
-----------------------
Section of script modified to:

my($sth_query,$sth_listf,$method);
use Data::Dumper;

# So many people have problems using the ListFields method,
# so we finally provide a simple example.
$sth_query = $dbh->query("select * from $firsttable");
$sth_listf = $dbh->listfields($firsttable);
print "\n".'Dumping $sth_query: '.Dumper($sth_query);
print 'Dumping $sth_listf: '.Dumper($sth_listf)."\n";
$i = 43;
for $method (qw/name table length type is_not_null is_pri_key/) {
for (0..$sth_query->numfields -1) {
# whatever we do to the one statementhandle, the other one has
# to behave exactly the same way

if ($sth_query->$method()->[$_] eq $sth_listf->$method()->[$_]) {
print "ok $i\n" ;
} else {
print "not ok $i\n";
}
print 'Dumping $sth_query->$method()->[$_]:
'.Dumper($sth_query->$method()->[$_]);
print 'Dumping $sth_listf->$method()->[$_]:
'.Dumper($sth_listf->$method()->[$_]);
print " method: $method\n";
print ' field: '."$_\n\n";

$i++;
}
}
------------------------------------------------------------ ------------
-----------------------
Relevant section of output from make test TEST_VERBOSE=1:

Dumping $sth_query: $VAR1 = bless( {}, 'Mysql::Statement' );
Dumping $sth_listf: $VAR1 = bless( {}, 'Mysql::Statement' );

ok 43
Dumping $sth_query->$method()->[$_]: $VAR1 = 'she';
Dumping $sth_listf->$method()->[$_]: $VAR1 = 'she';
method: name
field: 0

ok 44
Dumping $sth_query->$method()->[$_]: $VAR1 = 'him';
Dumping $sth_listf->$method()->[$_]: $VAR1 = 'him';
method: name
field: 1

ok 45
Dumping $sth_query->$method()->[$_]: $VAR1 = 'who';
Dumping $sth_listf->$method()->[$_]: $VAR1 = 'who';
method: name
field: 2

not ok 46
Dumping $sth_query->$method()->[$_]: $VAR1 = 'TABLE01';
Dumping $sth_listf->$method()->[$_]: $VAR1 = 'table01';
method: table
field: 0

not ok 47
Dumping $sth_query->$method()->[$_]: $VAR1 = 'TABLE01';
Dumping $sth_listf->$method()->[$_]: $VAR1 = 'table01';
method: table
field: 1

not ok 48
Dumping $sth_query->$method()->[$_]: $VAR1 = 'TABLE01';
Dumping $sth_listf->$method()->[$_]: $VAR1 = 'table01';
method: table
field: 2

ok 49
Dumping $sth_query->$method()->[$_]: $VAR1 = 14;
Dumping $sth_listf->$method()->[$_]: $VAR1 = 14;
method: length
field: 0

ok 50
Dumping $sth_query->$method()->[$_]: $VAR1 = 11;
Dumping $sth_listf->$method()->[$_]: $VAR1 = 11;
method: length
field: 1

ok 51
Dumping $sth_query->$method()->[$_]: $VAR1 = 1;
Dumping $sth_listf->$method()->[$_]: $VAR1 = 1;
method: length
field: 2

ok 52
Dumping $sth_query->$method()->[$_]: $VAR1 = 254;
Dumping $sth_listf->$method()->[$_]: $VAR1 = 254;
method: type
field: 0

ok 53
Dumping $sth_query->$method()->[$_]: $VAR1 = 3;
Dumping $sth_listf->$method()->[$_]: $VAR1 = 3;
method: type
field: 1

ok 54
Dumping $sth_query->$method()->[$_]: $VAR1 = 254;
Dumping $sth_listf->$method()->[$_]: $VAR1 = 254;
method: type
field: 2

ok 55
Dumping $sth_query->$method()->[$_]: $VAR1 = '1';
Dumping $sth_listf->$method()->[$_]: $VAR1 = '1';
method: is_not_null
field: 0

ok 56
Dumping $sth_query->$method()->[$_]: $VAR1 = '';
Dumping $sth_listf->$method()->[$_]: $VAR1 = '';
method: is_not_null
field: 1

ok 57
Dumping $sth_query->$method()->[$_]: $VAR1 = '';
Dumping $sth_listf->$method()->[$_]: $VAR1 = '';
method: is_not_null
field: 2

ok 58
Dumping $sth_query->$method()->[$_]: $VAR1 = '1';
Dumping $sth_listf->$method()->[$_]: $VAR1 = '1';
method: is_pri_key
field: 0

ok 59
Dumping $sth_query->$method()->[$_]: $VAR1 = '';
Dumping $sth_listf->$method()->[$_]: $VAR1 = '';
method: is_pri_key
field: 1

ok 60
Dumping $sth_query->$method()->[$_]: $VAR1 = '';
Dumping $sth_listf->$method()->[$_]: $VAR1 = '';
method: is_pri_key
field: 2


--
MySQL Perl Mailing List
For list archives: http://lists.mysql.com/perl
To unsubscribe: http://lists.mysql.com/perl?unsub=gcdmp-msql-mysql-modules@m .gmane.org

Re: Install DBD::mysql on Mac 10.3.2

am 12.03.2004 15:07:51 von Greg Rice

On Mar 11, 2004, at 4:01 PM, Jochen Wiedmann wrote:
>
> Could you modify the script and let the loop emit the respective values
> that it finds?
>
>
> Jochen

Looks like a case mismatch in tests 46-48 of mysql.t. I went ahead and
ran make install. Thanks for your patience.

Greg
------------------------------------------------------------ ------------
-----------------------
Section of script modified to:

my($sth_query,$sth_listf,$method);
use Data::Dumper;

# So many people have problems using the ListFields method,
# so we finally provide a simple example.
$sth_query = $dbh->query("select * from $firsttable");
$sth_listf = $dbh->listfields($firsttable);
print "\n".'Dumping $sth_query: '.Dumper($sth_query);
print 'Dumping $sth_listf: '.Dumper($sth_listf)."\n";
$i = 43;
for $method (qw/name table length type is_not_null is_pri_key/) {
for (0..$sth_query->numfields -1) {
# whatever we do to the one statementhandle, the other one has
# to behave exactly the same way

if ($sth_query->$method()->[$_] eq $sth_listf->$method()->[$_]) {
print "ok $i\n" ;
} else {
print "not ok $i\n";
}
print 'Dumping $sth_query->$method()->[$_]:
'.Dumper($sth_query->$method()->[$_]);
print 'Dumping $sth_listf->$method()->[$_]:
'.Dumper($sth_listf->$method()->[$_]);
print " method: $method\n";
print ' field: '."$_\n\n";

$i++;
}
}
------------------------------------------------------------ ------------
-----------------------
Relevant section of output from make test TEST_VERBOSE=1:

Dumping $sth_query: $VAR1 = bless( {}, 'Mysql::Statement' );
Dumping $sth_listf: $VAR1 = bless( {}, 'Mysql::Statement' );

ok 43
Dumping $sth_query->$method()->[$_]: $VAR1 = 'she';
Dumping $sth_listf->$method()->[$_]: $VAR1 = 'she';
method: name
field: 0

ok 44
Dumping $sth_query->$method()->[$_]: $VAR1 = 'him';
Dumping $sth_listf->$method()->[$_]: $VAR1 = 'him';
method: name
field: 1

ok 45
Dumping $sth_query->$method()->[$_]: $VAR1 = 'who';
Dumping $sth_listf->$method()->[$_]: $VAR1 = 'who';
method: name
field: 2

not ok 46
Dumping $sth_query->$method()->[$_]: $VAR1 = 'TABLE01';
Dumping $sth_listf->$method()->[$_]: $VAR1 = 'table01';
method: table
field: 0

not ok 47
Dumping $sth_query->$method()->[$_]: $VAR1 = 'TABLE01';
Dumping $sth_listf->$method()->[$_]: $VAR1 = 'table01';
method: table
field: 1

not ok 48
Dumping $sth_query->$method()->[$_]: $VAR1 = 'TABLE01';
Dumping $sth_listf->$method()->[$_]: $VAR1 = 'table01';
method: table
field: 2

ok 49
Dumping $sth_query->$method()->[$_]: $VAR1 = 14;
Dumping $sth_listf->$method()->[$_]: $VAR1 = 14;
method: length
field: 0

ok 50
Dumping $sth_query->$method()->[$_]: $VAR1 = 11;
Dumping $sth_listf->$method()->[$_]: $VAR1 = 11;
method: length
field: 1

ok 51
Dumping $sth_query->$method()->[$_]: $VAR1 = 1;
Dumping $sth_listf->$method()->[$_]: $VAR1 = 1;
method: length
field: 2

ok 52
Dumping $sth_query->$method()->[$_]: $VAR1 = 254;
Dumping $sth_listf->$method()->[$_]: $VAR1 = 254;
method: type
field: 0

ok 53
Dumping $sth_query->$method()->[$_]: $VAR1 = 3;
Dumping $sth_listf->$method()->[$_]: $VAR1 = 3;
method: type
field: 1

ok 54
Dumping $sth_query->$method()->[$_]: $VAR1 = 254;
Dumping $sth_listf->$method()->[$_]: $VAR1 = 254;
method: type
field: 2

ok 55
Dumping $sth_query->$method()->[$_]: $VAR1 = '1';
Dumping $sth_listf->$method()->[$_]: $VAR1 = '1';
method: is_not_null
field: 0

ok 56
Dumping $sth_query->$method()->[$_]: $VAR1 = '';
Dumping $sth_listf->$method()->[$_]: $VAR1 = '';
method: is_not_null
field: 1

ok 57
Dumping $sth_query->$method()->[$_]: $VAR1 = '';
Dumping $sth_listf->$method()->[$_]: $VAR1 = '';
method: is_not_null
field: 2

ok 58
Dumping $sth_query->$method()->[$_]: $VAR1 = '1';
Dumping $sth_listf->$method()->[$_]: $VAR1 = '1';
method: is_pri_key
field: 0

ok 59
Dumping $sth_query->$method()->[$_]: $VAR1 = '';
Dumping $sth_listf->$method()->[$_]: $VAR1 = '';
method: is_pri_key
field: 1

ok 60
Dumping $sth_query->$method()->[$_]: $VAR1 = '';
Dumping $sth_listf->$method()->[$_]: $VAR1 = '';
method: is_pri_key
field: 2


--
MySQL Perl Mailing List
For list archives: http://lists.mysql.com/perl
To unsubscribe: http://lists.mysql.com/perl?unsub=gcdmp-msql-mysql-modules@m .gmane.org