Commit b1047154 by Maarten L. Hekkelman

missing include, export symbols on Windows

parent c361af37
...@@ -106,7 +106,7 @@ namespace cif ...@@ -106,7 +106,7 @@ namespace cif
{ {
// flag for verbose output // flag for verbose output
extern int VERBOSE; extern CIFPP_DLL_IMPORT(int) VERBOSE;
// mmCIF mapping // mmCIF mapping
// A CIF data file in this case contains entries (data blocks) which can contain // A CIF data file in this case contains entries (data blocks) which can contain
......
...@@ -39,11 +39,22 @@ ...@@ -39,11 +39,22 @@
#endif #endif
#if _MSC_VER #if _MSC_VER
constexpr inline bool isatty(int) { return false; } #include <io.h>
#define isatty _isatty
#else #else
#include <unistd.h> #include <unistd.h>
#endif #endif
#ifdef _MSC_VER
#ifdef CIFPP_BUILD_DLL
#define CIFPP_DLL_IMPORT(type) __declspec(dllexport) type
#else
#define CIFPP_DLL_IMPORT(type) __declspec(dllimport) type
#endif
#else
#define CIFPP_DLL_IMPORT(type) type
#endif
namespace cif namespace cif
{ {
......
...@@ -30,6 +30,8 @@ ...@@ -30,6 +30,8 @@
#include <cstdint> #include <cstdint>
#include <array> #include <array>
#include "CifUtils.hpp"
namespace mmcif namespace mmcif
{ {
...@@ -43,8 +45,8 @@ struct Spacegroup ...@@ -43,8 +45,8 @@ struct Spacegroup
int nr; int nr;
}; };
extern const Spacegroup kSpaceGroups[]; extern CIFPP_DLL_IMPORT(const Spacegroup) kSpaceGroups[];
extern const std::size_t kNrOfSpaceGroups; extern CIFPP_DLL_IMPORT(const std::size_t) kNrOfSpaceGroups;
// -------------------------------------------------------------------- // --------------------------------------------------------------------
...@@ -105,8 +107,8 @@ struct SymopDataBlock ...@@ -105,8 +107,8 @@ struct SymopDataBlock
static_assert(sizeof(SymopDataBlock) == sizeof(uint64_t), "Size of SymopData is wrong"); static_assert(sizeof(SymopDataBlock) == sizeof(uint64_t), "Size of SymopData is wrong");
extern const SymopDataBlock kSymopNrTable[]; extern CIFPP_DLL_IMPORT(const SymopDataBlock) kSymopNrTable[];
extern const std::size_t kSymopNrTableSize; extern CIFPP_DLL_IMPORT(const std::size_t) kSymopNrTableSize;
// -------------------------------------------------------------------- // --------------------------------------------------------------------
......
...@@ -39,6 +39,7 @@ ...@@ -39,6 +39,7 @@
#include <map> #include <map>
#include <mutex> #include <mutex>
#include <regex> #include <regex>
#include <sstream>
#include <thread> #include <thread>
#include <tuple> #include <tuple>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment