Commit b3512f49 by Mislav Marohnić

Avoid endless recursion when rbx is installed over existing one

When installing rbx over an existing location, the `gems/bin` directory
will already be a symlink to `bin/` and an attempt to recreate this will
end up in recursion that keeps growing a binstub file until the disk is full.
parent 985200d4
...@@ -644,7 +644,7 @@ fix_rbx_gem_binstubs() { ...@@ -644,7 +644,7 @@ fix_rbx_gem_binstubs() {
local bindir="${prefix}/bin" local bindir="${prefix}/bin"
local file binstub local file binstub
# Symlink Rubinius' `gems/bin/` into `bin/` # Symlink Rubinius' `gems/bin/` into `bin/`
if [ -d "$gemdir" ]; then if [ -d "$gemdir" ] && [ ! -L "$gemdir" ]; then
for file in "$gemdir"/*; do for file in "$gemdir"/*; do
binstub="${bindir}/${file##*/}" binstub="${bindir}/${file##*/}"
rm -f "$binstub" rm -f "$binstub"
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment