]> git.ipfire.org Git - thirdparty/apache/httpd.git/commitdiff
run libtool from the apr install directory (in case that is different
authorJeff Trawick <trawick@apache.org>
Fri, 4 Apr 2003 19:04:21 +0000 (19:04 +0000)
committerJeff Trawick <trawick@apache.org>
Fri, 4 Apr 2003 19:04:21 +0000 (19:04 +0000)
from the apache install directory)

further changes are needed to automatically pick up apr and apr-util
include directories; for now, "-Wc,-I/path" needs to be added to the
apxs -c invocation to work around that problem

git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@99213 13f79535-47bb-0310-9956-ffa450edef68

support/apxs.in

index a5a2f4e879a5f1be0f5f9335e6a56a3e27c6091e..49ddcb4de0f61925543c1e8817044d2b20164dcf 100644 (file)
@@ -362,6 +362,17 @@ if ($opt_q) {
     print "$result\n";
 }
 
+my $apr_bindir = get_vars("APR_BINDIR");
+
+if (! -x "$apr_bindir/apr-config") {
+    error("$apr_bindir/apr-config not found!");
+    exit(1);
+}
+
+my $libtool = `$apr_bindir/apr-config --installbuilddir`;
+chomp($libtool);
+$libtool = "$libtool/libtool";
+
 if ($opt_c) {
     ##
     ##  SHARED OBJECT COMPILATION
@@ -424,7 +435,7 @@ if ($opt_c) {
         $la =~ s|\.c$|.la|;
         my $o = $s;
         $o =~ s|\.c$|.o|;
-        push(@cmds, "$installbuilddir/libtool $ltflags --mode=compile $CFG_CC $cflags -I$CFG_INCLUDEDIR $opt -c -o $lo $s && touch $slo");
+        push(@cmds, "$libtool $ltflags --mode=compile $CFG_CC $cflags -I$CFG_INCLUDEDIR $opt -c -o $lo $s && touch $slo");
         unshift(@objs, $lo);
     }
 
@@ -449,13 +460,6 @@ if ($opt_c) {
         $opt .= " -l$opt_l";
     }
 
-    my $apr_bindir = get_vars("APR_BINDIR");
-
-    if (! -x "$apr_bindir/apr-config") {
-        error("$apr_bindir/apr-config not found!");
-        exit(1);
-    }
-
     if ($opt_p == 1) {
         my $apu_bindir = get_vars("APU_BINDIR");
 
@@ -477,7 +481,7 @@ if ($opt_c) {
         $opt .= " -rpath $CFG_LIBEXECDIR -module -avoid-version $apr_ldflags";
     }
 
-    push(@cmds, "$installbuilddir/libtool $ltflags --mode=link $CFG_CC -o $dso_file $opt $lo");
+    push(@cmds, "$libtool $ltflags --mode=link $CFG_CC -o $dso_file $opt $lo");
 
     #   execute the commands
     &execute_cmds(@cmds);
@@ -508,7 +512,7 @@ if ($opt_i or $opt_e) {
         $t =~ s|\.la$|\.so|;
         if ($opt_i) {
            push(@cmds, "$installbuilddir/instdso.sh SH_LIBTOOL='" .
-                 "$installbuilddir/libtool' $f $CFG_LIBEXECDIR");
+                 "$libtool' $f $CFG_LIBEXECDIR");
            push(@cmds, "chmod 755 $CFG_LIBEXECDIR/$t");
         }