Tiny Core Linux
Tiny Core Base => Corepure64 => Topic started by: andyj on October 28, 2017, 11:58:38 AM
-
Busybox 1.25 (TC 8.0) mv would move all files in a wildcard source including links good or broken. Busybox 1.27 (TC 8.1+) mv will not move a link if it is broken. This is a bit of a challenge when building extensions because sometimes the link in the extension won't be good until the extension is installed. GNU mv on a distro like Slackware moves all links good and broken. Seems like mv changed for some reason?
-
Could you give an example - I just tried a quick test and was able to move a broken link?
-
Try:
mkdir -p /tmp/mvtest/TCZ/usr/local/lib /tmp/mvtest/TCZ-dev/usr/local/lib
cd /tmp/mvtest/TCZ-dev/usr/local/lib
touch libmy.so.1.0.1
ln -s libmy.so.1.0.1 libmy.so.1
ln -s libmynolink.so libmy.so
cd /tmp/mvtest
mv TCZ-dev/usr/local/lib/*.so* TCZ/usr/local/lib
find
If it matters this is 64 bit.
-
Confirmed, but this is actually an ash bug. Running your script under bash succeeds.
-
But this used to work in Busybox/ash 1.25 (TC 8.0) and before. "type mv is /bin/mv" which is still Busybox. The behavior changed. It didn't used to be a bug, or it would have been a problem before I upgraded past 8.0.
-
There have been few recent changes to mv in busybox git (5 this year), whereas there have been a bunch of changes to ash..
Could you submit a bug report to busybox?
-
I sent an email. This is also something we can fix with a config change, by disabling the "ash: use glob from libc" option.
And yeah, the bug was introduced after 1.25. Ash is part of busybox.
-
Meaning "CONFIG_ASH_INTERNAL_GLOB=y"?
-
Yeah, that one.