[82111] trunk/base
jmr at macports.org
jmr at macports.org
Mon Aug 8 06:16:39 PDT 2011
Revision: 82111
http://trac.macports.org/changeset/82111
Author: jmr at macports.org
Date: 2011-08-08 06:16:37 -0700 (Mon, 08 Aug 2011)
Log Message:
-----------
rearrange tcl package symlink creation to hopefully cover all possibilities
Modified Paths:
--------------
trunk/base/portmgr/dmg/postflight
trunk/base/src/macports1.0/Makefile
Modified: trunk/base/portmgr/dmg/postflight
===================================================================
--- trunk/base/portmgr/dmg/postflight 2011-08-08 11:46:27 UTC (rev 82110)
+++ trunk/base/portmgr/dmg/postflight 2011-08-08 13:16:37 UTC (rev 82111)
@@ -125,11 +125,16 @@
# link macports1.0 into tcl package dir if possible
function link_tcl_package {
# delete old directory if present
- if [[ ! -L "${TCL_PACKAGE_DIR}/macports1.0" ]] && [[ -d "${TCL_PACKAGE_DIR}/macports1.0" ]]; then
- rm -vrf "${TCL_PACKAGE_DIR}/macports1.0" || true
- fi
- if [[ ! -e "${TCL_PACKAGE_DIR}/macports1.0" ]] && [[ -w "${TCL_PACKAGE_DIR}" ]]; then
- ln -vs "${MACPORTS_TCL_DIR}/macports1.0" "${TCL_PACKAGE_DIR}/macports1.0" || true
+ if [[ ! -L "${TCL_PACKAGE_DIR}/macports1.0" ]]; then
+ if [[ ! -e "${TCL_PACKAGE_DIR}" ]]; then
+ /usr/bin/install -d "${TCL_PACKAGE_DIR}" || true
+ fi
+ if [[ -d "${TCL_PACKAGE_DIR}/macports1.0" ]]; then
+ rm -vrf "${TCL_PACKAGE_DIR}/macports1.0" || true
+ fi
+ if [[ ! -e "${TCL_PACKAGE_DIR}/macports1.0" && -d "${TCL_PACKAGE_DIR}" ]]; then
+ ln -vs "${MACPORTS_TCL_DIR}/macports1.0" "${TCL_PACKAGE_DIR}/macports1.0" || true
+ fi
fi
}
Modified: trunk/base/src/macports1.0/Makefile
===================================================================
--- trunk/base/src/macports1.0/Makefile 2011-08-08 11:46:27 UTC (rev 82110)
+++ trunk/base/src/macports1.0/Makefile 2011-08-08 13:16:37 UTC (rev 82111)
@@ -33,15 +33,15 @@
echo "${TCL_PACKAGE_DIR}" > ${DESTDIR}${prefix}/var/macports/.tclpackage
if test -z "${DESTDIR}" -a "${INSTALLPKGLINK}" != "${INSTALLDIR}"; then \
- if test ! -d "${TCL_PACKAGE_DIR}"; then \
- $(INSTALL) -d -o ${DSTUSR} -g ${DSTGRP} -m ${DSTMODE} "${TCL_PACKAGE_DIR}" || true; \
- fi; \
- if test -w "${TCL_PACKAGE_DIR}"; then \
- if test ! -L "${INSTALLPKGLINK}" && test -d "${INSTALLPKGLINK}"; then \
- rm -rf "${INSTALLPKGLINK}" || true; \
- fi; \
- if test ! -e "${INSTALLPKGLINK}"; then \
- ln -s "${INSTALLDIR}" "${INSTALLPKGLINK}" || true; \
- fi; \
- fi; \
+ if test ! -L "${INSTALLPKGLINK}"; then \
+ if test ! -e "${TCL_PACKAGE_DIR}"; then \
+ $(INSTALL) -d -o ${DSTUSR} -g ${DSTGRP} -m ${DSTMODE} "${TCL_PACKAGE_DIR}" || true; \
+ fi; \
+ if test -d "${INSTALLPKGLINK}"; then \
+ rm -vrf "${INSTALLPKGLINK}" || true; \
+ fi; \
+ if test ! -e "${INSTALLPKGLINK}"; then \
+ ln -vs "${INSTALLDIR}" "${INSTALLPKGLINK}" || true; \
+ fi; \
+ fi; \
fi
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/macports-changes/attachments/20110808/3bacac7e/attachment.html>
More information about the macports-changes
mailing list