Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Making DBD::Oracle with Instant Client 10.1.0.3

2 views
Skip to first unread message

sni...@sankyo.co.jp

unread,
Feb 1, 2005, 11:09:58 PM2/1/05
to dbi-...@perl.org
Hi all,

Thanks to the devel package, I've got succeeded in making DBD::Oracle
with the Oracle Instant Client 10.1.0.3, no *.mk files, in my linux box.
My recipe is:

1) install both basic- and devel-10.1.0.3 rpm packages
2) export ORALCE_HOME="/usr/lib/oracle/10.1.0.3/client"
3) export LD_LIBRARY_PATH="$ORACLE_HOME/lib:$LD_LIBRARY_PATH"
4) modify the Makefile.PL file to bypass the find_headers() routine and
to pass a correct -I flag to cc (the attached dirty patch is FYI)
5) execute the Makefile.PL * with the -l option *, perl Makefile.PL -l
6) make && make test && make install
# I got many errors in t/30long.t (retrieving blobs ?)
# but it seems to work fairly.

I hope this could help those who are annoyed with the "Unable to locate an
oracle.mk,..." error.

Happy DBing,

Satoshi

--- Makefile.PL.orig 2004-10-22 18:07:04.000000000 +0900
+++ Makefile.PL 2005-02-02 12:39:56.703125000 +0900
@@ -276,7 +276,7 @@
print "Oracle sysliblist: $syslibs\n";
my $libdir = ora_libdir();
$opts{dynamic_lib} = { OTHERLDFLAGS => "$::opt_g" };
- my @h_dirs = find_headers();
+# my @h_dirs = find_headers();
if ($client_version_full =~ /^8.0.6/ && $os eq 'hpux') {
$linkwith_msg = "-lextp -l$lib.";
$opts{LIBS} = [ "-L$OH/$libdir -lextp -l$lib $syslibs" ];
@@ -286,7 +286,8 @@
$linkwith_msg = "-l$lib.";
$opts{LIBS} = [ "-L$OH/$libdir -l$lib $syslibs" ];
}
- my $inc = join " ", map { "-I$OH/$_" } @h_dirs;
+# my $inc = join " ", map { "-I$OH/$_" } @h_dirs;
+ my $inc = "-I/usr/include/oracle/10.1.0.3/client";
$opts{INC} = "$inc -I$dbi_arch_dir";
}
else { # --- trawl the guts of Oracle's make files looking the how it wants to link

Tim Bunce

unread,
Feb 2, 2005, 5:26:58 AM2/2/05
to sni...@sankyo.co.jp, dbi-...@perl.org
On Wed, Feb 02, 2005 at 01:09:58PM +0900, sni...@sankyo.co.jp wrote:
> Hi all,
>
> Thanks to the devel package, I've got succeeded in making DBD::Oracle
> with the Oracle Instant Client 10.1.0.3, no *.mk files, in my linux box.
> My recipe is:
>
> 1) install both basic- and devel-10.1.0.3 rpm packages
> 2) export ORALCE_HOME="/usr/lib/oracle/10.1.0.3/client"
> 3) export LD_LIBRARY_PATH="$ORACLE_HOME/lib:$LD_LIBRARY_PATH"
> 4) modify the Makefile.PL file to bypass the find_headers() routine and
> to pass a correct -I flag to cc (the attached dirty patch is FYI)
> 5) execute the Makefile.PL * with the -l option *, perl Makefile.PL -l
> 6) make && make test && make install
> # I got many errors in t/30long.t (retrieving blobs ?)
> # but it seems to work fairly.
>
> I hope this could help those who are annoyed with the "Unable to locate an
> oracle.mk,..." error.
>
> Happy DBing,
>
> Satoshi

Thanks Satoshi. I was planning to support Instant Client for the
next DBD::Oracle release. You've just saved me a little time digging.

Tim.

0 new messages