Skip to content

Commit

Permalink
cleaning rvm pkg
Browse files Browse the repository at this point in the history
  • Loading branch information
mpapis committed Aug 10, 2012
1 parent 8ca17a8 commit 9c6a5a9
Showing 1 changed file with 9 additions and 20 deletions.
29 changes: 9 additions & 20 deletions scripts/functions/pkg
Expand Up @@ -86,28 +86,17 @@ install_package()

unset configure_flags

touch "$rvm_path/config/packages"
if [[ "$action" == "uninstall" ]]
then
__rvm_run "$package/make.uninstall" \
"make uninstall" \
"Uninstalling $package from $rvm_usr_path" && \
builtin cd "$rvm_src_path" && \
__rvm_run "$package/rm_src.uninstall" \
"rm -rf $rvm_src_path/$package-$version" \
"Removing ${package}-${version} from $rvm_src_path" && \
touch "$rvm_path/config/packages"
"$rvm_scripts_path/db" \
"$rvm_path/config/packages" "${package}" delete
__rvm_run "$package/make.uninstall" "make uninstall" "Uninstalling $package from $rvm_usr_path" &&
builtin cd "$rvm_src_path" &&
__rvm_run "$package/rm_src.uninstall" "rm -rf $rvm_src_path/$package-$version" "Removing ${package}-${version} from $rvm_src_path" &&
"$rvm_scripts_path/db" "$rvm_path/config/packages" "${package}" delete
else
__rvm_run "$package/make" \
"make $rvm_make_flags" \
"Compiling $package in $rvm_src_path/$package-$version." && \
__rvm_run "$package/make.install" \
"make install" \
"Installing $package to $rvm_usr_path" && \
touch "$rvm_path/config/packages"
"$rvm_scripts_path/db" \
"$rvm_path/config/packages" "${package}" "${version}"
__rvm_run "$package/make" "make $rvm_make_flags" "Compiling $package in $rvm_src_path/$package-$version." &&
__rvm_run "$package/make.install" "make install" "Installing $package to $rvm_usr_path" &&
"$rvm_scripts_path/db" "$rvm_path/config/packages" "${package}" "${version}"
fi
)
}
Expand Down Expand Up @@ -180,7 +169,7 @@ openssl()

# Don't use -j option for make OpenSSL
[[ -z "$rvm_make_flags" ]] ||
rvm_make_flags=$(echo "$rvm_make_flags" | sed -e "s/-j[[:space:]]*[[:digit:]]*//")
rvm_make_flags=$(echo "$rvm_make_flags" | sed -e "s/-j[[:space:]]*[[:digit:]]*//")

else
configure_command="./config"
Expand Down

0 comments on commit 9c6a5a9

Please sign in to comment.