Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 13 Feb 2021 14:12:47 GMT
From:      Alex Richardson <arichardson@FreeBSD.org>
To:        src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org
Subject:   git: 88db1cc9f197 - main - tools/build/make.py: drop workaround for cc --version not being parsed
Message-ID:  <202102131412.11DEClOL001015@gitrepo.freebsd.org>

next in thread | raw e-mail | index | archive | help
The branch main has been updated by arichardson:

URL: https://cgit.FreeBSD.org/src/commit/?id=88db1cc9f197a376817ce27ba269348666bbd4b7

commit 88db1cc9f197a376817ce27ba269348666bbd4b7
Author:     Alex Richardson <arichardson@FreeBSD.org>
AuthorDate: 2021-02-13 13:54:20 +0000
Commit:     Alex Richardson <arichardson@FreeBSD.org>
CommitDate: 2021-02-13 13:54:25 +0000

    tools/build/make.py: drop workaround for cc --version not being parsed
    
    Previously bsd.compiler.mk was not able to detect the compiler type for
    Ubuntu's /usr/bin/cc unless we were invoking the /usr/bin/gcc symlink.
    This problem has been fixed by 9c6954329a9285547881ddd60e393b7c55ed30c4
    so we can drop the workaround from make.py.
    
    Reviewed By:    jrtc27
    Differential Revision: https://reviews.freebsd.org/D28323
---
 tools/build/make.py | 11 ++---------
 1 file changed, 2 insertions(+), 9 deletions(-)

diff --git a/tools/build/make.py b/tools/build/make.py
index e692fef11e05..bc6d8fb449bb 100755
--- a/tools/build/make.py
+++ b/tools/build/make.py
@@ -182,13 +182,6 @@ if __name__ == "__main__":
                 sys.exit("TARGET= and TARGET_ARCH= must be set explicitly "
                          "when building on non-FreeBSD")
         # infer values for CC/CXX/CPP
-
-        if sys.platform.startswith(
-                "linux") and parsed_args.host_compiler_type == "cc":
-            # FIXME: bsd.compiler.mk doesn't handle the output of GCC if it
-            #  is /usr/bin/cc on Ubuntu since it doesn't contain the GCC string.
-            parsed_args.host_compiler_type = "gcc"
-
         if parsed_args.host_compiler_type == "gcc":
             default_cc, default_cxx, default_cpp = ("gcc", "g++", "cpp")
         # FIXME: this should take values like `clang-9` and then look for
@@ -225,8 +218,8 @@ if __name__ == "__main__":
         if not shutil.which("strip"):
             if sys.platform.startswith("darwin"):
                 # On macOS systems we have to use /usr/bin/strip.
-                sys.exit("Cannot find required tool 'strip'. Please install the"
-                         " host compiler and command line tools.")
+                sys.exit("Cannot find required tool 'strip'. Please install "
+                         "the host compiler and command line tools.")
             if parsed_args.host_compiler_type == "clang":
                 strip_binary = "llvm-strip"
             else:



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202102131412.11DEClOL001015>