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.
Steps to Reproduce:
stat: illegal option -- c
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 .
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):
Author: Alexander Bezrukov <firstname.lastname@example.org>
AuthorDate: 2020-10-25 08:14:22 +0000
Commit: Fabian Groffen <email@example.com>
CommitDate: 2020-10-25 08:14:22 +0000
scripts/bootstrap-prefix: fix stat invocation for Darwin/*BSD
Signed-off-by: Fabian Groffen <firstname.lastname@example.org>
scripts/bootstrap-prefix.sh | 11 +++++++++--
1 file changed, 9 insertions(+), 2 deletions(-)