diff --git a/app/vector3edit.cpp b/app/vector3edit.cpp index c049bb3..416efe1 100644 --- a/app/vector3edit.cpp +++ b/app/vector3edit.cpp @@ -1,5 +1,6 @@ #include "vector3edit.h" +#include #include #include diff --git a/lib/common.h b/lib/common.h index b3b5fdd..aa87d0d 100644 --- a/lib/common.h +++ b/lib/common.h @@ -7,7 +7,11 @@ #define LIBWEAVER_PACK( __Declaration__ ) __pragma( pack(push, 1) ) __Declaration__ __pragma( pack(pop)) #endif +#ifdef _MSC_VER #define LIBWEAVER_EXPORT __declspec(dllexport) +#else +#define LIBWEAVER_EXPORT +#endif #if defined(_WIN32) #define LIBWEAVER_OS_WINDOWS diff --git a/lib/core.cpp b/lib/core.cpp index 98ceabd..14cf2d0 100644 --- a/lib/core.cpp +++ b/lib/core.cpp @@ -1,5 +1,7 @@ #include "core.h" +#include + namespace si { Core::Core() diff --git a/lib/core.h b/lib/core.h index e48d894..de11c41 100644 --- a/lib/core.h +++ b/lib/core.h @@ -4,6 +4,7 @@ #include #include "common.h" +#include "types.h" namespace si { diff --git a/lib/interleaf.cpp b/lib/interleaf.cpp index f3e1305..b3cfffb 100644 --- a/lib/interleaf.cpp +++ b/lib/interleaf.cpp @@ -74,11 +74,11 @@ bool Interleaf::ParseStream(Chunk *chunk) Chunk *list = static_cast(chunk->GetChildAt(1)); if (list) { - using ChunkMap = std::map >; + typedef std::map ChunkMap; ChunkMap data; - for (Core *chunk : list->GetChildren()) { - Chunk *mxch = static_cast(chunk); + for (Children::const_iterator it=list->GetChildren().begin(); it!=list->GetChildren().end(); it++) { + Chunk *mxch = static_cast(*it); if (mxch->id() == Chunk::TYPE_pad_) { // Ignore this chunk } else if (mxch->id() == Chunk::TYPE_MxCh) { diff --git a/lib/object.h b/lib/object.h index 1bd60e2..6f0fe62 100644 --- a/lib/object.h +++ b/lib/object.h @@ -10,7 +10,7 @@ namespace si { class Object : public Core { public: - using ChunkedData = std::vector; + typedef std::vector ChunkedData; Object(); diff --git a/lib/types.h b/lib/types.h index db84c2c..dbb2d5e 100644 --- a/lib/types.h +++ b/lib/types.h @@ -1,6 +1,7 @@ #ifndef TYPES_H #define TYPES_H +#include #include #include #include @@ -24,7 +25,7 @@ namespace si { class bytearray : public std::vector { public: - bytearray() = default; + bytearray(){} template T *cast() { return reinterpret_cast(data()); } @@ -138,7 +139,7 @@ private: }; -using DataMap = std::map; +typedef std::map DataMap; }