Blame SOURCES/httpd-2.4.25-apxs.patch

f0c688
3fd4d8
- use libdir from configuration.
3fd4d8
- only link against -lapr itself
3fd4d8
- also run restorecon on install module .so
f0c688
3fd4d8
--- httpd-2.4.25/support/apxs.in.apxs
3fd4d8
+++ httpd-2.4.25/support/apxs.in
3fd4d8
@@ -35,6 +35,7 @@
f0c688
 my $exec_prefix    = get_vars("exec_prefix");
f0c688
 my $datadir        = get_vars("datadir");
f0c688
 my $localstatedir  = get_vars("localstatedir");
f0c688
+my $libdir         = get_vars("libdir");
f0c688
 my $CFG_TARGET     = get_vars("progname");
f0c688
 my $CFG_SYSCONFDIR = get_vars("sysconfdir");
f0c688
 my $CFG_CFLAGS     = join ' ', map { get_vars($_) }
3fd4d8
@@ -275,7 +276,7 @@
af9b8b
     $data =~ s|%NAME%|$name|sg;
af9b8b
     $data =~ s|%TARGET%|$CFG_TARGET|sg;
af9b8b
     $data =~ s|%PREFIX%|$prefix|sg;
af9b8b
-    $data =~ s|%INSTALLBUILDDIR%|$installbuilddir|sg;
af9b8b
+    $data =~ s|%LIBDIR%|$libdir|sg;
af9b8b
 
af9b8b
     my ($mkf, $mods, $src) = ($data =~ m|^(.+)-=#=-\n(.+)-=#=-\n(.+)|s);
af9b8b
 
3fd4d8
@@ -453,11 +454,11 @@
af9b8b
     my $ldflags = "$CFG_LDFLAGS";
af9b8b
     if ($opt_p == 1) {
af9b8b
         
af9b8b
-        my $apr_libs=`$apr_config --cflags --ldflags --link-libtool --libs`;
af9b8b
+        my $apr_libs=`$apr_config --cflags --ldflags --link-libtool`;
af9b8b
         chomp($apr_libs);
af9b8b
         my $apu_libs="";
af9b8b
         if ($apr_major_version < 2) {
af9b8b
-            $apu_libs=`$apu_config --ldflags --link-libtool --libs`;
af9b8b
+            $apu_libs=`$apu_config --ldflags --link-libtool`;
af9b8b
             chomp($apu_libs);
af9b8b
         }
af9b8b
         
3fd4d8
@@ -504,6 +505,9 @@
3fd4d8
 	    push(@cmds, "$installbuilddir/instdso.sh SH_LIBTOOL='" .
3fd4d8
                  "$libtool' $f $CFG_LIBEXECDIR");
3fd4d8
 	    push(@cmds, "chmod 755 $CFG_LIBEXECDIR/$t");
3fd4d8
+	    if (-x "/sbin/restorecon") {
3fd4d8
+		push(@cmds, "restorecon -v $CFG_LIBEXECDIR/$t");
3fd4d8
+	    }
3fd4d8
         }
3fd4d8
 
3fd4d8
         #   determine module symbolname and filename
3fd4d8
@@ -672,8 +676,8 @@
af9b8b
 
af9b8b
 builddir=.
af9b8b
 top_srcdir=%PREFIX%
af9b8b
-top_builddir=%PREFIX%
af9b8b
-include %INSTALLBUILDDIR%/special.mk
af9b8b
+top_builddir=%LIBDIR%/httpd
af9b8b
+include %LIBDIR%/httpd/build/special.mk
af9b8b
 
af9b8b
 #   the used tools
33b929
 APACHECTL=apachectl