[API break] Move all the tools in the tools directory instead of common.

The `common` name is from the time where kiwix was only one repository
for all the project (android, desktop, server...).

Now we have split the repositories and kiwix-lib is the "common" repo,
the "common" directory is somehow nonsense.
This commit is contained in:
Matthieu Gautier 2018-11-28 14:15:49 +01:00
parent ecb2a80baf
commit af7689e3e8
26 changed files with 42 additions and 43 deletions

View File

@ -24,7 +24,6 @@
#include <zim/article.h> #include <zim/article.h>
#include <exception> #include <exception>
#include <string> #include <string>
#include "common.h"
using namespace std; using namespace std;

View File

@ -15,12 +15,12 @@ headers = [
install_headers(headers, subdir:'kiwix') install_headers(headers, subdir:'kiwix')
install_headers( install_headers(
'common/base64.h', 'tools/base64.h',
'common/networkTools.h', 'tools/networkTools.h',
'common/otherTools.h', 'tools/otherTools.h',
'common/pathTools.h', 'tools/pathTools.h',
'common/regexTools.h', 'tools/regexTools.h',
'common/stringTools.h', 'tools/stringTools.h',
subdir:'kiwix/common' subdir:'kiwix/tools'
) )

View File

@ -26,9 +26,9 @@
#include <pugixml.hpp> #include <pugixml.hpp>
#include "common/base64.h" #include "tools/base64.h"
#include "common/pathTools.h" #include "tools/pathTools.h"
#include "common/regexTools.h" #include "tools/regexTools.h"
#include "library.h" #include "library.h"
#include "reader.h" #include "reader.h"

View File

@ -31,8 +31,8 @@
#include <string> #include <string>
#include "common.h" #include "common.h"
#include "entry.h" #include "entry.h"
#include "common/pathTools.h" #include "tools/pathTools.h"
#include "common/stringTools.h" #include "tools/stringTools.h"
using namespace std; using namespace std;

View File

@ -29,8 +29,8 @@
#include <string> #include <string>
#include <vector> #include <vector>
#include <vector> #include <vector>
#include "common/pathTools.h" #include "tools/pathTools.h"
#include "common/stringTools.h" #include "tools/stringTools.h"
#include "kiwix_config.h" #include "kiwix_config.h"
using namespace std; using namespace std;

View File

@ -24,7 +24,7 @@
#include <android/log.h> #include <android/log.h>
#include "org_kiwix_kiwixlib_JNIKiwixReader.h" #include "org_kiwix_kiwixlib_JNIKiwixReader.h"
#include "common/base64.h" #include "tools/base64.h"
#include "reader.h" #include "reader.h"
#include "utils.h" #include "utils.h"

View File

@ -5,8 +5,8 @@
#include <sstream> #include <sstream>
#include <thread> #include <thread>
#include <chrono> #include <chrono>
#include <common/otherTools.h> #include <tools/otherTools.h>
#include <common/pathTools.h> #include <tools/pathTools.h>
#include <downloader.h> // For AriaError #include <downloader.h> // For AriaError
#ifdef _WIN32 #ifdef _WIN32

View File

@ -20,9 +20,9 @@
#include "book.h" #include "book.h"
#include "reader.h" #include "reader.h"
#include "common/base64.h" #include "tools/base64.h"
#include "common/regexTools.h" #include "tools/regexTools.h"
#include "common/networkTools.h" #include "tools/networkTools.h"
#include <pugixml.hpp> #include <pugixml.hpp>

View File

@ -18,7 +18,7 @@
*/ */
#include "downloader.h" #include "downloader.h"
#include "common/pathTools.h" #include "tools/pathTools.h"
#include <algorithm> #include <algorithm>
#include <thread> #include <thread>
@ -28,7 +28,7 @@
#include "aria2.h" #include "aria2.h"
#include "xmlrpc.h" #include "xmlrpc.h"
#include "common/otherTools.h" #include "tools/otherTools.h"
#include <pugixml.hpp> #include <pugixml.hpp>
namespace kiwix namespace kiwix

View File

@ -21,9 +21,9 @@
#include "book.h" #include "book.h"
#include "libxml_dumper.h" #include "libxml_dumper.h"
#include "common/base64.h" #include "tools/base64.h"
#include "common/regexTools.h" #include "tools/regexTools.h"
#include "common/pathTools.h" #include "tools/pathTools.h"
#include <pugixml.hpp> #include <pugixml.hpp>
#include <algorithm> #include <algorithm>

View File

@ -20,9 +20,9 @@
#include "libxml_dumper.h" #include "libxml_dumper.h"
#include "book.h" #include "book.h"
#include <common/base64.h> #include <tools/base64.h>
#include <common/stringTools.h> #include <tools/stringTools.h>
#include <common/otherTools.h> #include <tools/otherTools.h>
namespace kiwix namespace kiwix
{ {

View File

@ -11,12 +11,12 @@ kiwix_sources = [
'searcher.cpp', 'searcher.cpp',
'subprocess.cpp', 'subprocess.cpp',
'aria2.cpp', 'aria2.cpp',
'common/base64.cpp', 'tools/base64.cpp',
'common/pathTools.cpp', 'tools/pathTools.cpp',
'common/regexTools.cpp', 'tools/regexTools.cpp',
'common/stringTools.cpp', 'tools/stringTools.cpp',
'common/networkTools.cpp', 'tools/networkTools.cpp',
'common/otherTools.cpp', 'tools/otherTools.cpp',
] ]
kiwix_sources += lib_resources kiwix_sources += lib_resources

View File

@ -20,7 +20,7 @@
#include "opds_dumper.h" #include "opds_dumper.h"
#include "book.h" #include "book.h"
#include <common/otherTools.h> #include <tools/otherTools.h>
namespace kiwix namespace kiwix
{ {

View File

@ -24,7 +24,7 @@
René Nyffenegger rene.nyffenegger@adp-gmbh.ch René Nyffenegger rene.nyffenegger@adp-gmbh.ch
*/ */
#include <common/base64.h> #include <tools/base64.h>
#include <iostream> #include <iostream>
static const std::string base64_chars = static const std::string base64_chars =

View File

@ -17,7 +17,7 @@
* MA 02110-1301, USA. * MA 02110-1301, USA.
*/ */
#include <common/networkTools.h> #include <tools/networkTools.h>
#ifdef _WIN32 #ifdef _WIN32
#include <winsock2.h> #include <winsock2.h>

View File

@ -17,7 +17,7 @@
* MA 02110-1301, USA. * MA 02110-1301, USA.
*/ */
#include <common/otherTools.h> #include <tools/otherTools.h>
#include <map> #include <map>
static std::map<std::string, std::string> codeisomapping { static std::map<std::string, std::string> codeisomapping {

View File

@ -17,7 +17,7 @@
* MA 02110-1301, USA. * MA 02110-1301, USA.
*/ */
#include <common/pathTools.h> #include <tools/pathTools.h>
#ifdef __APPLE__ #ifdef __APPLE__
#include <limits.h> #include <limits.h>

View File

@ -17,7 +17,7 @@
* MA 02110-1301, USA. * MA 02110-1301, USA.
*/ */
#include <common/regexTools.h> #include <tools/regexTools.h>
std::map<std::string, icu::RegexMatcher*> regexCache; std::map<std::string, icu::RegexMatcher*> regexCache;

View File

@ -17,7 +17,7 @@
* MA 02110-1301, USA. * MA 02110-1301, USA.
*/ */
#include <common/stringTools.h> #include <tools/stringTools.h>
#include <unicode/normlzr.h> #include <unicode/normlzr.h>
#include <unicode/rep.h> #include <unicode/rep.h>

View File

@ -3,7 +3,7 @@
#ifndef KIWIX_XMLRPC_H_ #ifndef KIWIX_XMLRPC_H_
#define KIWIX_XMLRPC_H_ #define KIWIX_XMLRPC_H_
#include <common/otherTools.h> #include <tools/otherTools.h>
namespace kiwix { namespace kiwix {