<table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>Issue</th>
<td>
<a href=https://github.com/llvm/llvm-project/issues/106361>106361</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>
Build failure with ENABLE_Z3_SOLVER=ON for homebrew
</td>
</tr>
<tr>
<th>Labels</th>
<td>
new issue
</td>
</tr>
<tr>
<th>Assignees</th>
<td>
</td>
</tr>
<tr>
<th>Reporter</th>
<td>
lukeshingles
</td>
</tr>
</table>
<pre>
llvm 19.1.0rc3 fails to build on homebrew for macOS 12 with AppleClang 14.0.0.14000029
PR for llvm 19: https://github.com/Homebrew/homebrew-core/pull/181351
Actions output: https://github.com/Homebrew/homebrew-core/actions/runs/10579224738/job/29311433866?pr=181351
Full log: [job-logs.txt.zip](https://github.com/user-attachments/files/16782168/job-logs.txt.zip)
```sh
2024-08-27T18:04:17.1066420Z /private/tmp/llvm-20240827-62116-de3bz4/llvm-project-19.1.0-rc3.src/llvm/stage1/bin/clang++ -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS -I/tmp/llvm-20240827-62116-de3bz4/llvm-project-19.1.0-rc3.src/llvm/build/lib/Support -I/tmp/llvm-20240827-62116-de3bz4/llvm-project-19.1.0-rc3.src/llvm/lib/Support -I/tmp/llvm-20240827-62116-de3bz4/llvm-project-19.1.0-rc3.src/llvm/build/include -I/tmp/llvm-20240827-62116-de3bz4/llvm-project-19.1.0-rc3.src/llvm/include -isystem /opt/homebrew/include -Wno-backend-plugin -stdlib=libc++ -fPIC -fvisibility-inlines-hidden -Werror=date-time -Werror=unguarded-availability-new -Wall -Wextra -Wno-unused-parameter -Wwrite-strings -Wcast-qual -Wmissing-field-initializers -pedantic -Wno-long-long -Wc++98-compat-extra-semi -Wimplicit-fallthrough -Wcovered-switch-default -Wno-noexcept-type -Wnon-virtual-dtor -Wdelete-non-virtual-dtor -Wsuggest-override -Wno-comment -Wstring-conversion -Wmisleading-indentation -Wctad-maybe-unsupported -fdiagnostics-color -fprofile-instr-use="/tmp/llvm-20240827-62116-de3bz4/llvm-project-19.1.0-rc3.src/llvm/stage2/profiles/pgo_profile.prof" -flto=thin -O3 -DNDEBUG -std=c++17 -arch arm64 -isysroot /Library/Developer/CommandLineTools/SDKs/MacOSX12.sdk -MD -MT lib/Support/CMakeFiles/LLVMSupport.dir/Z3Solver.cpp.o -MF lib/Support/CMakeFiles/LLVMSupport.dir/Z3Solver.cpp.o.d -o lib/Support/CMakeFiles/LLVMSupport.dir/Z3Solver.cpp.o -c /tmp/llvm-20240827-62116-de3bz4/llvm-project-19.1.0-rc3.src/llvm/lib/Support/Z3Solver.cpp
2024-08-27T18:04:17.1072470Z /tmp/llvm-20240827-62116-de3bz4/llvm-project-19.1.0-rc3.src/llvm/lib/Support/Z3Solver.cpp:950:8: error: no template named 'unordered_map' in namespace 'std'
2024-08-27T18:04:17.1073240Z 950 | std::unordered_map<std::string, unsigned> UnsignedValues;
2024-08-27T18:04:17.1073560Z | ~~~~~^
2024-08-27T18:04:17.1074220Z /tmp/llvm-20240827-62116-de3bz4/llvm-project-19.1.0-rc3.src/llvm/lib/Support/Z3Solver.cpp:951:8: error: no template named 'unordered_map' in namespace 'std'
2024-08-27T18:04:17.1074950Z 951 | std::unordered_map<std::string, double> DoubleValues;
2024-08-27T18:04:17.1075260Z | ~~~~~^
2024-08-27T18:04:17.1076360Z /tmp/llvm-20240827-62116-de3bz4/llvm-project-19.1.0-rc3.src/llvm/lib/Support/Z3Solver.cpp:973:10: error: no viable conversion from returned value of type 'unique_ptr<(anonymous namespace)::Z3Statistics>' to function return type 'unique_ptr<SMTSolverStatistics>'
2024-08-27T18:04:17.1077490Z 973 | return std::make_unique<Z3Statistics>(std::move(Result));
2024-08-27T18:04:17.1077850Z | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
2024-08-27T18:04:17.1079420Z /Library/Developer/CommandLineTools/SDKs/MacOSX12.sdk/usr/include/c++/v1/__memory/unique_ptr.h:121:59: note: candidate constructor (the implicit copy constructor) not viable: no known conversion from 'typename __unique_if<Z3Statistics>::__unique_single' (aka 'unique_ptr<(anonymous namespace)::Z3Statistics>') to 'const unique_ptr<SMTSolverStatistics> &' for 1st argument
2024-08-27T18:04:17.1080860Z 121 | class _LIBCPP_UNIQUE_PTR_TRIVIAL_ABI _LIBCPP_TEMPLATE_VIS unique_ptr {
2024-08-27T18:04:17.1081260Z | ^~~~~~~~~~
2024-08-27T18:04:17.1082690Z /Library/Developer/CommandLineTools/SDKs/MacOSX12.sdk/usr/include/c++/v1/__memory/unique_ptr.h:185:21: note: candidate constructor template not viable: no known conversion from 'typename __unique_if<Z3Statistics>::__unique_single' (aka 'unique_ptr<(anonymous namespace)::Z3Statistics>') to 'nullptr_t' (aka 'std::nullptr_t') for 1st argument
2024-08-27T18:04:17.1084140Z 185 | _LIBCPP_CONSTEXPR unique_ptr(nullptr_t) _NOEXCEPT : __ptr_(pointer(), __default_init_tag()) {}
2024-08-27T18:04:17.1084580Z | ^ ~~~~~~~~~
2024-08-27T18:04:17.1085950Z /Library/Developer/CommandLineTools/SDKs/MacOSX12.sdk/usr/include/c++/v1/__memory/unique_ptr.h:213:3: note: candidate constructor not viable: no known conversion from 'typename __unique_if<Z3Statistics>::__unique_single' (aka 'unique_ptr<(anonymous namespace)::Z3Statistics>') to 'unique_ptr<SMTSolverStatistics> &&' for 1st argument
2024-08-27T18:04:17.1087230Z 213 | unique_ptr(unique_ptr&& __u) _NOEXCEPT
2024-08-27T18:04:17.1087500Z | ^ ~~~~~~~~~~~~~~~~
2024-08-27T18:04:17.1088980Z /Library/Developer/CommandLineTools/SDKs/MacOSX12.sdk/usr/include/c++/v1/__memory/unique_ptr.h:222:3: note: candidate template ignored: requirement 'is_convertible<(anonymous namespace)::Z3Statistics *, llvm::SMTSolverStatistics *>::value' was not satisfied [with _Up = (anonymous namespace)::Z3Statistics, _Ep = std::default_delete<(anonymous namespace)::Z3Statistics>]
2024-08-27T18:04:17.1090330Z 222 | unique_ptr(unique_ptr<_Up, _Ep>&& __u) _NOEXCEPT
2024-08-27T18:04:17.1090620Z | ^
2024-08-27T18:04:17.1091180Z /Library/Developer/CommandLineTools/SDKs/MacOSX12.sdk/usr/include/c++/v1/__memory/unique_ptr.h:190:12: note: explicit constructor is not a candidate
2024-08-27T18:04:17.1091970Z 190 | explicit unique_ptr(pointer __p) _NOEXCEPT : __ptr_(__p, __default_init_tag()) {}
2024-08-27T18:04:17.1092360Z | ^
2024-08-27T18:04:17.1093100Z /tmp/llvm-20240827-62116-de3bz4/llvm-project-19.1.0-rc3.src/llvm/lib/Support/Z3Solver.cpp:950:45: warning: private field 'UnsignedValues' is not used [-Wunused-private-field]
2024-08-27T18:04:1
7.1093920Z 950 | std::unordered_map<std::string, unsigned> UnsignedValues;
2024-08-27T18:04:17.1094260Z | ^
2024-08-27T18:04:17.1095070Z /tmp/llvm-20240827-62116-de3bz4/llvm-project-19.1.0-rc3.src/llvm/lib/Support/Z3Solver.cpp:951:43: warning: private field 'DoubleValues' is not used [-Wunused-private-field]
2024-08-27T18:04:17.1095850Z 951 | std::unordered_map<std::string, double> DoubleValues;
2024-08-27T18:04:17.1096180Z | ^
2024-08-27T18:04:17.1096440Z 2 warnings and 3 errors generated.
```
</pre>
<img width="1px" height="1px" alt="" src="http://email.email.llvm.org/o/eJzUmV1z46jSgH8NuaFwSSBZ0kUuFH-8b-rk6yTOZCs3KixhmQ0CDSBnMhf720-B5MRJZseTmeyk1pWKbAHdDf3QNECN4bVk7BDERyCeHtDOrpU-FN0dM2sua8HMwVJVD4dCbBoYZqNwFOiSwBXlwkCr4LLjooJKwrVq2FKze7hSGja0PL-CIYb33K5h3raCTQSVNQyjUTAKRmEUBEGAMwiCKQjyi0vfatABSA7X1rYGkBzgOcDzmtt1txyVqgF4_v-DIoDnW52oVJoBPG87IQCeh2lI4rAXnZeWK2mg6mzb2Z8XTXs5AM915x9hECcZxlFCUoDnf6olwHOckTCMCEnHY0DmrQZkumvL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