1
Fork 0
mirror of https://github.com/SapphireServer/Sapphire.git synced 2025-04-24 13:47:46 +00:00

Merge pull request #964 from arieshi255/fix-clang

Fix building on Clang and add Oodle support for Linux targets
This commit is contained in:
hkAlice 2024-07-28 05:15:17 -03:00 committed by GitHub
commit 32bea19f2c
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
7 changed files with 24 additions and 8 deletions

View file

@ -1,9 +1,19 @@
add_library(OodleNet STATIC IMPORTED GLOBAL)
set_target_properties(
if(WIN32)
set_target_properties(
OodleNet
PROPERTIES
IMPORTED_IMPLIB "${CMAKE_SOURCE_DIR}/deps/Oodle/oo2net_9_win64.lib"
IMPORTED_LOCATION "${CMAKE_SOURCE_DIR}/deps/Oodle/oo2net_9_win64.lib"
LINKER_LANGUAGE C
)
)
elseif(UNIX)
set_target_properties(
OodleNet
PROPERTIES
IMPORTED_IMPLIB "${CMAKE_SOURCE_DIR}/deps/Oodle/liboo2netlinux64.a"
IMPORTED_LOCATION "${CMAKE_SOURCE_DIR}/deps/Oodle/liboo2netlinux64.a"
LINKER_LANGUAGE C
)
endif()

View file

@ -1,6 +1,8 @@
#ifndef __OODLE2NET_H__
#define __OODLE2NET_H__
#include <stdint.h>
extern "C" intptr_t __stdcall OodleNetwork1_Shared_Size( int32_t htbits );
extern "C" intptr_t __stdcall OodleNetwork1UDP_State_Size();

View file

@ -249,7 +249,7 @@ namespace xiv::exd
for( int32_t i = 0; i < cacheEntry.second.subRows; i++ )
{
// Get the vector fields for the given record and preallocate it
ExdRow row = { cacheEntry.first, i };
ExdRow row = { cacheEntry.first, static_cast< uint8_t >( i ) };
auto& fields = data[ row ];
fields.reserve( memberCount );

View file

@ -5,6 +5,7 @@
#include <iomanip>
#include <sstream>
#include <vector>
#include <cstdint>
namespace xiv::utils::bparse
{

View file

@ -4,6 +4,7 @@
#include <list>
#include <map>
#include <iostream>
#include <cstdint>
namespace Mysql
{

View file

@ -27,6 +27,7 @@ with this program; if not, write to the Free Software Foundation, Inc.,
#include <iostream>
#include <sstream>
#include <cstdint>
typedef struct st_mysql_field MYSQL_FIELD;
#ifndef UL64

View file

@ -1,4 +1,5 @@
#include <string>
#include <cstdint>
namespace Sapphire::Common::Util
{