I am trying to install Gentoo prefix on MacOS X (Mojave and Catalina). bootstrap-prefix.sh relies on the GNU version of the stat utility. MacOS X and FreeBSD (and probably other *BSD) have the BSD version of this utility installed, which use another set of flags. Therefore is the error message. The fix is trivial. I will be attaching a patch. Reproducible: Always Steps to Reproduce: 1. ./bootstrap-prefix.sh Actual Results: stat: illegal option -- c Expected Results: No error message and the intended check is actually performed Obviously I cannot provide 'emerge --info' output. I also used the 'Other' component because the web interface for Gentoo Bugzilla asks to not file bugs under 'Mac OSX', reserving it to ppc Macs.
Created attachment 668306 [details, diff] A trivial fix for stat invocation in bootstrap-prefix.sh Tested on clean MacOS 10.14.6. Untested on *BSD (but consulted FreeBSD stat(1) man page [0]. 0: https://www.freebsd.org/cgi/man.cgi?query=stat&manpath=FreeBSD+12.1-RELEASE+and+Ports
Have you actually managed to get a bootstrap working? (See the other bug).
(In reply to Sam James from comment #2) > Have you actually managed to get a bootstrap working? (See the other bug). Only stage 1, then I have got the messages: * ready to bootstrap stage2_log !!! unknown compiler I haven't had a chance to really look into this yet. This error is preceeded by several other errors during the script execution, I started to clean them one by one, this bug is the beginning (not sure if I will be able to make real progress). I did a dumb and trivial fix for the /usr/include problem, simply symlinked the SDK include dir to /usr/include (disabled SIP for this single operation). I am a very newbie in the MacOS, probably I don't understand yet the real problem.
The bug has been closed via the following commit(s): https://gitweb.gentoo.org/repo/proj/prefix.git/commit/?id=6b522acbb352eaae250d54b48456350ded50d7ce commit 6b522acbb352eaae250d54b48456350ded50d7ce Author: Alexander Bezrukov <phmagic@mail.ru> AuthorDate: 2020-10-25 08:14:22 +0000 Commit: Fabian Groffen <grobian@gentoo.org> CommitDate: 2020-10-25 08:14:22 +0000 scripts/bootstrap-prefix: fix stat invocation for Darwin/*BSD Closes: https://bugs.gentoo.org/751037 Signed-off-by: Fabian Groffen <grobian@gentoo.org> scripts/bootstrap-prefix.sh | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-)