an attempt to fix issue #111

This commit is contained in:
Denis Ryabov 2014-03-17 23:23:53 +04:00
parent 21b0daf7f8
commit 671bec8e78
9 changed files with 13 additions and 3 deletions

View File

@ -22,6 +22,8 @@
#include <boost/filesystem/convenience.hpp>
#include <boost/interprocess/sync/file_lock.hpp>
#include <boost/algorithm/string/predicate.hpp>
#include <boost/locale.hpp>
#include <boost/locale/generator.hpp>
#include <openssl/crypto.h>
#ifndef WIN32
@ -399,6 +401,7 @@ bool AppInit2(boost::thread_group& threadGroup)
#endif
#endif
#endif
std::locale::global(boost::locale::generator().generate(""));
// ********************************************************* Step 2: parameter interactions

View File

@ -174,6 +174,7 @@ LIBS += \
-l boost_filesystem$(BOOST_LIB_SUFFIX) \
-l boost_program_options$(BOOST_LIB_SUFFIX) \
-l boost_thread$(BOOST_LIB_SUFFIX) \
-l boost_locale$(BOOST_LIB_SUFFIX) \
-l db_cxx$(BDB_LIB_SUFFIX) \
-L$(NDK_BASE)/sources/cxx-stl/gnu-libstdc++/4.6/libs/armeabi/ -lgnustl_static
#-l ssl_static -l crypto_static

View File

@ -30,6 +30,7 @@ LIBS= \
-l boost_program_options-mt-s \
-l boost_thread_win32-mt-s \
-l boost_chrono-mt-s \
-l boost_locale-mt-s \
-l db_cxx \
-l ssl \
-l crypto

View File

@ -39,6 +39,7 @@ LIBS= \
-l boost_program_options$(BOOST_SUFFIX) \
-l boost_thread$(BOOST_SUFFIX) \
-l boost_chrono$(BOOST_SUFFIX) \
-l boost_locale$(BOOST_SUFFIX) \
-l db_cxx \
-l ssl \
-l crypto

View File

@ -37,6 +37,7 @@ LIBS += \
-l boost_filesystem$(BOOST_LIB_SUFFIX) \
-l boost_program_options$(BOOST_LIB_SUFFIX) \
-l boost_thread$(BOOST_LIB_SUFFIX) \
-l boost_locale$(BOOST_LIB_SUFFIX) \
-l db_cxx$(BDB_LIB_SUFFIX) \
-l ssl \
-l crypto

View File

@ -50,6 +50,7 @@ LIBS += \
-lboost_program_options-mt \
-lboost_thread-mt \
-lboost_chrono-mt \
-lboost_locale-mt \
-lssl \
-lcrypto \
-lz

View File

@ -38,6 +38,7 @@ LIBS += \
-l boost_filesystem$(BOOST_LIB_SUFFIX) \
-l boost_program_options$(BOOST_LIB_SUFFIX) \
-l boost_thread$(BOOST_LIB_SUFFIX) \
-l boost_locale$(BOOST_LIB_SUFFIX) \
-l db_cxx$(BDB_LIB_SUFFIX) \
-l ssl \
-l crypto \

View File

@ -13,6 +13,7 @@ using namespace json_spirit;
using namespace std;
#include <boost/filesystem.hpp>
#include <boost/locale.hpp>
#include <boost/algorithm/string.hpp>
#include <boost/lexical_cast.hpp>
@ -1226,7 +1227,7 @@ void updateSeenHashtags(std::string &message, int64_t msgTime)
BOOST_FOREACH(string const& token, tokens) {
if( token.length() >= 2 ) {
string word = token.substr(1);
boost::algorithm::to_lower(word);
word = boost::locale::to_lower(word);
if( token.at(0) == '#') {
hashtags.insert(word);
}
@ -1489,7 +1490,7 @@ Value newpostmsg(const Array& params, bool fHelp)
BOOST_FOREACH(string const& token, tokens) {
if( token.length() >= 2 ) {
string word = token.substr(1);
boost::algorithm::to_lower(word);
word = boost::locale::to_lower(word);
if( token.at(0) == '#') {
ses->dht_putData(word, "hashtag", true,
v, strUsername, GetAdjustedTime(), 0);

View File

@ -453,7 +453,7 @@ LIBS += $$join(BOOST_LIB_PATH,,-L,) $$join(BDB_LIB_PATH,,-L,) $$join(OPENSSL_LIB
LIBS += -lssl -lcrypto -ldb_cxx$$BDB_LIB_SUFFIX
# -lgdi32 has to happen after -lcrypto (see #681)
win32:LIBS += -lws2_32 -lshlwapi -lmswsock -lole32 -loleaut32 -luuid -lgdi32
LIBS += -lboost_system$$BOOST_LIB_SUFFIX -lboost_filesystem$$BOOST_LIB_SUFFIX -lboost_program_options$$BOOST_LIB_SUFFIX -lboost_thread$$BOOST_THREAD_LIB_SUFFIX
LIBS += -lboost_system$$BOOST_LIB_SUFFIX -lboost_filesystem$$BOOST_LIB_SUFFIX -lboost_program_options$$BOOST_LIB_SUFFIX -lboost_thread$$BOOST_THREAD_LIB_SUFFIX -lboost_locale$$BOOST_THREAD_LIB_SUFFIX
win32:LIBS += -lboost_chrono$$BOOST_LIB_SUFFIX
macx:LIBS += -lboost_chrono$$BOOST_LIB_SUFFIX