[Pdx-pm] DBD::mysql cont.

Chris Dawson cdawson at webiphany.com
Wed Mar 31 04:21:22 CST 2004


James,

I don't personally use tcsh shell, but here is the issue, I think:

sh-2.05b$ tcsh
 > set foo bar
 > echo $foo

 > set foo=bar
 > echo $foo
bar
 >

So, in other words, your set command below is not setting the PATH 
variable to anything, since it requires a '=' sign. 

Try this,

set 
PATH=/usr/local/mysql-standard-4.0.15-apple-darwin6.4-powerpc/bin/:$PATH

Then, try to run mysql_config.  It should work now, right?  If so, then 
try to re-run "perl -MCPAN -e 'install DBD::mysql'"

Chris

James marks wrote:

> This is the situation as I understand it:
>
>
> The Makefile.PL script, when run, returns this error:
>
> 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.
>
>
>
> The relevant lines in Makefile.PL are as follows:
>
> 173    # First try mysql_config
> 174    open(PIPE, "mysql_config --$param |");
> 175    my $str = "";
> 176    while (defined(my $line = <PIPE>)) {
>
>
> with line 174 returning an error (null value?) causing line 176 to 
> fail. It seems that the script is unable to locate the "mysql_config" 
> file which, in fact, resides in this directory:
>
> /usr/local/mysql/bin/
>
> where "mysql" is an alias to 
> "mysql-standard-4.0.15-apple-darwin6.4-powerpc"
>
> I don't know how to direct the Makefile.PL script to that directory.
>
>> You might have to use something like "set PATH 
>> /usr/local/mysql-standard-4.0.15-apple-darwin6.4-powerpc/bin/:$PATH" 
>> depending on what your shell requires...
>
>
> I've tried this:
>
> [iMac:~/.cpan/build/DBD-mysql-2.9003] jamesmar% set PATH 
> /usr/local/mysql-standard-4.0.15-apple-darwin6.4-powerpc/bin/:$PATH
>
> but it returns the following:
>
> tcsh: set: Variable name must begin with a letter.
>
> I'm not sure what that means. To me, the obvious shell variable is 
> "PATH" which begins with a letter, and the obvious Perl variable is 
> $PATH but Perl variables must begin with a symbol rather than just a 
> letter and, ignoring the $ symbol, the next character IS a letter.
>
> (Again, please keep in mind that I'm just learning Perl - and 
> programming for that matter - and some things which might appear to be 
> blatantly obvious to the average programmer my sail right past me 
> without a sound.)
>
> I could try leaving the $ symbol off of the last word in the "set" 
> statement but that would, to me, represent "PATH" as a file or directory.
>
> I tried leaving the Perl variable off of the end of the "set" 
> statement and got the same response:
>
> tcsh: set: Variable name must begin with a letter.
>
>
> It's late (2 a.m.) and I have to be at work early this morning so I'll 
> have to put it on hold for now and try again this evening.
>
> I really appreciate all the advice and suggestions that have been 
> offered so far. Please let me know if I wear out my welcome!
>
> James
>
> _______________________________________________
> Pdx-pm-list mailing list
> Pdx-pm-list at mail.pm.org
> http://mail.pm.org/mailman/listinfo/pdx-pm-list





More information about the Pdx-pm-list mailing list