diff --git a/include/eepp/ui/css/propertyspecification.hpp b/include/eepp/ui/css/propertyspecification.hpp index 7e4e09097..8169b6b2c 100644 --- a/include/eepp/ui/css/propertyspecification.hpp +++ b/include/eepp/ui/css/propertyspecification.hpp @@ -33,8 +33,15 @@ class EE_API PropertySpecification { protected: friend class PropertyDefinition; + +// Investigate why robin_hood::unordered_flat_map fails with wasm build! +#if EE_PLATFORM == EE_PLATFORM_EMSCRIPTEN + std::unordered_map> mProperties; + std::unordered_map> mShorthands; +#else UnorderedMap> mProperties; UnorderedMap> mShorthands; +#endif const PropertyDefinition* addPropertyAlias( Uint32 aliasId, const PropertyDefinition* propDef ); }; diff --git a/src/eepp/core/string.cpp b/src/eepp/core/string.cpp index 537273e61..c43393c56 100644 --- a/src/eepp/core/string.cpp +++ b/src/eepp/core/string.cpp @@ -14,7 +14,8 @@ #include #include -#if __GNUC__ >= 11 || ( __clang__ && __clang_major__ >= 12 ) +#if ( __GNUC__ >= 11 || ( __clang__ && __clang_major__ >= 12 ) ) && \ + EE_PLATFORM != EE_PLATFORM_EMSCRIPTEN #define STD_SUPPORTS_FIXED_TO_CHARS #endif diff --git a/src/eepp/graphics/textureatlasloader.cpp b/src/eepp/graphics/textureatlasloader.cpp index 4fecbbdf3..4db841552 100644 --- a/src/eepp/graphics/textureatlasloader.cpp +++ b/src/eepp/graphics/textureatlasloader.cpp @@ -366,8 +366,7 @@ bool TextureAtlasLoader::updateTextureAtlas() { fs.write( reinterpret_cast( tTexHdr ), sizeof( sTextureHdr ) ); fs.write( reinterpret_cast( &tTexAtlas->TextureRegions[0] ), - sizeof( sTextureRegionHdr ) * - (std::streamsize)tTexAtlas->TextureRegions.size() ); + sizeof( sTextureRegionHdr ) * (std::size_t)tTexAtlas->TextureRegions.size() ); } return true; diff --git a/src/eepp/graphics/texturepacker.cpp b/src/eepp/graphics/texturepacker.cpp index 6817b5b7b..546d6a49e 100644 --- a/src/eepp/graphics/texturepacker.cpp +++ b/src/eepp/graphics/texturepacker.cpp @@ -727,7 +727,7 @@ void TexturePacker::saveTextureRegions() { if ( tTextureRegionsHdr.size() ) fs.write( reinterpret_cast( &tTextureRegionsHdr[0] ), - sizeof( sTextureRegionHdr ) * (std::streamsize)tTextureRegionsHdr.size() ); + sizeof( sTextureRegionHdr ) * tTextureRegionsHdr.size() ); } } diff --git a/src/tools/ecode/version.cpp b/src/tools/ecode/version.cpp index 65b8222f5..d2d8ecaf6 100644 --- a/src/tools/ecode/version.cpp +++ b/src/tools/ecode/version.cpp @@ -1,4 +1,5 @@ #include "version.hpp" +#include #include namespace ecode { @@ -13,12 +14,12 @@ Uint64 Version::getVersionNum() { Version ver = getVersion(); return ECODE_VERSIONNUM( ver.major, ver.minor, ver.patch, ver.commit ); } - std::string Version::getVersionNumString() { Version ver = getVersion(); if ( ver.commit > 0 && ver.commit < 9999 ) - return String::format( "%d.%d.%d-%d", ver.major, ver.minor, ver.patch, ver.commit ); - return String::format( "%d.%d.%d", ver.major, ver.minor, ver.patch ); + return String::format( "%" PRIu64 ".%" PRIu64 ".%" PRIu64 "-%" PRIu64, ver.major, ver.minor, + ver.patch, ver.commit ); + return String::format( "%" PRIu64 ".%" PRIu64 ".%" PRIu64, ver.major, ver.minor, ver.patch ); } std::string Version::getVersionFullName() {