Merge branch 'master' of github.com:InvictusInnovations/fc
This commit is contained in:
commit
a254e5ff28
6 changed files with 20 additions and 4 deletions
|
|
@ -202,6 +202,7 @@ ELSE()
|
||||||
IF(APPLE)
|
IF(APPLE)
|
||||||
SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11 -stdlib=libc++ -Wall")
|
SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11 -stdlib=libc++ -Wall")
|
||||||
ELSE()
|
ELSE()
|
||||||
|
target_compile_options(fc PUBLIC -std=c++11 -Wall -fnon-call-exceptions)
|
||||||
SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11 -Wall -fnon-call-exceptions")
|
SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11 -Wall -fnon-call-exceptions")
|
||||||
ENDIF()
|
ENDIF()
|
||||||
ENDIF()
|
ENDIF()
|
||||||
|
|
|
||||||
|
|
@ -58,7 +58,7 @@ namespace fc
|
||||||
|
|
||||||
/** Allows to explicitly specify OpenSSL configuration file path to be loaded at OpenSSL library init.
|
/** Allows to explicitly specify OpenSSL configuration file path to be loaded at OpenSSL library init.
|
||||||
If not set OpenSSL will try to load the conf. file (openssl.cnf) from the path it was
|
If not set OpenSSL will try to load the conf. file (openssl.cnf) from the path it was
|
||||||
configured with what caused serious Keyhotee startup bugs on some Win7 machines.
|
configured with what caused serious Keyhotee startup bugs on some Win7, Win8 machines.
|
||||||
\warning to be effective this method should be used before any part using OpenSSL, especially
|
\warning to be effective this method should be used before any part using OpenSSL, especially
|
||||||
before init_openssl call
|
before init_openssl call
|
||||||
*/
|
*/
|
||||||
|
|
|
||||||
|
|
@ -165,6 +165,9 @@ namespace fc {
|
||||||
*/
|
*/
|
||||||
const path& app_path();
|
const path& app_path();
|
||||||
|
|
||||||
|
/** @return application executable path */
|
||||||
|
const fc::path& current_path();
|
||||||
|
|
||||||
class variant;
|
class variant;
|
||||||
void to_variant( const fc::path&, fc::variant& );
|
void to_variant( const fc::path&, fc::variant& );
|
||||||
void from_variant( const fc::variant& , fc::path& );
|
void from_variant( const fc::variant& , fc::path& );
|
||||||
|
|
|
||||||
|
|
@ -49,7 +49,7 @@ namespace fc {
|
||||||
friend class tcp_server;
|
friend class tcp_server;
|
||||||
class impl;
|
class impl;
|
||||||
#ifdef _WIN64
|
#ifdef _WIN64
|
||||||
fc::fwd<impl,0x78> my;
|
fc::fwd<impl,0x81> my;
|
||||||
#else
|
#else
|
||||||
fc::fwd<impl,0x54> my;
|
fc::fwd<impl,0x54> my;
|
||||||
#endif
|
#endif
|
||||||
|
|
|
||||||
|
|
@ -49,7 +49,13 @@ namespace fc
|
||||||
|
|
||||||
int init_openssl()
|
int init_openssl()
|
||||||
{
|
{
|
||||||
static openssl_scope ossl;
|
auto strAppDir = current_path();
|
||||||
return 0;
|
fc::path appDir(strAppDir);
|
||||||
|
fc::path openSSLConf = appDir / "openssl.cnf";
|
||||||
|
if (fc::exists(openSSLConf))
|
||||||
|
fc::store_configuration_path(openSSLConf);
|
||||||
|
|
||||||
|
static openssl_scope ossl;
|
||||||
|
return 0;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -421,4 +421,10 @@ namespace fc {
|
||||||
#endif
|
#endif
|
||||||
return appdir;
|
return appdir;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
const fc::path& current_path()
|
||||||
|
{
|
||||||
|
static fc::path appCurrentPath = boost::filesystem::current_path();
|
||||||
|
return appCurrentPath;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue