Skip to content

Commit 1e2a944

Browse files
committed
use #pragma comment only on msvc
1 parent ba1466f commit 1e2a944

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

netcode.c

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -168,15 +168,19 @@ void netcode_default_free_function( void * context, void * pointer )
168168
#include <ws2tcpip.h>
169169
#include <ws2ipdef.h>
170170
#include <iphlpapi.h>
171+
#ifdef _MSC_VER
171172
#pragma comment( lib, "WS2_32.lib" )
172173
#pragma comment( lib, "IPHLPAPI.lib" )
174+
#endif // #ifdef _MSC_VER
173175

174176
#ifdef SetPort
175177
#undef SetPort
176178
#endif // #ifdef SetPort
177179

178180
#include <iphlpapi.h>
181+
#ifdef _MSC_VER
179182
#pragma comment( lib, "IPHLPAPI.lib" )
183+
#endif // #ifdef _MSC_VER
180184

181185
#elif NETCODE_PLATFORM == NETCODE_PLATFORM_MAC || NETCODE_PLATFORM == NETCODE_PLATFORM_UNIX
182186

@@ -482,7 +486,9 @@ typedef UINT32 QOS_FLOWID, *PQOS_FLOWID;
482486
#endif // #ifdef __MINGW32__
483487
#include <qos2.h>
484488

489+
#ifdef _MSC_VER
485490
#pragma comment( lib, "Qwave.lib" )
491+
#endif // #ifdef _MSC_VER
486492

487493
static int netcode_set_socket_codepoint( SOCKET socket, QOS_TRAFFIC_TYPE trafficType, QOS_FLOWID flowId, PSOCKADDR addr )
488494
{

0 commit comments

Comments
 (0)