question in mysql_config

H

Huub

Hi,

I'm trying to install DBD::mysql. When I start cpan, I start "look
DBD::mysql". Then in the terminal "perl Makefile.PL
--testhost=<hostname>". Then I get this message:

Can't exec "mysql_config": No such file or directory at Makefile.PL line 76.

Do I have to install something else first?

Thanks,

Huub
 
S

Sherm Pendley

Huub said:
Hi,

I'm trying to install DBD::mysql. When I start cpan, I start "look
DBD::mysql". Then in the terminal "perl Makefile.PL
--testhost=<hostname>". Then I get this message:

Can't exec "mysql_config": No such file or directory at Makefile.PL line 76.

Do I have to install something else first?

You don't *have* to, no. If you don't use --testhost and other options to
specify the host, port, etc. to connect to, and where to find the MySQL
client headers and libraries, then Makefile.PL will run the mysql_config
tool to get that information.

If you *have* given all the relevant information, then the failure to find
mysql_config will cause no harm.

Obviously, btw, you do need to have the MySQL client C library and headers
installed somewhere on your system.

sherm--
 
H

Huub

Obviously, btw, you do need to have the MySQL client C library and headers
installed somewhere on your system.

Thank you. Another problem: on another machine I installed it with help
from you and others. With this new installation, I get this with "make":
/usr/bin/ld: cannot find -lz
collect2: ld returned 1 exit status


An error occurred while linking the DBD::mysql driver. The error
message seems to indicate that you don't have a libz.a,
or a libz.so. This is typically resolved by:

1.) You may try to remove the -lz or -lgz flag from the libs list
by using the --libs switch for "perl Makefile.PL".
2.) On Red Hat Linux install libz-devel
3.) On other systems, please contact the mailing list

Though both machines run Fedora, neither has libz-devel installed. And
on the other machine I didn't get this message. Any clue?
 
S

Sherm Pendley

Huub said:
Though both machines run Fedora, neither has libz-devel installed.

You've already identified the problem, and the solution is listed as #2
on the list above: Install libz-devel.

sherm--
 
H

Huub

You've already identified the problem, and the solution is listed as #2
on the list above: Install libz-devel.

sherm--

That doesn't answer the question why the other machine posed not problem
in this situation, while it didn't have libz either.
BTW, the INSTALL.html indicates that libz is only necessary when
installing from source. Assuming both "look DBD::mysql" or "install
DBD::mysql" mean installing from source, what is installing from
pre-compiled then?
 
H

Huub

You've already identified the problem, and the solution is listed as #2
on the list above: Install libz-devel.

sherm--

That doesn't answer the question why the other machine posed not problem
in this situation, while it doesn't have libz either. On the other
hand, zlib is installed, which turns out to be the successor tp libz.
So, I fail to see what's going wrong and why.
BTW, the INSTALL.html indicates that libz is only necessary when
installing from source. Assuming both "look DBD::mysql" or "install
DBD::mysql" mean installing from source, what is installing from
pre-compiled then?
 
S

Sherm Pendley

Huub said:
That doesn't answer the question why the other machine posed not problem
in this situation, while it doesn't have libz either. On the other
hand, zlib is installed, which turns out to be the successor tp
libz. So, I fail to see what's going wrong and why.

Who knows? Different MySQL client libraries, different -dev packages, etc.
Any number of possibilities exist. I wouldn't waste time worrying about it.
I'd just do what the error message says to do (install libz-devel) and move
on.
BTW, the INSTALL.html indicates that libz is only necessary when
installing from source. Assuming both "look DBD::mysql" or "install
DBD::mysql" mean installing from source, what is installing from
pre-compiled then?

RPM or PPD packages, etc. - lots of ways to get pre-compiled modules on
a variety of platforms.

sherm--
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,755
Messages
2,569,536
Members
45,019
Latest member
RoxannaSta

Latest Threads

Top