Skip to content

Commit

Permalink
fix for windows
Browse files Browse the repository at this point in the history
  • Loading branch information
zhixiong-tang committed Nov 16, 2023
1 parent 6800b51 commit 86fd7af
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 2 deletions.
5 changes: 5 additions & 0 deletions src/geobuf/geobuf.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,11 @@
#include <sstream>

#include "spdlog/spdlog.h"
// fix exposed macro 'GetObject' from wingdi.h (included by spdlog.h) under
// windows, see https://github.com/Tencent/rapidjson/issues/1448
#ifdef GetObject
#undef GetObject
#endif

#include <cmath>
#include <protozero/pbf_builder.hpp>
Expand Down
8 changes: 6 additions & 2 deletions src/geobuf/geobuf_index.hpp
Original file line number Diff line number Diff line change
@@ -1,7 +1,13 @@
#pragma once
#include "geobuf.hpp"
#include "planet.hpp"

#include <spdlog/spdlog.h>
// fix exposed macro 'GetObject' from wingdi.h (included by spdlog.h) under
// windows, see https://github.com/Tencent/rapidjson/issues/1448
#ifdef GetObject
#undef GetObject
#endif

#include <fcntl.h>
#include <mio/mio.hpp>
Expand All @@ -11,8 +17,6 @@
#include <iomanip>
#include <sstream>

#include "spdlog/spdlog.h"

namespace cubao
{
inline std::string to_hex(const std::string &s, bool upper_case = true)
Expand Down

0 comments on commit 86fd7af

Please sign in to comment.