Building ICU-63.1 on Cygwin fails with the following error:
icu/source/i18n/unicode/numberrangeformatter.h:189:33: error: explicit instantiation of ‘struct std::atomic<icu_63::number::impl::NumberRangeFormatterImpl*>’ in namespace ‘icu_63::number’ (which does not enclose namespace ‘std’) [-fpermissive]
template struct U_I18N_API std::atomic<impl::NumberRangeFormatterImpl*>;
This problem started with the following commit:
Author: Jeff Genovy <email@example.com>
Date: Fri Oct 5 10:44:52 2018 -0700
Fix MSVC/clang compiler warning C4251, export explicit template, required for building DLLs on Windows. Also fix a few other warnings as well.
My C++ knowledge isn't good enough to understand what this is all about, but there's an obvious fix, for which I'll submit a PR.
I think this should likely be listed as a "known issue" on the ICU v63 download page, and then we can merge the fix into the maint-63 branch once the fix is in master. (I will wait until the ICU-TC discussion tomorrow first though.)
See also ICU-20209.
The current Firefox patches at https://bugzilla.mozilla.org/show_bug.cgi?id=1499026 disable the explicit instantiation for MinGW, too. So maybe it's possible to change the overall condition to U_PF_WINDOWS == U_PLATFORM?
Thank you for the report stweil
Note: There is some related discussion on the other issue/ticket that is similar to your patch.