Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 751067 - bootstrap-prefix.sh: !!! unknown compiler on macOS
Summary: bootstrap-prefix.sh: !!! unknown compiler on macOS
Status: RESOLVED FIXED
Alias: None
Product: Gentoo/Alt
Classification: Unclassified
Component: Prefix Support (show other bugs)
Hardware: AMD64 OS X
: Normal trivial (vote)
Assignee: Gentoo Prefix
URL:
Whiteboard:
Keywords: PATCH
Depends on:
Blocks: 755644
  Show dependency tree
 
Reported: 2020-10-24 22:09 UTC by Alexander Bezrukov
Modified: 2020-11-20 01:32 UTC (History)
3 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
Fix for clang-11 version check (clang-version.patch,590 bytes, patch)
2020-10-24 22:13 UTC, Alexander Bezrukov
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Alexander Bezrukov 2020-10-24 22:09:17 UTC
I am trying to install Gentoo prefix on MacOS X (Mojave and Catalina). The system is fresh installed and mostly clean (Xcode is obviously an exception).

bootstrap-prefix.sh produces a series of error messages, then fails. I am trying to fix these errors one by one. This reports deals with the following error message:

!!! unknown compiler.

This error happens in function configure_toolchain(). My invocation of 'gcc --version' produces the following output:

Configured with: --prefix=/Library/Developer/CommandLineTools/usr --with-gxx-include-dir=/usr/include/c++/4.2.1
Apple clang version 11.0.0 (clang-1100.0.33.17)
Target: x86_64-apple-darwin18.7.0
Thread model: posix
InstalledDir: /Library/Developer/CommandLineTools/usr/bin

which obviously is slightly different with what the script expects.

The fix is trivial. I will be attaching a patch.

Reproducible: Always

Steps to Reproduce:
1. ./bootstrap-prefix.sh

Actual Results:  
!!! unknown compiler

Expected Results:  
No error message and the version of clang is properly determined.

Obviously I cannot provide 'emerge --info' output.
Comment 1 Alexander Bezrukov 2020-10-24 22:13:20 UTC
Created attachment 668363 [details, diff]
Fix for clang-11 version check

Tested on cleanish MacOS 10.14.6 with Xcode 11.3.1(11C505).
Comment 2 Larry the Git Cow gentoo-dev 2020-10-26 11:50:03 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/proj/prefix.git/commit/?id=c87ecd828f4b4de9ba80c32d3eaf19bfcfc6deea

commit c87ecd828f4b4de9ba80c32d3eaf19bfcfc6deea
Author:     Fabian Groffen <grobian@gentoo.org>
AuthorDate: 2020-10-26 11:49:09 +0000
Commit:     Fabian Groffen <grobian@gentoo.org>
CommitDate: 2020-10-26 11:49:09 +0000

    scripts/bootstrap-prefix.sh: add detection support for newer Apple clang
    
    Thanks Alexander Bezrukov for an initial patch.  I went with a slightly
    different approach, to be a bit more specific and hopefully not match
    something unexpected in the future.
    
    Closes: https://bugs.gentoo.org/751067
    Signed-off-by: Fabian Groffen <grobian@gentoo.org>

 scripts/bootstrap-prefix.sh | 17 +++++++++++++++++
 1 file changed, 17 insertions(+)