|go ahead... be a heretic|
Re: What are DBD::Oracle's dependencies (on Linux)?by Rhys (Pilgrim)
|on Oct 01, 2004 at 19:15 UTC||Need Help??|
I just got through this myself not too long ago. It was such a giant PITA that I created an RPM for it once everything finally worked.
Basically, the only thing you need from the Oracle CDs are the C libraries and headers. You need these in order to build DBD::Oracle. I also recommend adding a script to /etc/profile.d that will set your ORACLE_HOME and ORACLE_BASE environment variables.
Once you have the Oracle client pieces installed properly (don't forget to edit tnsnames.ora!), you should be able to use CPAN to install DBD::Oracle. The 'make test' part will fail if you have not set the ORACLE_SID variable, but if you look through the build output and that's the only thing that fails, just do force install DBD::Oracle and it will work. (At least, it works for me.)
Really, the hard part is getting all of the Oracle client to install properly. When I installed 9.2, the biggest problem was working around the _libcwait Java problem. Oracle has a 'patch' for it that builds a library with that function and preloads it. It's kind of silly, and only necessary for the installation. It's also a good idea to create the 'oracle' user ID and the 'oinstall' group on your system before running the installer. Also, DO NOT RUN THE INSTALLER FROM THE CD-ROM. Stay in your home directory and use the absolute path to run it. E.g.:
The reason is that if the current directory is in the CD-ROM when you run the installer, it won't be able to properly unmount the CD when it's time to change discs, things get weird, and you have to start over.
But to help you with anything more specific, I'm afraid we need to know what version of the Oracle client you're trying to install, since they are all different.
NOTE: The "Instant Client" won't work, because it comes with none of the libraries and headers you need to build DBD::Oracle. It's a functioning client, but that won't help you write Perl. ;-)