<pre style='margin:0'>
Chris Jones (cjones051073) pushed a commit to branch master
in repository macports-ports.

</pre>
<p><a href="https://github.com/macports/macports-ports/commit/08f1da8d2625406e5168150dc5ccb48bad29bae3">https://github.com/macports/macports-ports/commit/08f1da8d2625406e5168150dc5ccb48bad29bae3</a></p>
<pre style="white-space: pre; background: #F8F8F8">The following commit(s) were added to refs/heads/master by this push:
<span style='display:block; white-space:pre;color:#404040;'>     new 08f1da8d262 llvm 17: Disable Werror on darwin < 17
</span>08f1da8d262 is described below

<span style='display:block; white-space:pre;color:#808000;'>commit 08f1da8d2625406e5168150dc5ccb48bad29bae3
</span>Author: Chris Jones <jonesc@macports.org>
AuthorDate: Tue Sep 26 10:00:06 2023 +0100

<span style='display:block; white-space:pre;color:#404040;'>    llvm 17: Disable Werror on darwin < 17
</span>---
 lang/llvm-17/Portfile                              |  9 ++++--
 ...0041-no-Werror-unguarded-availability-new.patch | 32 ++++++++++++++++++++++
 2 files changed, 39 insertions(+), 2 deletions(-)

<span style='display:block; white-space:pre;color:#808080;'>diff --git a/lang/llvm-17/Portfile b/lang/llvm-17/Portfile
</span><span style='display:block; white-space:pre;color:#808080;'>index 3240bd3efd4..cb7b847207a 100644
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>--- a/lang/llvm-17/Portfile
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/lang/llvm-17/Portfile
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -17,6 +17,7 @@ legacysupport.use_static              yes
</span> legacysupport.disable_function_wrap   yes
 
 categories              lang
<span style='display:block; white-space:pre;background:#e0ffe0;'>+platforms               {darwin >= 11}
</span> license                 NCSA
 maintainers             nomaintainer
 
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -49,7 +50,7 @@ compiler.blacklist      *gcc* {clang < 1001} macports-clang-3.*
</span> # work/build/include/c++/v1/optional:224:5: error: destructor cannot be marked constexpr
 #     _LIBCPP_CONSTEXPR_AFTER_CXX17 ~__optional_destruct_base()
 compiler.blacklist-append {clang < 1204} {macports-clang-[5-9].0} {macports-clang-1[0-3]}
<span style='display:block; white-space:pre;background:#ffe0e0;'>-compiler.fallback       clang macports-clang-14 macports-clang-15
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+compiler.fallback       clang macports-clang-16 macports-clang-15 macports-clang-14
</span> 
 # We can't use Ninja with our custom destrooting plan for llvm
 #cmake.generator         Ninja
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -203,6 +204,11 @@ if {${os.platform} eq "darwin"} {
</span>     patchfiles-append b98da4c71edda3df0a0555b1ab63ec52e92252b4-inverse.patch
 }
 
<span style='display:block; white-space:pre;background:#e0ffe0;'>+if {${os.platform} eq "darwin" && ${os.major} <= 16} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+    # error: 'utimensat' is only available on macOS 10.13 or newer
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+    patchfiles-append 0041-no-Werror-unguarded-availability-new.patch
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+}
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span> post-patch {
     reinplace "s|@@PREFIX@@|${prefix}|" \
         ${patch.dir}/clang/lib/Driver/ToolChains/Clang.cpp \
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -371,7 +377,6 @@ if { ${subport} eq "clang-${llvm_version}" || ${subport} eq "flang-${llvm_versio
</span>         configure.args-append    -DCLANG_ENABLE_CLANGD=OFF \
                                  -DLLVM_ENABLE_BACKTRACES=OFF
     }
<span style='display:block; white-space:pre;background:#ffe0e0;'>-
</span> }
 
 if {${subport} eq "lldb-${llvm_version}"} {
<span style='display:block; white-space:pre;color:#808080;'>diff --git a/lang/llvm-17/files/0041-no-Werror-unguarded-availability-new.patch b/lang/llvm-17/files/0041-no-Werror-unguarded-availability-new.patch
</span>new file mode 100644
<span style='display:block; white-space:pre;color:#808080;'>index 00000000000..be256718ed9
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>--- /dev/null
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/lang/llvm-17/files/0041-no-Werror-unguarded-availability-new.patch
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -0,0 +1,32 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+diff --git a/HandleLLVMOptions.cmake.orig b/HandleLLVMOptions.cmake
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+index 76723be..1d6d880 100644
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+--- a/llvm/cmake/modules/HandleLLVMOptions.cmake
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++++ b/llvm/cmake/modules/HandleLLVMOptions.cmake
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -600,7 +600,7 @@ endif( LLVM_COMPILER_IS_GCC_COMPATIBLE )
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ # Specific default warnings-as-errors for compilers accepting GCC-compatible warning flags:
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if ( LLVM_COMPILER_IS_GCC_COMPATIBLE OR CMAKE_CXX_COMPILER_ID MATCHES "XL" )
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+   add_flag_if_supported("-Werror=date-time" WERROR_DATE_TIME)
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+-  add_flag_if_supported("-Werror=unguarded-availability-new" WERROR_UNGUARDED_AVAILABILITY_NEW)
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++  #add_flag_if_supported("-Werror=unguarded-availability-new" WERROR_UNGUARDED_AVAILABILITY_NEW)
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ endif( LLVM_COMPILER_IS_GCC_COMPATIBLE OR CMAKE_CXX_COMPILER_ID MATCHES "XL" )
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ 
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if ( LLVM_COMPILER_IS_GCC_COMPATIBLE )
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+diff --git a/config-ix.cmake.orig b/config-ix.cmake
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+index f63c3f1..2a2dd10 100644
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+--- a/llvm/cmake/config-ix.cmake
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++++ b/llvm/cmake/config-ix.cmake
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -271,10 +271,10 @@ set(BACKTRACE_HEADER ${Backtrace_HEADER})
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ 
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ # Prevent check_symbol_exists from using API that is not supported for a given
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ # deployment target.
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+-check_c_compiler_flag("-Werror=unguarded-availability-new" "C_SUPPORTS_WERROR_UNGUARDED_AVAILABILITY_NEW")
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+-if(C_SUPPORTS_WERROR_UNGUARDED_AVAILABILITY_NEW)
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+-  set(CMAKE_REQUIRED_FLAGS "${CMAKE_REQUIRED_FLAGS} -Werror=unguarded-availability-new")
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+-endif()
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++#check_c_compiler_flag("-Werror=unguarded-availability-new" "C_SUPPORTS_WERROR_UNGUARDED_AVAILABILITY_NEW")
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++#if(C_SUPPORTS_WERROR_UNGUARDED_AVAILABILITY_NEW)
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++#  set(CMAKE_REQUIRED_FLAGS "${CMAKE_REQUIRED_FLAGS} -Werror=unguarded-availability-new")
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++#endif()
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ 
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ # Determine whether we can register EH tables.
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ check_symbol_exists(__register_frame "${CMAKE_CURRENT_LIST_DIR}/unwind.h" HAVE_REGISTER_FRAME)
</span></pre><pre style='margin:0'>

</pre>