> > What seems to be happening with RC3 is that Makefile.PL is behaving
> > as if I had a full Oracle install rather than an Instant Client.
> 
> Yeap. I'll take a closer look at the log and see if I can spot why.
> Thanks for the details.

I think it just needs the Oracle XE and Oracle Instant Client branches
swapping around.

r2395 changed:

-elsif ($::opt_m =~ /\bdemo_xe.mk$/) {  # Oracle XE
+elsif ($mkfile = find_mkfile() and $mkfile =~ /\bdemo_xe.mk$/) { # Oracle
XE

This is executed before the check for the Instant Client library that makes
it pick the direct-link approach. Problem is that find_mkfile() does a die()
if it can't find the makefile. Since the IC SDK directory isn't searched,
and it's not needed anyway if it's going for direct link, then this makes
the IC build fail at this point.

Swap the XE and IC tests over (as in attached patch) and it builds
successfully again for me (on Linux 10201instant, 10201xe, 10201full,
10104instant, 9207full).

So it then tries in order (for UNIX variants):

(1) Direct link (user-selected with -l)
(2) Instant Client direct link
(3) Oracle XE makefile
(4) Full client makefile

--
Andy Hassall :: [EMAIL PROTECTED] :: http://www.andyh.co.uk
http://www.andyhsoftware.co.uk/space :: disk and FTP usage analysis tool 
Index: Makefile.PL
===================================================================
--- Makefile.PL (revision 2402)
+++ Makefile.PL (working copy)
@@ -302,31 +302,6 @@
     check_ldlibpthname();
 }
 
-elsif ($mkfile = find_mkfile() and $mkfile =~ /\bdemo_xe.mk$/) { # Oracle XE
-
-    print "Looks like Oracle XE ($mkfile)\n";
-
-    fetch_oci_macros($mkfile);
-    $MK{CCINCLUDES} = '-I$(ICINCHOME)'; # undo odd refinition in demo_xe.mk
-
-    # From linux Oracle XE (10.2.0):
-    #  ICINCHOME=$(ORACLE_HOME)/rdbms/public/
-    #  ICLIBHOME=$(ORACLE_HOME)/lib/
-    #  ICLIBPATH=-L$(ICLIBHOME)
-    #  THREADLIBS=-lpthread    [initially -lthread then redefined]
-    #  CCLIB=$(ICLIBPATH) -lclntsh $(THREADLIBS)
-    #  CCINCLUDES = -I$(ICINCHOME)   [see above]
-    #   CCFLAGS=$(CCINCLUDES) -DLINUX -D_GNU_SOURCE -D_REENTRANT -g [initially 
without -DLINUX -D_GNU_SOURCE]
-    my $cclib   = expand_mkvars($MK{CCLIB}, 0, 1);
-    my $ccflags = expand_mkvars($MK{CCFLAGS}, 0, 1);
-
-    $linkwith_msg = "$cclib";
-    $opts{LIBS} = [ $cclib ];
-    $opts{INC}  = "-I$dbi_arch_dir $ccflags";
-    $opts{dynamic_lib} = { OTHERLDFLAGS => "$::opt_g" };
-    check_ldlibpthname();
-}
-
 # --- special case for Oracle 10g instant client
 
 elsif (-e "$OH/libclntsh.$so" or -e "$OH/libclntsh.$so.10.1") {   # note lack 
of ../lib/...
@@ -356,6 +331,32 @@
     $opts{INC}  = "-I$inc -I$dbi_arch_dir";
 
 }
+
+elsif ($mkfile = find_mkfile() and $mkfile =~ /\bdemo_xe.mk$/) { # Oracle XE
+
+    print "Looks like Oracle XE ($mkfile)\n";
+
+    fetch_oci_macros($mkfile);
+    $MK{CCINCLUDES} = '-I$(ICINCHOME)'; # undo odd refinition in demo_xe.mk
+
+    # From linux Oracle XE (10.2.0):
+    #  ICINCHOME=$(ORACLE_HOME)/rdbms/public/
+    #  ICLIBHOME=$(ORACLE_HOME)/lib/
+    #  ICLIBPATH=-L$(ICLIBHOME)
+    #  THREADLIBS=-lpthread    [initially -lthread then redefined]
+    #  CCLIB=$(ICLIBPATH) -lclntsh $(THREADLIBS)
+    #  CCINCLUDES = -I$(ICINCHOME)   [see above]
+    #   CCFLAGS=$(CCINCLUDES) -DLINUX -D_GNU_SOURCE -D_REENTRANT -g [initially 
without -DLINUX -D_GNU_SOURCE]
+    my $cclib   = expand_mkvars($MK{CCLIB}, 0, 1);
+    my $ccflags = expand_mkvars($MK{CCFLAGS}, 0, 1);
+
+    $linkwith_msg = "$cclib";
+    $opts{LIBS} = [ $cclib ];
+    $opts{INC}  = "-I$dbi_arch_dir $ccflags";
+    $opts{dynamic_lib} = { OTHERLDFLAGS => "$::opt_g" };
+    check_ldlibpthname();
+}
+
 else { # --- trawl the guts of Oracle's make files looking the how it wants to 
link
     #Lincoln: pick the right library path
     check_ldlibpthname();

Reply via email to