#!/bin/sh

export CROSS_COMPILE=/opt/hardhat/devkit/ppc/8xx/bin/ppc_8xx
export CC=$CROSS_COMPILE-gcc
export CXX=$CROSS_COMPILE-g++
export AS=$CROSS_COMPILE-as
export LD=$CROSS_COMPILE-ld
export CPP="$CC -E"
export AR=$CROSS_COMPILE-ar
export NM=$CROSS_COMPILE-nm
export STRIP="$CROSS_COMPILE-strip --remove-section=.note --remove-section=.comment"
export RANLIB=$CROSS_COMPILE-ranlib

echo 'ac_cv_func_setpgrp_void=yes' > config.cache

./configure --host=powerpc-hardhat-linux --prefix=/usr/ \
                --build=i386 ac_cv_func_setpgrp_void=yes

make

make DESTDIR=$(pwd)/target install

