PostgreSQL database support

This commit is contained in:
zeuner
2017-01-08 23:24:09 +01:00
committed by sfan5
parent d490cf0a31
commit af502f3ac2
6 changed files with 243 additions and 0 deletions

View File

@ -13,6 +13,9 @@
#include "ZlibDecompressor.h"
#include "util.h"
#include "db-sqlite3.h"
#if USE_POSTGRESQL
#include "db-postgresql.h"
#endif
#if USE_LEVELDB
#include "db-leveldb.h"
#endif
@ -283,6 +286,10 @@ void TileGenerator::openDb(const std::string &input)
if(backend == "sqlite3")
m_db = new DBSQLite3(input);
#if USE_POSTGRESQL
else if(backend == "postgresql")
m_db = new DBPostgreSQL(input);
#endif
#if USE_LEVELDB
else if(backend == "leveldb")
m_db = new DBLevelDB(input);