mirror of
https://git.hardenedbsd.org/hardenedbsd/HardenedBSD.git
synced 2024-11-11 04:42:16 +01:00
sort: Only build FreeBSD-specific ALTMON_x stuff when ATLMON_1 is defined
On MacOS, we bootstrap sort. Since ALTMON_* are not defined there, the
build blows up. Since we don't need this feature for the FreeBSD build
process, and since we won't use it unless we actually install the NL
files that have this data in it, just #ifdef it out for now. In the
extremely unlikely event that the FreeBSD bootstrap/build process grows
this dependency, we can evaluate the best solution then (which most
likely is going to be not depend on the local's month names).
Fixes: 3d44dce90a
(MacOS builds and github CI)
Sponsored by: Netflix
Reviewed by: jrtc27, jlduran@gmail.com, markj
Differential Revision: https://reviews.freebsd.org/D42868
This commit is contained in:
parent
3e7e3b5bdf
commit
bd234c0d4c
@ -113,9 +113,11 @@ initialise_months(void)
|
||||
const nl_item ab_item[12] = { ABMON_1, ABMON_2, ABMON_3, ABMON_4,
|
||||
ABMON_5, ABMON_6, ABMON_7, ABMON_8, ABMON_9, ABMON_10,
|
||||
ABMON_11, ABMON_12 };
|
||||
#ifdef ALTMON_1
|
||||
const nl_item alt_item[12] = { ALTMON_1, ALTMON_2, ALTMON_3, ALTMON_4,
|
||||
ALTMON_5, ALTMON_6, ALTMON_7, ALTMON_8, ALTMON_9, ALTMON_10,
|
||||
ALTMON_11, ALTMON_12 };
|
||||
#endif
|
||||
int i;
|
||||
|
||||
/*
|
||||
@ -132,9 +134,13 @@ initialise_months(void)
|
||||
if (!populate_cmonth(&cmonths[i].ab,
|
||||
ab_item[i], i))
|
||||
continue;
|
||||
#ifdef ALTMON_1
|
||||
if (!populate_cmonth(&cmonths[i].alt,
|
||||
alt_item[i], i))
|
||||
continue;
|
||||
#else
|
||||
cmonths[i].alt = NULL;
|
||||
#endif
|
||||
}
|
||||
}
|
||||
|
||||
@ -148,9 +154,13 @@ initialise_months(void)
|
||||
if (!populate_wmonth(&wmonths[i].ab,
|
||||
ab_item[i], i))
|
||||
continue;
|
||||
#ifdef ALTMON_1
|
||||
if (!populate_wmonth(&wmonths[i].alt,
|
||||
alt_item[i], i))
|
||||
continue;
|
||||
#else
|
||||
wmonths[i].alt = NULL;
|
||||
#endif
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user