Backup.
This commit is contained in:
parent
fbd8464043
commit
c23cbc275f
26
Assembly.def
Normal file
26
Assembly.def
Normal file
@ -0,0 +1,26 @@
|
||||
LIBRARY EHS_Dyn
|
||||
EXPORTS
|
||||
?GenerateSeed_u64@HRNG@ehs@@SA_KXZ
|
||||
?Generate_u64@HRNG@ehs@@SA_K_K0@Z
|
||||
?Generate_u64@HRNG@ehs@@SA_KXZ
|
||||
?GenerateSeed_s64@HRNG@ehs@@SA_JXZ
|
||||
?Generate_s64@HRNG@ehs@@SA_J_J0@Z
|
||||
?Generate_s64@HRNG@ehs@@SA_JXZ
|
||||
?GenerateSeed_u32@HRNG@ehs@@SAIXZ
|
||||
?Generate_u32@HRNG@ehs@@SAIII@Z
|
||||
?Generate_u32@HRNG@ehs@@SAIXZ
|
||||
?GenerateSeed_s32@HRNG@ehs@@SAHXZ
|
||||
?Generate_s32@HRNG@ehs@@SAHHH@Z
|
||||
?Generate_s32@HRNG@ehs@@SAHXZ
|
||||
?GenerateSeed_u16@HRNG@ehs@@SAIXZ
|
||||
?Generate_u16@HRNG@ehs@@SAGGG@Z
|
||||
?Generate_u16@HRNG@ehs@@SAGXZ
|
||||
?GenerateSeed_s16@HRNG@ehs@@SAFXZ
|
||||
?Generate_s16@HRNG@ehs@@SAFFF@Z
|
||||
?Generate_s16@HRNG@ehs@@SAFXZ
|
||||
?GenerateSeed_u8@HRNG@ehs@@SAEXZ
|
||||
?Generate_u8@HRNG@ehs@@SAEEE@Z
|
||||
?Generate_u8@HRNG@ehs@@SAEXZ
|
||||
?GenerateSeed_s8@HRNG@ehs@@SACXZ
|
||||
?Generate_s8@HRNG@ehs@@SACCC@Z
|
||||
?Generate_s8@HRNG@ehs@@SACXZ
|
@ -1,4 +1,4 @@
|
||||
cmake_minimum_required(VERSION 3.25.1)
|
||||
cmake_minimum_required(VERSION 3.30.4)
|
||||
|
||||
set(IS_OS_WINDOWS FALSE)
|
||||
set(IS_OS_LINUX FALSE)
|
||||
@ -11,6 +11,8 @@ set(IS_ARCH_ARM FALSE)
|
||||
|
||||
project(EHS CXX C)
|
||||
|
||||
set(CMAKE_VERBOSE_MAKEFILE ON)
|
||||
|
||||
if (${CMAKE_HOST_SYSTEM_NAME} STREQUAL "Windows")
|
||||
set(IS_OS_WINDOWS TRUE)
|
||||
set(USER_HOME_DIRECTORY "$ENV{USERPROFILE}")
|
||||
@ -262,11 +264,8 @@ elseif (IS_OS_LINUX)
|
||||
endif ()
|
||||
endif()
|
||||
|
||||
#set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fPIC")
|
||||
#message("${CMAKE_CXX_FLAGS}")
|
||||
|
||||
add_library(EHS_Stc STATIC ${EHS_SOURCES})
|
||||
add_library(EHS_Dyn SHARED ${EHS_SOURCES})
|
||||
add_library(EHS_Dyn SHARED ${EHS_SOURCES} Assembly.def)
|
||||
add_executable(StrToHash src/StrToHash.cpp)
|
||||
|
||||
target_compile_definitions(EHS_Dyn PRIVATE EHS_LIB_EXPORT)
|
||||
|
@ -5,7 +5,7 @@
|
||||
|
||||
namespace ehs
|
||||
{
|
||||
class EHS_LIB_IO HRNG
|
||||
class HRNG
|
||||
{
|
||||
public:
|
||||
static UInt_64 GenerateSeed_u64();
|
||||
|
@ -3,7 +3,7 @@
|
||||
|
||||
namespace ehs
|
||||
{
|
||||
class SHA256
|
||||
class EHS_LIB_IO SHA256
|
||||
{
|
||||
private:
|
||||
static UInt_32 ROTR(UInt_32 x, UInt_32 n);
|
||||
|
@ -84,6 +84,8 @@ namespace ehs
|
||||
|
||||
bool IsIPv6Only() const override;
|
||||
|
||||
void SetReuse(const bool &value) override;
|
||||
|
||||
bool IsValid() const override;
|
||||
|
||||
private:
|
||||
|
@ -4,7 +4,7 @@
|
||||
|
||||
namespace ehs
|
||||
{
|
||||
class AVX2
|
||||
class EHS_LIB_IO AVX2
|
||||
{
|
||||
public:
|
||||
/// Compares two unaligned 4 element vectors using 64-bit integers.
|
||||
|
@ -4,7 +4,7 @@
|
||||
|
||||
namespace ehs
|
||||
{
|
||||
class AVX512
|
||||
class EHS_LIB_IO AVX512
|
||||
{
|
||||
public:
|
||||
/// Compares two unaligned 8 element vectors using 64-bit integers.
|
||||
|
@ -1,4 +1,5 @@
|
||||
#include "ehs/io/socket/SSL.h"
|
||||
#include "ehs/io/Console.h"
|
||||
|
||||
#include <openssl/ssl.h>
|
||||
#include <openssl/bio.h>
|
||||
@ -163,10 +164,16 @@ namespace ehs
|
||||
OpenSSL_add_ssl_algorithms();
|
||||
SSL_load_error_strings();
|
||||
|
||||
if (!OPENSSL_init_ssl(OPENSSL_INIT_LOAD_CONFIG, nullptr))
|
||||
{
|
||||
EHS_LOG_INT(LogType::ERR, 0, "Failed to initialize OpenSSL.");
|
||||
return;
|
||||
}
|
||||
|
||||
ctx = SSL_CTX_new(TLS_client_method());
|
||||
if (!ctx)
|
||||
{
|
||||
EHS_LOG_INT(LogType::ERR, 0, "Failed to creat SSL context.");
|
||||
EHS_LOG_INT(LogType::ERR, 1, "Failed to creat SSL context.");
|
||||
return;
|
||||
}
|
||||
|
||||
@ -182,7 +189,19 @@ namespace ehs
|
||||
SInt_32 rc = SSL_connect(sslHdl);
|
||||
if (rc != 1)
|
||||
{
|
||||
EHS_LOG_INT(LogType::ERR, 1, "Failed to connect with error #" + Str_8::FromNum(SSL_get_error(sslHdl, rc)) + ".");
|
||||
SInt_32 err = SSL_get_error(sslHdl, rc);
|
||||
if (err == SSL_ERROR_SSL)
|
||||
{
|
||||
UInt_32 e;
|
||||
while ((e = ERR_get_error()) != 0)
|
||||
{
|
||||
char buf[256];
|
||||
ERR_error_string_n(e, buf, sizeof(buf));
|
||||
Console::Write_8(Str_8(buf));
|
||||
}
|
||||
}
|
||||
|
||||
EHS_LOG_INT(LogType::ERR, 2, "Failed to connect with error #" + Str_8::FromNum(err) + ".");
|
||||
|
||||
return;
|
||||
}
|
||||
|
@ -406,6 +406,10 @@ namespace ehs
|
||||
return result;
|
||||
}
|
||||
|
||||
void TCP::SetReuse(const bool &value)
|
||||
{
|
||||
}
|
||||
|
||||
bool TCP::IsValid() const
|
||||
{
|
||||
return hdl != EHS_INVALID_SOCKET;
|
||||
|
Loading…
x
Reference in New Issue
Block a user