Fix wrong rapidjson include on Appveyor

This commit is contained in:
Gioacchino Mazzurco 2019-11-28 01:33:17 +01:00
parent 516b5e7a83
commit 3bb42ca799
No known key found for this signature in database
GPG Key ID: A1FBCA3872E87051
5 changed files with 7 additions and 25 deletions

View File

@ -90,7 +90,7 @@ install:
# Configuring MSys2
- set PATH=C:\msys64\usr\bin;%PATH%
- set PATH=C:\msys64\mingw32\bin;%PATH%
- pacman --noconfirm -S mingw-w64-i686-qt5 mingw-w64-i686-miniupnpc mingw-w64-i686-sqlcipher mingw-w64-i686-libmicrohttpd mingw-w64-i686-xapian-core mingw-w64-i686-cmark
- pacman --noconfirm -S mingw-w64-i686-qt5 mingw-w64-i686-miniupnpc mingw-w64-i686-rapidjson mingw-w64-i686-sqlcipher mingw-w64-i686-xapian-core mingw-w64-i686-cmark
#- pacman --noconfirm -S mingw-w64-i686-qt5-static mingw-w64-i686-miniupnpc mingw-w64-i686-sqlcipher mingw-w64-i686-libmicrohttpd
#- set PATH=C:\msys64\mingw32\qt5-static\bin\;%PATH%

View File

@ -32,12 +32,7 @@
#include <iomanip>
#include <string>
#include <typeinfo> // for typeid
#ifdef HAS_RAPIDJSON
#include <rapidjson/prettywriter.h>
#else
#include <rapid_json/prettywriter.h>
#endif // HAS_RAPIDJSON
static constexpr uint32_t MAX_SERIALIZED_CHUNK_SIZE = 10*1024*1024 ; // 10 MB.

View File

@ -38,11 +38,10 @@ bitdht {
# always possible to find them
RAPIDJSON_AVAILABLE = $$system(pkg-config --atleast-version 1.1 RapidJSON && echo yes)
isEmpty(RAPIDJSON_AVAILABLE) {
message("using built-in rapidjson")
message("using rapidjson from submodule")
INCLUDEPATH *= $$clean_path($${PWD}/../../supportlibs/rapidjson/include)
} else {
message("using system rapidjson")
DEFINES *= HAS_RAPIDJSON
}

View File

@ -19,19 +19,12 @@
* *
*******************************************************************************/
#include <rapidjson/writer.h>
#include <rapidjson/stringbuffer.h>
#include <rapidjson/prettywriter.h>
#include "util/rsjson.h"
#ifdef HAS_RAPIDJSON
# include <rapidjson/writer.h>
# include <rapidjson/stringbuffer.h>
# include <rapidjson/prettywriter.h>
#else
# include <rapid_json/writer.h>
# include <rapid_json/stringbuffer.h>
# include <rapid_json/prettywriter.h>
#endif // HAS_RAPIDJSON
inline int getJsonManipulatorStatePosition()
{
static int p = std::ios_base::xalloc();

View File

@ -21,12 +21,7 @@
#pragma once
#include <iostream>
#ifdef HAS_RAPIDJSON
# include <rapidjson/document.h>
#else
# include <rapid_json/document.h>
#endif // HAS_RAPIDJSON
#include <rapidjson/document.h>
/**
* Use this type for JSON documents representations in RetroShare code