Bug #29889 DBD::mysql doesn't support the --prefix or --PREFIX option for non-system-wide
Submitted: 19 Jul 2007 4:19 Modified: 19 Jul 2007 6:53
Reporter: David Buzz Email Updates:
Status: Not a Bug Impact on me:
None 
Category:Connectors: DBD::mysql ( Perl ) Severity:S2 (Serious)
Version:DBD-mysql-4.005 OS:Any
Assigned to: CPU Architecture:Any

[19 Jul 2007 4:19] David Buzz
Description:
I'm using a localised (ie not system-wide) install of the mysql client libraries (eg in my homefolder, in: /home/buzz/mysql-5.0.41-solaris9-sparc/ ) , and I want to build a "personal" install of DBD::mysql to go with this.

.. but DBD::mysql 'Makefile.PL' doesn't support the --prefix or --PREFIX option 

How to repeat:

I don't have the option of doing a system-wide install, as we have a LOT of existing dependancies that rely on the older library version/s staying where they are!

my build command: (specifying both the perl version, and the mysql version)
perl5.8.8 Makefile.PL --mysql_config=/home/buzz/mysql-5.0.41-solaris9-sparc/bin/mysql_config

but this wants to install the perl libraries into /usr/local/lib...etc  (I looked in the the generated Makefile).

Suggested fix:
MY WORKAROUND:
Currently, my solution is going to be to "hack" the generated Makefile - if I can.

YOUR BTTER FIX:
Most CPAN modules (excpept this) have the ability to do:

perl5.8.8 Makefile.PL --prefix=/home/buzz --mysql_config=/home/buzz/mysql-5.0.41-solaris9-sparc/bin/mysql_config

this would allow me to install to /home/buzz/lib....etc which is what I want.

I then 'export PERL5LIB=/home/buzz/lib/....etc' to make sure these librararies are located first.
[19 Jul 2007 6:53] Sveta Smirnova
Thank you for taking the time to write to us, but this is not a bug. Please double-check the documentation available at http://dev.mysql.com/doc/ and the instructions on
how to report a bug at http://bugs.mysql.com/how-to-report.php

DBD::mysql supports PREFIX option. I.e. `perl Makefile.PL --mysql_config=path PREFIX=$HOME/foo`