mirror of https://git.FreeBSD.org/ports.git
devel/sol2: fix dependant ports build failure with clang 18
PR: 282018
(cherry picked from commit 36244079e4
)
This commit is contained in:
parent
db5128afdb
commit
ce57a1a89f
|
@ -1,6 +1,7 @@
|
||||||
PORTNAME= sol2
|
PORTNAME= sol2
|
||||||
DISTVERSIONPREFIX= v
|
DISTVERSIONPREFIX= v
|
||||||
DISTVERSION= 4.0.0-alpha
|
DISTVERSION= 4.0.0-alpha
|
||||||
|
PORTREVISION= 1
|
||||||
CATEGORIES= devel
|
CATEGORIES= devel
|
||||||
|
|
||||||
MAINTAINER= yuri@FreeBSD.org
|
MAINTAINER= yuri@FreeBSD.org
|
||||||
|
@ -19,4 +20,11 @@ CMAKE_TESTING_ON= SOL2_TESTS
|
||||||
|
|
||||||
NO_ARCH= yes
|
NO_ARCH= yes
|
||||||
|
|
||||||
.include <bsd.port.mk>
|
.include <bsd.port.pre.mk>
|
||||||
|
|
||||||
|
.if ${CHOSEN_COMPILER_TYPE} == clang && \
|
||||||
|
${COMPILER_VERSION} >= 180 && ${COMPILER_VERSION} < 190
|
||||||
|
EXTRA_PATCHES= ${PATCHDIR}/extra-patch-include_sol_function__types__stateless.hpp
|
||||||
|
.endif
|
||||||
|
|
||||||
|
.include <bsd.port.post.mk>
|
||||||
|
|
|
@ -0,0 +1,24 @@
|
||||||
|
--- include/sol/function_types_stateless.hpp.orig 2021-03-06 06:03:23 UTC
|
||||||
|
+++ include/sol/function_types_stateless.hpp
|
||||||
|
@@ -320,7 +320,9 @@ namespace sol { namespace function_detail {
|
||||||
|
}
|
||||||
|
|
||||||
|
template <bool is_yielding, bool no_trampoline>
|
||||||
|
- static int call(lua_State* L) noexcept(std::is_nothrow_copy_assignable_v<T>) {
|
||||||
|
+ static int call(lua_State* L)
|
||||||
|
+ // regression in clang 18 - llvm/llvm-project#91362
|
||||||
|
+ {
|
||||||
|
int nr;
|
||||||
|
if constexpr (no_trampoline) {
|
||||||
|
nr = real_call(L);
|
||||||
|
@@ -360,7 +362,9 @@ namespace sol { namespace function_detail {
|
||||||
|
}
|
||||||
|
|
||||||
|
template <bool is_yielding, bool no_trampoline>
|
||||||
|
- static int call(lua_State* L) noexcept(std::is_nothrow_copy_assignable_v<T>) {
|
||||||
|
+ static int call(lua_State* L)
|
||||||
|
+ // regression in clang 18 - llvm/llvm-project#91362
|
||||||
|
+ {
|
||||||
|
int nr;
|
||||||
|
if constexpr (no_trampoline) {
|
||||||
|
nr = real_call(L);
|
Loading…
Reference in New Issue