Force POSIX locale, as otherwise the build (makeinfo) may break.

* the cause for the spurious makeinfo breakages is that it relies on
  being executed in POSIX locale - spotted by Jonathan Schleifer, thanks!
This commit is contained in:
Oliver Tappe 2012-11-07 20:31:39 +01:00
parent 48a09beb0a
commit ed0528aef0
4 changed files with 14 additions and 11 deletions

View File

@ -12,10 +12,10 @@ compile binutils:
mkdir binutils-obj
cd binutils-obj
CFLAGS="-O2" CXXFLAGS="-O2" ../binutils/configure \
LC_ALL=POSIX CFLAGS="-O2" CXXFLAGS="-O2" ../binutils/configure \
--prefix=/boot/develop/abi/x86/gcc2/tools/gcc-2.95.3-haiku-${GCCDATE} \
--disable-nls --enable-shared=yes
make
LC_ALL=POSIX make
cd ..
@ -23,10 +23,10 @@ compile gcc:
mkdir gcc-obj
cd gcc-obj
CFLAGS="-O2" CXXFLAGS="-O2" ../gcc/configure \
LC_ALL=POSIX CFLAGS="-O2" CXXFLAGS="-O2" ../gcc/configure \
--prefix=/boot/develop/abi/x86/gcc2/tools/gcc-2.95.3-haiku-${GCCDATE} \
--disable-nls --enable-shared=yes --enable-languages=c,c++
make bootstrap
LC_ALL=POSIX make bootstrap
# the above will fail when compiling builtinbuf.cc, but we can ignore that
# since it's trying to build libstdc++.so, which haiku provides anyway
cd ..

View File

@ -13,23 +13,23 @@ compile binutils:
mkdir binutils-obj
cd binutils-obj
CFLAGS="-O2" CXXFLAGS="-O2" ../binutils/configure \
LC_ALL=POSIX CFLAGS="-O2" CXXFLAGS="-O2" ../binutils/configure \
--prefix=/boot/develop/abi/x86/gcc4/tools/${GCCVERSION} \
--disable-nls --enable-shared=yes \
--with-htmldir=html-docs
make -j2
LC_ALL=POSIX make -j2
cd ..
compile gcc:
mkdir gcc-obj
cd gcc-obj
CFLAGS="-O2" CXXFLAGS="-O2" ../gcc/configure \
LC_ALL=POSIX CFLAGS="-O2" CXXFLAGS="-O2" ../gcc/configure \
--prefix=/boot/develop/abi/x86/gcc4/tools/${GCCVERSION} \
--enable-shared --enable-languages=c,c++ \
--disable-nls --without-libiconv-prefix --disable-libstdcxx-pch \
--with-htmldir=html-docs
make -j2 bootstrap
LC_ALL=POSIX make -j2 bootstrap
cd ..
Ok, now everything is compiled and ready, waiting to be installed:

View File

@ -35,6 +35,9 @@ if [ ! -d "$base" ]; then
# From now on fail, if anything goes wrong.
set -o errexit
# forcefeed the POSIX locale, as the build (makeinfo) might choke otherwise
export LC_ALL=POSIX
cd $gcc_base/..
rm -rf binutils-obj

View File

@ -70,8 +70,6 @@ case "$gccDate" in
*) echo "Invalid GCC date string '$gccDate'." >&2; exit 1;;
esac
# get the GCC version
gccVersion=`cat $gccSources/gcc/BASE-VER`
if [ -z "$gccVersion" ]; then
@ -103,11 +101,13 @@ echo
echo "This is going to take a while ..."
sleep 3
# From now on fail, if anything goes wrong.
set -o errexit
# forcefeed the POSIX locale, as the build (makeinfo) might choke otherwise
export LC_ALL=POSIX
# remove and recreate the build directories
rm -rf "$buildDir"
mkdir -p "$binutilsBuildDir" "$gccBuildDir"