If you have ever had this message:
Unable to locate an oracle.mk, proc.mk or other suitable *.mk
file in your Oracle installation. (I looked in…)
It can be a very frustrating one to track down.
I have seen it across almost all platforms and versions of Oracle but what it boils down to is that you are quite simply:
1) Missing some part of your Oracle Client or
2) Part of your Oracle Client is some place where the Makefile.PL cannot find it or
3) Part of your Oracle Client is buried inside a resource or a symbolic link or
4) Oracle has moved or removed files that DBD::Oracle needs to compile.
Well what to do then??
There is no 100% answer for this problem but there seems to be two main scenarios where I have encountered this and have come up with somewhat of a solution:
1) If you are attempting to build against any of Oracle’s Instantclients you most likely have only have the basic install available. To correct this simply make sure you get the SDK and SQLPlus downloads as well and try compiling again.
2) If you are installing against an 11g instance (Oracle seems to have moved a number of things about depending on the platform) then you best bet would be to give this a try:
Perl Makefile.PL -l
which forces the compile to user the “direct link” method thus bypassing the *.mk files. Expect much more output and a longer compile time when you take this route but it should work exactly the same.
I had the same problem to, but fortunately your help made me pass to make test. Im trying to compile to an 11G install and it seems that Oracle removed lib32. Now I problably need a 64 bit perl and all the required modules. Dont know if they exist.
Thanks alot John , had the #2 problem compiling it against oracle 11g , great work !
the step perl Makefile.PL -l helped me pass to the next step.
Now when trying to compile it, I get the following error message:
ld: fatal: file : open failed: No such file or directory
ld: fatal: file /opt/app/oracle/product/11.2/lib/libclntsh.so: wrong ELF class: ELFCLASS64
ld: fatal: File processing errors. No output written to blib/arch/auto/DBD/Oracle/Oracle.so
collect2: ld returned 1 exit status
make: *** [blib/arch/auto/DBD/Oracle/Oracle.so] Error 1
Thanks alot. It helped me.
Thank you. it resolved my issue
Has anyone compiled DBD::ORacle in the past 5 years? My god. We’re at 12.2 now, and I find practcially nothing on this. Has perl / cpan module development taken such a huge step backwards? The README file is no longer a README file as such. The INSTALL barely mentions anything useful.
“export LD_LIBRARY_PATH=/usr/lib/oracle/12.1/client64/lib/ ORACLE_HOME=/usr/lib/oracle/12.1/client64 ; perl Makefile.PL -l ; make ; make install” at least did for me (ubuntu 64bit & instantclient 12 / 64bit) smoothly