From ac6fd6d64d37b00ab43600a59d7b0a6e09edfc91 Mon Sep 17 00:00:00 2001 From: Joe Hunkeler Date: Mon, 22 Feb 2016 21:32:04 -0500 Subject: Remove dead symlinks to fix python2 installation bug --- iraf/iraf.ini | 17 ++++++++++++++++- 1 file changed, 16 insertions(+), 1 deletion(-) diff --git a/iraf/iraf.ini b/iraf/iraf.ini index 2d264da..a56730d 100644 --- a/iraf/iraf.ini +++ b/iraf/iraf.ini @@ -16,7 +16,7 @@ url: #git_url: ssh://git@bitbucket.org/jhunkeler/${package:name}-combined [build] -number: 11 +number: 12 detect_binary_files_with_prefix: False [osx] binary_relocation: False [osx] @@ -128,11 +128,26 @@ linux: ln -s -f $$iraf/unix/bin.$$IRAFARCH/xpp.e && \ ln -s -f $$iraf/unix/bin.$$IRAFARCH/xyacc.e xyacc ) + UR_BUILTIN=/Users/Shared/ureka.iraf/ur_work/iraf + find . -lname "$$UR_BUILTIN/*" \ + -exec sh -c 'echo Re-linking builtin paths "$$0" ;\ + ln -snf "$$(readlink "$$0" \ + | sed -e "s|$$UR_BUILTIN|../..|" -e "s|/as/|/as.$$IRAFARCH/|")" "$$0"' {} \; + find . -lname '/iraf/iraf/*' \ -exec sh -c 'echo Re-linking "$$0" ;\ ln -snf "$$(readlink "$$0" \ | sed -e "s|/iraf/iraf|../..|" -e "s|/as/|/as.$$IRAFARCH/|")" "$$0"' {} \; + # I say we take off and nuke the entire site from orbit. + # It's the only way to be sure... + # -- Ellen Ripley + + # Basically we're making a pass to remove *all* dead symlinks from IRAF. For better or worse... + echo "Removing dead symlinks..." + find $$iraf $$iraf/../variants -type l | xargs -n 1 -I'{}' \ + sh -c 'file {} | grep broken | cut -f 1 -d :' | xargs rm -f + #gzip -9 unix/bin.$$IRAFARCH/sgi2ueps.e #rm -f unix/bin.$$IRAFARCH/sgi2ueps.e -- cgit