From 5f3eda80d5047f25e75d71d39e29adeb7ee7e838 Mon Sep 17 00:00:00 2001 From: mollusk Date: Sat, 20 May 2017 06:55:44 -0700 Subject: [PATCH] euphoria-manager now checks for symlinks better --- tools/euphoria-manager | 26 ++++++++++++-------------- 1 file changed, 12 insertions(+), 14 deletions(-) diff --git a/tools/euphoria-manager b/tools/euphoria-manager index 0075630..aa723c4 100755 --- a/tools/euphoria-manager +++ b/tools/euphoria-manager @@ -33,7 +33,7 @@ fext="tar.gz" extcmd="tar" deps="curl" target_dir="/usr/local" -url="http://heanet.dl.sourceforge.net/project/rapideuphoria/Euphoria/${version}-${state}/euphoria-${version}-Linux-${arch}-57179171dbed.${fext}" +url="https://svwh.dl.sourceforge.net/project/rapideuphoria/Euphoria/${version}-${state}/${name}-${version}-Linux-${arch}-57179171dbed.${fext}" tmpdir="/tmp" check_deps(){ @@ -110,25 +110,23 @@ post_install(){ ln -v -s ${target_dir}/${name}-${version}-Linux-${arch}/bin/eucoverage /usr/bin } +symlinks=$(which {eui,euc,eutest,eudist,eudoc,eushroud,euloc,eudis,eubind,eub,echoversion,creole,eucoverage}) + uninstall_pkg(){ if [ ! -d ${target_dir}/${name}-${version}-Linux-${arch} ];then printf "${name}-${version} is not installed\n" + + if [[ $symlinks ]];then + rm $symlinks + fi + else rm -v -r ${target_dir}/${name}-${version}-Linux-${arch} - rm -v /usr/bin/eui - rm -v /usr/bin/euc - rm -v /usr/bin/eutest - rm -v /usr/bin/eudist - rm -v /usr/bin/eudoc - rm -v /usr/bin/eushroud - rm -v /usr/bin/euloc - rm -v /usr/bin/eudis - rm -v /usr/bin/eubind - rm -v /usr/bin/eub - rm -v /usr/bin/echoversion - rm -v /usr/bin/creole - rm -v /usr/bin/eucoverage + + if [[ $symlinks ]];then + rm $symlinks + fi if [ ! -d ${target_dir}/${name}-${version}-Linux-${arch} ];then echo