# Build error on MacOS 10.12 with recent master (BinaryBuilder dependency issues?)

**URL:** https://discourse.julialang.org/t/build-error-on-macos-10-12-with-recent-master-binarybuilder-dependency-issues/24031
**Category:** General Usage
**Created:** [May 9, 2019, 1:59pm UTC](https://discourse.julialang.org/t/build-error-on-macos-10-12-with-recent-master-binarybuilder-dependency-issues/24031 "2019-05-09T13:59:28Z")
**Posts on this page:** 4
**Page:** 1

<div class="post-metadata">

### Author: ![jgoldfar](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/jgoldfar/32/2664_2.png) [@jgoldfar](https://discourse.julialang.org/u/jgoldfar)
#### Post date: [May 9, 2019, 1:59pm UTC](https://discourse.julialang.org/t/build-error-on-macos-10-12-with-recent-master-binarybuilder-dependency-issues/24031/1 "2019-05-09T13:59:28Z")

</div>

With a clean installation of a recent git clone, I’m unable to make it past the following error:

```julia
Traceback (most recent call last):
  File "/Users/jgoldfar/Public/julia-dev/contrib/normalize_triplet.py", line 118, in <module>
    }[list(filter(lambda x: re.match("\d+\.\d+\.\d+", x), sys.argv[2].split()))[-1][0]]
KeyError: '9'
  % Total % Received % Xferd Average Speed Time Time Time Current
                                 Dload Upload Total Spent Left Speed
100 425 100 425 0 0 1387 0 --:--:-- --:--:-- --:--:-- 1388
  0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0
curl: (22) The requested URL returned error: 404 Not Found
<snip>

```

It appears as though normalize\_triplet.py needs a patch to allow GCC9 such as

```julia
diff --git a/contrib/normalize_triplet.py b/contrib/normalize_triplet.py
index d3b168e71e..493415d326 100755
--- a/contrib/normalize_triplet.py
+++ b/contrib/normalize_triplet.py
@@ -115,6 +115,7 @@ if gcc_version == "blank_gcc":
             "6": "gcc4",
             "7": "gcc7",
             "8": "gcc8",
+ "9": "gcc9",
         }[list(filter(lambda x: re.match("\d+\.\d+\.\d+", x), sys.argv[2].split()))[-1][0]]
 
 if cxx_abi == "blank_cxx_abi":
-- 

```

(though setting `USECLANG=1` doesn’t remove this issue, so perhaps I’m misunderstanding this point) but then the corresponding file does not exist in the repository.  
Has anyone else come across this issue? Is the solution building the necessary dependencies from source?

---

<div class="post-metadata">

### Author: ![fredrikekre](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/fredrikekre/32/1688_2.png) [@fredrikekre](https://discourse.julialang.org/u/fredrikekre)
#### Post date: [May 9, 2019, 2:15pm UTC](https://discourse.julialang.org/t/build-error-on-macos-10-12-with-recent-master-binarybuilder-dependency-issues/24031/2 "2019-05-09T14:15:17Z")

</div>

I think that patch should work. Did you try?  
Alternatively, you can manually force compilation of dependencies with

```julia
USE_BINARYBUILDER=0

```

in a `Make.user` file.

---

<div class="post-metadata">

### Author: ![jgoldfar](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/jgoldfar/32/2664_2.png) [@jgoldfar](https://discourse.julialang.org/u/jgoldfar)
#### Post date: [May 9, 2019, 2:36pm UTC](https://discourse.julialang.org/t/build-error-on-macos-10-12-with-recent-master-binarybuilder-dependency-issues/24031/3 "2019-05-09T14:36:46Z")

</div>

Thanks for your help! That patch will fix normalize\_triplet.py, but then the gcc9 version is not available to be downloaded, and the build system doesn’t include any fallback.

In my case, downgrading the homebrew-provided GCC fixed the issue; I know that rebuilding all of the dependencies for each compiler release can be time consuming: is there a way I can contribute?

---

<div class="post-metadata">

### Author: ![fredrikekre](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/fredrikekre/32/1688_2.png) [@fredrikekre](https://discourse.julialang.org/u/fredrikekre)
#### Post date: [May 9, 2019, 2:40pm UTC](https://discourse.julialang.org/t/build-error-on-macos-10-12-with-recent-master-binarybuilder-dependency-issues/24031/4 "2019-05-09T14:40:17Z")

</div>

> [@jgoldfar](#):
>
> Thanks for your help! That patch will fix normalize\_triplet.py, but then the gcc9 version is not available to be downloaded, and the build system doesn’t include any fallback.

Okay, I misread your patch. What if you try

```diff
diff --git a/contrib/normalize_triplet.py b/contrib/normalize_triplet.py
index d3b168e71e..493415d326 100755
--- a/contrib/normalize_triplet.py
+++ b/contrib/normalize_triplet.py
@@ -115,6 +115,7 @@ if gcc_version == "blank_gcc":
             "6": "gcc4",
             "7": "gcc7",
             "8": "gcc8",
+ "9": "gcc8",
         }[list(filter(lambda x: re.match("\d+\.\d+\.\d+", x), sys.argv[2].split()))[-1][0]]
 
 if cxx_abi == "blank_cxx_abi":

```

IIRC they should be compatible.

> [@jgoldfar](#):
>
> I know that rebuilding all of the dependencies for each compiler release can be time consuming: is there a way I can contribute?

I think it is just a matter of time, but maybe you can open an issue just to keep track of it and link to this thread?

Edit: I opened an issue [Travis macOS failure due to gcc upgrade · Issue #31975 · JuliaLang/julia · GitHub](https://github.com/JuliaLang/julia/issues/31975)

Edit2: Fix merged to master: [Add GCC 9 support to `normalize_triplet.py` by staticfloat · Pull Request #31976 · JuliaLang/julia · GitHub](https://github.com/JuliaLang/julia/pull/31976)
