Re: MySQL newbie: Failed to determine directory of mysql.h

jose isaias cabrera <[email protected]>
Newsgroups gmane.comp.db.mysql.perl
Message-ID <[email protected]>
Pete,

if I may and with all due respect (and sorry for the lengthy emails), but
you're missing the point:  I am trying to install DBD::mysql.  Will you take
a look at this run of cpan to try to install DBD::mysql,

odouls 14:00:31-> cpan
Terminal does not support AddHistory.

cpan shell -- CPAN exploration and modules installation (v1.7601)
ReadLine support available (try 'install Bundle::CPAN')

cpan> install DBD::mysql
CPAN: Storable loaded ok
Going to read /h/jicman/.cpan/Metadata
  Database was generated on Wed, 03 Nov 2004 09:08:40 GMT
Running install for module DBD::mysql
Running make for R/RU/RUDY/DBD-mysql-2.9004.tar.gz
CPAN: Digest::MD5 loaded ok
Checksum for
/h/jicman/.cpan/sources/authors/id/R/RU/RUDY/DBD-mysql-2.9004.tar.gz ok
x DBD-mysql-2.9004, 0 bytes, 0 tape blocks
x DBD-mysql-2.9004/t, 0 bytes, 0 tape blocks
x DBD-mysql-2.9004/t/mysql2.t, 4187 bytes, 9 tape blocks
x DBD-mysql-2.9004/t/akmisc.t, 27024 bytes, 53 tape blocks
x DBD-mysql-2.9004/t/60leaks.t, 5228 bytes, 11 tape blocks
x DBD-mysql-2.9004/t/10dsnlist.t, 2019 bytes, 4 tape blocks
x DBD-mysql-2.9004/t/ak-dbd.t, 15573 bytes, 31 tape blocks
x DBD-mysql-2.9004/t/50chopblanks.t, 3926 bytes, 8 tape blocks
x DBD-mysql-2.9004/t/mysql.t, 19474 bytes, 39 tape blocks
x DBD-mysql-2.9004/t/lib.pl, 5588 bytes, 11 tape blocks
x DBD-mysql-2.9004/t/40blobs.t, 3507 bytes, 7 tape blocks
x DBD-mysql-2.9004/t/40nulls.t, 2591 bytes, 6 tape blocks
x DBD-mysql-2.9004/t/insertid.t, 1234 bytes, 3 tape blocks
x DBD-mysql-2.9004/t/40listfields.t, 4156 bytes, 9 tape blocks
x DBD-mysql-2.9004/t/40bindparam.t, 5388 bytes, 11 tape blocks
x DBD-mysql-2.9004/t/mysql.dbtest, 3683 bytes, 8 tape blocks
x DBD-mysql-2.9004/t/dbdadmin.t, 7700 bytes, 16 tape blocks
x DBD-mysql-2.9004/t/20createdrop.t, 1833 bytes, 4 tape blocks
x DBD-mysql-2.9004/t/00base.t, 989 bytes, 2 tape blocks
x DBD-mysql-2.9004/t/30insertfetch.t, 2624 bytes, 6 tape blocks
x DBD-mysql-2.9004/t/40numrows.t, 4232 bytes, 9 tape blocks
x DBD-mysql-2.9004/t/50commit.t, 6617 bytes, 13 tape blocks
x DBD-mysql-2.9004/t/mysql.mtest, 758 bytes, 2 tape blocks
x DBD-mysql-2.9004/MANIFEST, 601 bytes, 2 tape blocks
x DBD-mysql-2.9004/myld, 1425 bytes, 3 tape blocks
x DBD-mysql-2.9004/dbdimp.c, 68146 bytes, 134 tape blocks
x DBD-mysql-2.9004/lib, 0 bytes, 0 tape blocks
x DBD-mysql-2.9004/lib/DBD, 0 bytes, 0 tape blocks
x DBD-mysql-2.9004/lib/DBD/mysql, 0 bytes, 0 tape blocks
x DBD-mysql-2.9004/lib/DBD/mysql/GetInfo.pm, 16069 bytes, 32 tape blocks
x DBD-mysql-2.9004/lib/DBD/mysql/INSTALL.pod, 20584 bytes, 41 tape blocks
x DBD-mysql-2.9004/lib/DBD/mysql.pm, 47770 bytes, 94 tape blocks
x DBD-mysql-2.9004/lib/Mysql, 0 bytes, 0 tape blocks
x DBD-mysql-2.9004/lib/Mysql/Statement.pm, 3939 bytes, 8 tape blocks
x DBD-mysql-2.9004/lib/Bundle, 0 bytes, 0 tape blocks
x DBD-mysql-2.9004/lib/Bundle/DBD, 0 bytes, 0 tape blocks
x DBD-mysql-2.9004/lib/Bundle/DBD/mysql.pm, 417 bytes, 1 tape blocks
x DBD-mysql-2.9004/lib/Mysql.pm, 23888 bytes, 47 tape blocks
x DBD-mysql-2.9004/dbdimp.h, 6115 bytes, 12 tape blocks
x DBD-mysql-2.9004/mysql.xs, 8786 bytes, 18 tape blocks
x DBD-mysql-2.9004/MANIFEST.SKIP, 31 bytes, 1 tape blocks
x DBD-mysql-2.9004/README, 2716 bytes, 6 tape blocks
x DBD-mysql-2.9004/INSTALL.html, 26305 bytes, 52 tape blocks
x DBD-mysql-2.9004/META.yml, 381 bytes, 1 tape blocks
x DBD-mysql-2.9004/Makefile.PL, 8955 bytes, 18 tape blocks
x DBD-mysql-2.9004/ChangeLog, 40311 bytes, 79 tape blocks
x DBD-mysql-2.9004/constants.h, 1937 bytes, 4 tape blocks
x DBD-mysql-2.9004/TODO, 896 bytes, 2 tape blocks
Removing previously used /h/jicman/.cpan/build/DBD-mysql-2.9004

  CPAN.pm: Going to build R/RU/RUDY/DBD-mysql-2.9004.tar.gz

Can't exec "mysql_config": No such file or directory at Makefile.PL line
174.
readline() on closed filehandle PIPE at Makefile.PL line 176.
Can't exec "mysql_config": No such file or directory at Makefile.PL line
174.
readline() on closed filehandle PIPE at Makefile.PL line 176.
Can't exec "mysql_config": No such file or directory at Makefile.PL line
174.
readline() on closed filehandle PIPE at Makefile.PL line 176.
Can't exec "mysql_config": No such file or directory at Makefile.PL line
174.
readline() on closed filehandle PIPE at Makefile.PL line 176.
Can't exec "mysql_config": No such file or directory at Makefile.PL line
174.
readline() on closed filehandle PIPE at Makefile.PL line 176.
Failed to determine directory of mysql.h. Use

  perl Makefile.PL --cflags=-I<dir>

to set this directory. For details see the INSTALL.html file,
section "C Compiler flags" or type

  perl Makefile.PL --help
Running make test
  Make had some problems, maybe interrupted? Won't test
Running make install
  Make had some problems, maybe interrupted? Won't install

cpan>

now, as you can see, this is what I am trying to do, so it's not hidden
anywhere.  It's just failing with "failed to determine directory of mysql.h.
I don't have any place where mysql.h is.  So, I can't point to it.  So, my
question is, do I need to install a client which would have this file
mysql.h, because I don't have it in my unix system.  Also, if I display the
files where Makefile.PL is found,

odouls 14:01:44-> pwd
/h/jicman/.cpan/build/DBD-mysql-2.9004

odouls 14:01:54-> ls
ChangeLog*     MANIFEST.SKIP*  README*       dbdimp.c*  myld*
INSTALL.html*  META.yml        TODO          dbdimp.h*  mysql.xs*
MANIFEST*      Makefile.PL*    constants.h*  lib/       t/

odouls 14:02:01->

there is no "mysql_config" in there.  So... again, where are these files
suppose to be?

thanks.

----- Original Message ----- 
From: "Peter P. Benac" <[email protected]>
To: "'jose isaias cabrera'" <[email protected]>;
<[email protected]>
Sent: Thursday, November 11, 2004 1:26 PM
Subject: RE: MySQL newbie: Failed to determine directory of mysql.h


> Jose,
>
>     This error indicates you do not have DBD::mysql installed or you don't
> have it installed in the default locations.  You need to install the MySQL
> Bundle from CPAN into it's default location or use lib to tell your script
> where to find it.
>
> Regards,
> Pete
> ----
> Peter P. Benac, CCNA
> Celtic Spirit Networking
> Providing Network and Systems Project Management and Installation and Web
> Hosting.
> Phone: 919-618-2557
> Web: http://www.emacolet.com
> Need quick reliable Systems or Network Management advice visit
> http://www.nmsusers.org
>
> To have principles...
>              First have courage.. With principles comes integrity!!!
>
>
>
>
> -----Original Message-----
> From: jose isaias cabrera [mailto:[email protected]]
> Sent: Thursday, November 11, 2004 11:07 AM
> To: [email protected]
> Subject: MySQL newbie: Failed to determine directory of mysql.h
>
>
>
> Greetings!
>
> I am trying to connect from a unix server to a Windows 2000 MySQL server
and
> I am having problems with the DBD::mysql perl module.  Here is the
program:
>
> #/h/jicman/bin/perl -w
> use DBI;
>
> my $h = 'sqlhost.mydsn.net';
> my $dsn = "DBI:mysql:my_database:$h";
> my $db_user_name = 'admin';
> my $db_password = 'secret';
> my ($id, $password);
> my $dbh = DBI->connect($dsn, $db_user_name, $db_password);
>
> and I get this error:
>
>
> Using CPAN to download DBD::mysql driver, I get this error message:
>
> install_driver(mysql) failed: Can't locate DBD/mysql.pm in @INC (@INC
> contains: /h/jicman/lib/perl5/5.8.5/sun4 /h/jicman/lib/perl5/5.8.5
> /h/jicman/lib/perl5/5.8.5/sun4 /h/jicman/lib/perl5/site_perl/5.8.5
> /h/jicman/lib/perl5/site_perl ~jicman/lib/perl .) at (eval 1) line 3.
> Perhaps the DBD::mysql perl module hasn't been fully installed, or perhaps
> the capitalisation of 'mysql' isn't right. Available drivers: DBM,
ExampleP,
> File, Multiplex, Proxy, Sponge.  at Macros/MySQL.pl line 9
>
> So, I go to CPAN and try to install that module
>
> cpan> install DBD::mysql
> CPAN: Storable loaded ok
> Going to read /h/jicman/.cpan/Metadata
>   Database was generated on Wed, 03 Nov 2004 09:08:40 GMT Running install
> for module DBD::mysql Running make for R/RU/RUDY/DBD-mysql-2.9004.tar.gz
> CPAN: Digest::MD5 loaded ok
> Checksum for
> /h/jicman/.cpan/sources/authors/id/R/RU/RUDY/DBD-mysql-2.9004.tar.gz ok x
> DBD-mysql-2.9004, 0 bytes, 0 tape blocks x DBD-mysql-2.9004/t, 0 bytes, 0
> tape blocks x DBD-mysql-2.9004/t/mysql2.t, 4187 bytes, 9 tape blocks x
> DBD-mysql-2.9004/t/akmisc.t, 27024 bytes, 53 tape blocks ... ... x
> DBD-mysql-2.9004/ChangeLog, 40311 bytes, 79 tape blocks x
> DBD-mysql-2.9004/constants.h, 1937 bytes, 4 tape blocks x
> DBD-mysql-2.9004/TODO, 896 bytes, 2 tape blocks Removing previously used
> /h/jicman/.cpan/build/DBD-mysql-2.9004
>
>   CPAN.pm: Going to build R/RU/RUDY/DBD-mysql-2.9004.tar.gz
>
> Can't exec "mysql_config": No such file or directory at Makefile.PL line
> 174.
> readline() on closed filehandle PIPE at Makefile.PL line 176. Can't exec
> "mysql_config": No such file or directory at Makefile.PL line 174.
> readline() on closed filehandle PIPE at Makefile.PL line 176. Can't exec
> "mysql_config": No such file or directory at Makefile.PL line 174.
> readline() on closed filehandle PIPE at Makefile.PL line 176. Can't exec
> "mysql_config": No such file or directory at Makefile.PL line 174.
> readline() on closed filehandle PIPE at Makefile.PL line 176. Can't exec
> "mysql_config": No such file or directory at Makefile.PL line 174.
> readline() on closed filehandle PIPE at Makefile.PL line 176. Failed to
> determine directory of mysql.h. Use
>
>   perl Makefile.PL --cflags=-I<dir>
>
> to set this directory. For details see the INSTALL.html file, section "C
> Compiler flags" or type
>
>   perl Makefile.PL --help
> Running make test
>   Make had some problems, maybe interrupted? Won't test
> Running make install
>   Make had some problems, maybe interrupted? Won't install
>
> --
>
> What can I do to fix this problem?  Don't forget that I am working from an
> Unix server without root password.
>
> thanks,
>
> josé
>
>
> -- 
> MySQL Perl Mailing List
> For list archives: http://lists.mysql.com/perl
> To unsubscribe:    http://lists.mysql.com/[email protected]
>
>
> -- 
> MySQL Perl Mailing List
> For list archives: http://lists.mysql.com/perl
> To unsubscribe:
http://lists.mysql.com/[email protected]
>
>
>


-- 
MySQL Perl Mailing List
For list archives: http://lists.mysql.com/perl
To unsubscribe:    http://lists.mysql.com/[email protected]
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.