httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Michael Felt <mamf...@gmail.com>
Subject Re: Unhappy interactions between AIX, apxs, instdso.sh, apr/build-1/libtool and php
Date Fri, 20 Jun 2014 19:34:53 GMT
Here is the patch - as text, and a file (not sure what normal is, but since
it is small doing both).

I moved $DLNAME != $TARGET_NAME test up because it seems more logical to
try and let this bit resolve
any issue before testing for the existance of $TARGET_NAME

Then, if $TARGET_NAME is still missing, try and guess/hope that it is
./libs and copy from there.
Set exit status to the exit status of the copy, and exit with that value at
the end.

I am wondering if the root cause is being corrected though. Perhaps apr is
in error, or the instructions for creating the .la file (would that
indicate libtool?). In any case, I hope this, even as a "hack" resolves the
recurring problems I have with getting php to install in a DESTDIR aka
INSTALL_ROOT.



*As an aside for anyone else attempting to package php, rather than install
on top of an installed httpd - there is a an additional moment that goes
wrong when installing to an installation directory: the configuration file
(httpd.conf) is, basically by definition, missing.*
*I would also like to see the apxs warn and skip, rather than fail when
apxs has been asked to add LoadModule (*

*(i.e. -S SYSCONFDIR='$(INSTALL_ROOT)/etc/httpd' ... -S (-a or -A or -e)
configuration file (i.e., $SYSCONFDIR/httpd.conf) is missing  rather than
failing. I think this would be more graceful.Currently I resolve this by
editing the php Makefile and remove the '-a' argument from the INSTALL_IT
definition.*

Back to the 'patch' proposal:

root@x093:[/data/prj/apache/httpd/httpd-2.2.27]diff -u ./build/instdso.sh
/var/httpd/build/instdso.sh
--- ./build/instdso.sh  2006-07-12 03:38:44 +0000
+++ /var/httpd/build/instdso.sh 2014-06-20 19:13:56 +0000
@@ -72,6 +72,20 @@
   exit 0
 fi

+if test "$DLNAME" != "$TARGET_NAME"
+then
+    mv $TARGETDIR/$DLNAME $TARGETDIR/$TARGET_NAME
+fi
+
+# at this point $TARGETDIR/$TARGET_NAME should exist
+# if not, let's hope it is in .libs and copy it to $TARGET_DIR
+status=0
+if ! test -e  $TARGETDIR/$TARGET_NAME
+then
+       cp -p .libs/$TARGET_NAME  $TARGETDIR/$TARGET_NAME || exit 1
+       status = $?
+fi
+
 if test -n "$LIBRARY_NAMES"
 then
     for f in $LIBRARY_NAMES
@@ -80,14 +94,9 @@
     done
 fi

-if test "$DLNAME" != "$TARGET_NAME"
-then
-    mv $TARGETDIR/$DLNAME $TARGETDIR/$TARGET_NAME
-fi
-
 rm -f $TARGETDIR/$DSOARCHIVE_BASENAME
 rm -f $TARGETDIR/$DSOBASE.a
 rm -f $TARGETDIR/lib$DSOBASE.a
 rm -f $TARGETDIR/lib$TARGET_NAME

-exit 0
+exit $status



On Fri, Jun 20, 2014 at 7:22 PM, Victor J. Orlikowski <
victor.j.orlikowski@alumni.duke.edu> wrote:

> On Jun 20, 2014, at 12:35 PM, Michael Felt <mamfelt@gmail.com> wrote:
>
> At least, I am assuming this to be the problem - because I am assuming the
> expectation is that $TARGET_NAME has been installed - unless DLNAME !=
> TARGET_NAME - because in that case DLNAME gets moved.
>
> Unfortunately, what has been installed is $LIBRARY_NAMES and that has
> already been removed!
>
>
> Yeah - I noticed that, when I glanced at it.
> Nice detective work!
>
> Send the patch on, and I’ll be glad to review/commit it.
>
> Best,
> Victor
> --
> Victor J. Orlikowski <> victor.j.orlikowski@alumni.duke.edu
>
>

Mime
View raw message