Skip to content

Commit

Permalink
Fix native WebAssembly emscripten build
Browse files Browse the repository at this point in the history
__EMSCRIPTEN__ is defined by the emscripten toolchain whichever
compiler it uses internall.  __asmjs__ and __wasm__ are defined in
the two different compiler frontends that emscripten can use.
  • Loading branch information
sbc100 committed Mar 20, 2018
1 parent d541fda commit 2dd8e02
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/time_zone_libc.cc
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,8 @@ OffsetAbbr get_offset_abbr(const std::tm& tm) {
const char* abbr = tzname[is_dst];
return {off, abbr};
}
#elif defined(__native_client__) || defined(__myriad2__) || defined(__asmjs__)
#elif defined(__native_client__) || defined(__myriad2__) || \
defined(__EMSCRIPTEN__)
// Uses the globals: 'timezone' and 'tzname'.
OffsetAbbr get_offset_abbr(const std::tm& tm) {
const bool is_dst = tm.tm_isdst > 0;
Expand Down

0 comments on commit 2dd8e02

Please sign in to comment.