Skip to content

Commit 0ab9dd7

Browse files
committed
Fix Linux build
1 parent 1ed69f0 commit 0ab9dd7

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

icuSources/i18n/dtptngen.cpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2113,6 +2113,7 @@ DateTimePatternGenerator::localeUsesLongDayPeriods(const Locale& locale) {
21132113
// is enabled or we're running the tests. BUT: We previously enabled long day period names in Traditional Chinese,
21142114
// with rdar://106179361, with a different implementation. So for zh_Hant, this function always returns true,
21152115
// and for all other languages we check this flag.
2116+
#if U_PLATFORM_IS_DARWIN_BASED
21162117
const char *progname = getprogname();
21172118
bool featureEnabled = os_feature_enabled(ICU, longDayPeriodNames);
21182119
if (uprv_strcmp(progname, "cintltst") == 0 || uprv_strcmp(progname, "intltest") == 0 || uprv_strcmp(progname, "xctest") == 0) {
@@ -2152,6 +2153,7 @@ DateTimePatternGenerator::localeUsesLongDayPeriods(const Locale& locale) {
21522153
}
21532154
}
21542155
}
2156+
#endif
21552157
return false;
21562158
}
21572159
#endif // APPLE_ICU_CHANGES

0 commit comments

Comments
 (0)