Ignore:
Timestamp:
Aug 8, 2011, 1:16:37 PM (9 years ago)
Author:
jmr@…
Message:

rearrange tcl package symlink creation to hopefully cover all possibilities

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/base/portmgr/dmg/postflight

    r81558 r82111  
    126126function link_tcl_package {
    127127    # delete old directory if present
    128     if [[ ! -L "${TCL_PACKAGE_DIR}/macports1.0" ]] && [[ -d "${TCL_PACKAGE_DIR}/macports1.0" ]]; then
    129         rm -vrf "${TCL_PACKAGE_DIR}/macports1.0" || true
    130     fi
    131     if [[ ! -e "${TCL_PACKAGE_DIR}/macports1.0" ]] && [[ -w "${TCL_PACKAGE_DIR}" ]]; then
    132                 ln -vs "${MACPORTS_TCL_DIR}/macports1.0" "${TCL_PACKAGE_DIR}/macports1.0" || true
     128    if [[ ! -L "${TCL_PACKAGE_DIR}/macports1.0" ]]; then
     129        if [[ ! -e "${TCL_PACKAGE_DIR}" ]]; then
     130            /usr/bin/install -d "${TCL_PACKAGE_DIR}" || true
     131        fi
     132        if [[ -d "${TCL_PACKAGE_DIR}/macports1.0" ]]; then
     133            rm -vrf "${TCL_PACKAGE_DIR}/macports1.0" || true
     134        fi
     135        if [[ ! -e "${TCL_PACKAGE_DIR}/macports1.0" && -d "${TCL_PACKAGE_DIR}" ]]; then
     136            ln -vs "${MACPORTS_TCL_DIR}/macports1.0" "${TCL_PACKAGE_DIR}/macports1.0" || true
     137        fi
    133138        fi
    134139}
Note: See TracChangeset for help on using the changeset viewer.