Skip to content

Commit d82375e

Browse files
committed
add fixes to support clang
1 parent 1a1ae95 commit d82375e

File tree

3 files changed

+4
-3
lines changed

3 files changed

+4
-3
lines changed

external/sources/RakNet/meson.build

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ deps = []
99

1010
if cxx.get_argument_syntax() == 'gcc'
1111
cpp_args = ['-w', '-fpermissive']
12+
cpp_options = ['cpp_std=gnu++11']
1213
if host_machine.system() == 'windows'
1314
cpp_args += ['-D_ITERATOR_DEBUG_LEVEL=0','-DWIN32','-D_RAKNET_LIB','-D_CRT_NONSTDC_NO_DEPRECATE','-D_CRT_SECURE_NO_DEPRECATE']
1415
if get_option('debug')
@@ -32,4 +33,4 @@ else
3233
endif
3334
raknet_dep = declare_dependency(link_with: raknet, dependencies: deps, include_directories: raknet_include)
3435

35-
meson.override_dependency('RakNet', raknet_dep)
36+
meson.override_dependency('RakNet', raknet_dep)

external/sources/RakNet/src/ReplicaManager3.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -138,7 +138,7 @@ void ReplicaManager3::AutoCreateConnectionList(
138138
{
139139
for (unsigned int index=0; index < participantListIn.Size(); index++)
140140
{
141-
if (GetConnectionByGUID(participantListIn[index], worldId)==false)
141+
if (!GetConnectionByGUID(participantListIn[index], worldId))
142142
{
143143
Connection_RM3 *connection = AllocConnection(rakPeerInterface->GetSystemAddressFromGuid(participantListIn[index]), participantListIn[index]);
144144
if (connection)

meson.build

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ override_options = []
1414
suffix=''
1515

1616
if compiler.get_id() == 'clang'
17-
error('LLVM clang is not supported due to missing features of the clang standard library. (std::execution)')
17+
warning('LLVM clang is not directly supported due to missing features of the clang standard library. Remember to set cpp_std to gnu++20 or force libstdc++ otherwise (std::execution)')
1818
endif
1919

2020
if host_machine.system() == 'darwin' and get_option('b_lto')

0 commit comments

Comments
 (0)