This is not Darwin-specific, and can cause issues on other OSes and
architectures, too.
export PATH="${PREFIX}/bin:${PATH}"
+GCCFLAGS=
+GDBFLAGS=
+BINUTILFLAGS=
+
case "$(uname)" in
Linux)
echo "Found Linux OS."
- GCCFLAGS=
- GDBFLAGS=
- BINUTILFLAGS=
;;
Darwin)
echo "Found Darwin OS."
GCCFLAGS="--with-gmp=${DARWIN_OPT_PATH} \
--with-mpfr=${DARWIN_OPT_PATH} \
-with-libiconv-prefix=${DARWIN_OPT_PATH}"
- GDBFLAGS="--disable-werror"
- BINUTILFLAGS="--disable-werror"
;;
*)
echo "Found unknown OS. Aborting!"
--with-gnu-as \
--with-gnu-ld \
--disable-nls \
+ --disable-werror \
${BINUTILFLAGS} || exit
echo "******************************************************************"
echo "* Building ${BINUTILS}"
--prefix=${PREFIX} \
--enable-interwork \
--enable-multilib \
+ --disable-werror \
${GDBFLAGS} || exit
echo "******************************************************************"
echo "* Building ${GDB}"