pkgsrc-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[pkgsrc/trunk]: pkgsrc/mk/configure LIBTOOL_OVERRIDE and SHLIBTOOL_OVERRIDE h...



details:   https://anonhg.NetBSD.org/pkgsrc/rev/fea279dcd95d
branches:  trunk
changeset: 515749:fea279dcd95d
user:      jlam <jlam%pkgsrc.org@localhost>
date:      Fri Jul 07 15:25:05 2006 +0000

description:
LIBTOOL_OVERRIDE and SHLIBTOOL_OVERRIDE have slightly different
semantics in pkgsrc.  Because libtool-override is run by default
whenever USE_LIBTOOL is specified, LIBTOOL_OVERRIDE never needs to be
defined, and some packages set it to nothing to avoid running
libtool-override.  However, shlibtool-override is only run if
SHLIBTOOL_OVERRIDE is defined and non-empty.

Split the code for libtool-override and shlibtool-override to reflect
these differing semantics.  This should make the PHP packages build
again by not overriding libtool.

diffstat:

 mk/configure/libtool-override.mk |  46 ++++++++++++++++++++++++++++-----------
 1 files changed, 33 insertions(+), 13 deletions(-)

diffs (79 lines):

diff -r ba334b6c3dd4 -r fea279dcd95d mk/configure/libtool-override.mk
--- a/mk/configure/libtool-override.mk  Fri Jul 07 15:15:34 2006 +0000
+++ b/mk/configure/libtool-override.mk  Fri Jul 07 15:25:05 2006 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: libtool-override.mk,v 1.3 2006/07/07 14:25:54 jlam Exp $
+# $NetBSD: libtool-override.mk,v 1.4 2006/07/07 15:25:05 jlam Exp $
 
 ######################################################################
 ### {ltconfig,libtool,shlibtool}-override (PRIVATE)
@@ -46,8 +46,6 @@
        done
 .endif
 
-_OVERRIDE_VAR.libtool=         LIBTOOL_OVERRIDE
-_OVERRIDE_VAR.shlibtool=       SHLIBTOOL_OVERRIDE
 _OVERRIDE_PATH.libtool=                ${_LIBTOOL}
 _OVERRIDE_PATH.shlibtool=      ${_SHLIBTOOL}
 
@@ -57,28 +55,50 @@
        ${ECHO} "\#!"${TOOLS_SH:Q} > $$file;                            \
        ${ECHO} "exec" ${_OVERRIDE_PATH.${_script_}:Q} '"$$@"' >> $$file; \
        ${CHMOD} +x $$file
+.endfor
 
-.PHONY: ${_script_}-override
-${_script_}-override:
-       @${STEP_MSG} "Modifying libtool scripts to use pkgsrc ${_script_}"
-.  if defined(${_OVERRIDE_VAR.${_script_}}) && \
-      !empty(${_OVERRIDE_VAR.${_script_}})
+.PHONY: libtool-override
+libtool-override:
+       @${STEP_MSG} "Modifying libtool scripts to use pkgsrc libtool"
+.if defined(LIBTOOL_OVERRIDE)
        ${_PKG_SILENT}${_PKG_DEBUG}set -e;                              \
        cd ${WRKSRC};                                                   \
-       for file in ${${_OVERRIDE_VAR.${_script_}}}; do                 \
+       for file in ${LIBTOOL_OVERRIDE}; do                             \
                ${TEST} -f "$$file" || continue;                        \
                ${_SCRIPT.${.TARGET}};                                  \
        done
-.  else
+.else
        ${_PKG_SILENT}${_PKG_DEBUG}set -e;                              \
        cd ${WRKSRC};                                                   \
        depth=0; pattern=libtool;                                       \
-       while ${TEST} $$depth -le ${OVERRIDE_DIRDEPTH.${_script_}}; do  \
+       while ${TEST} $$depth -le ${OVERRIDE_DIRDEPTH.libtool}; do      \
                for file in $$pattern; do                               \
                        ${TEST} -f "$$file" || continue;                \
                        ${_SCRIPT.${.TARGET}};                          \
                done;                                                   \
                depth=`${EXPR} $$depth + 1`; pattern="*/$$pattern";     \
        done
-.  endif
-.endfor
+.endif
+
+.PHONY: shlibtool-override
+shlibtool-override:
+       @${STEP_MSG} "Modifying libtool scripts to use pkgsrc shlibtool"
+.if defined(SHLIBTOOL_OVERRIDE) && !empty(SHLIBTOOL_OVERRIDE)
+       ${_PKG_SILENT}${_PKG_DEBUG}set -e;                              \
+       cd ${WRKSRC};                                                   \
+       for file in ${SHLIBTOOL_OVERRIDE}; do                           \
+               ${TEST} -f "$$file" || continue;                        \
+               ${_SCRIPT.${.TARGET}};                                  \
+       done
+.else
+       ${_PKG_SILENT}${_PKG_DEBUG}set -e;                              \
+       cd ${WRKSRC};                                                   \
+       depth=0; pattern=libtool;                                       \
+       while ${TEST} $$depth -le ${OVERRIDE_DIRDEPTH.shlibtool}; do    \
+               for file in $$pattern; do                               \
+                       ${TEST} -f "$$file" || continue;                \
+                       ${_SCRIPT.${.TARGET}};                          \
+               done;                                                   \
+               depth=`${EXPR} $$depth + 1`; pattern="*/$$pattern";     \
+       done
+.endif



Home | Main Index | Thread Index | Old Index