mirror of
https://github.com/fmtlib/fmt.git
synced 2024-11-02 11:28:20 +00:00
Fix FreeBSD 12
FreeBSD 12 changed the type of freelocale to the type defined by POSIX. Check the FreeBSD version when building for FreeBSD.
This commit is contained in:
parent
a4e4f74530
commit
edbbf7ce6c
@ -476,7 +476,7 @@ LocaleType newlocale(int category_mask, const char *locale, LocaleType base) {
|
||||
return LocaleMock::instance->newlocale(category_mask, locale, base);
|
||||
}
|
||||
|
||||
#if defined(__APPLE__) || defined(__FreeBSD__)
|
||||
#if defined(__APPLE__) || (defined(__FreeBSD__) && __FreeBSD_version < 1200002)
|
||||
typedef int FreeLocaleResult;
|
||||
#else
|
||||
typedef void FreeLocaleResult;
|
||||
|
@ -14,6 +14,7 @@
|
||||
#ifdef _WIN32
|
||||
# include <windows.h>
|
||||
#else
|
||||
# include <sys/param.h> // for FreeBSD version
|
||||
# include <sys/types.h> // for ssize_t
|
||||
#endif
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user