Skip to content

Commit 8c3000a

Browse files
macOS: Disable locale support when building on macOS
Remove locale support on macOS. uClibc runs an application on a host to generate local files, but that application fails to build on macOS, therefore locale support has to be disabled on macOS hosts. Signed-off-by: Anton Kolesov <[email protected]>
1 parent cfc08ee commit 8c3000a

File tree

2 files changed

+14
-0
lines changed

2 files changed

+14
-0
lines changed

README.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -104,6 +104,13 @@ To build PDF documentation for toolchain TeX must be installed:
104104
If PDF documentation is not needed, pass option `--no-pdf` to build-all.sh to
105105
disable its build, then mactex is not required.
106106

107+
> NB! Linux/uClibc toolchain built on macOS has different uClibc configuration
108+
> then the one built on Linux hosts - **local support is disabled**. The reason
109+
> is that when locale support is enabled, uClibc makefiles will build an
110+
> application called `genlocale` that will run on host system, but on macOS
111+
> this application fails to build, therefore support for locales is disabled
112+
> when Linux/uClibc toolchain is built on macOS.
113+
107114

108115
Getting sources
109116
---------------

build-uclibc.sh

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -450,6 +450,13 @@ else
450450
-i $uc_dot_config
451451
fi
452452

453+
# Remove locale support on macOS. uClibc runs an application on a host to
454+
# generate local files, but that application fails to build on macOS, therefore
455+
# locale support has to be disabled on macOS hosts.
456+
if [ "$IS_MAC_OS" = yes ]; then
457+
kconfig_disable_option $uc_dot_config UCLIBC_HAS_LOCALE
458+
fi
459+
453460
# Disable HARDWIRED_ABSPATH to avoid absolute path references to allow
454461
# relocatable toolchains.
455462
echo "HARDWIRED_ABSPATH=n" >> $uc_dot_config

0 commit comments

Comments
 (0)