rendered paste body#!/bin/sh -e
export prefix="/home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486"
export TOASTIX_BASE="/home/michael/git/newstix"
export STRIP="strip"
export STAGING_SIPDIR="/home/michael/git/newstix/tmp/sysroots/x86_64-linux/share/sip"
export localstatedir="/home/michael/git/newstix/tmp/sysroots/x86_64-linux/var"
export PSTAGING_ACTIVE="1"
export libexecdir="/home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/libexec"
export datadir="/home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/share"
export PKG_CONFIG_SYSROOT_DIR="/home/michael/git/newstix/tmp/sysroots/i486-oe-linux"
export BUILD_CXX="g++"
export LD="ld"
export bindir="/home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/bin"
export TARGET_CXXFLAGS="-isystem/home/michael/git/newstix/tmp/sysroots/i486-oe-linux/home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/include -fexpensive-optimizations -frename-registers -fomit-frame-pointer -O2 -fpermissive"
export includedir="/home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/include"
export BUILD_CC="gcc"
export BUILD_LDFLAGS="-L/home/michael/git/newstix/tmp/sysroots/x86_64-linux/lib -Wl,-rpath-link,/home/michael/git/newstix/tmp/sysroots/x86_64-linux/lib -Wl,-rpath,/home/michael/git/newstix/tmp/sysroots/x86_64-linux/lib -Wl,-O1"
export BUILD_LD="ld"
export SDK_CFLAGS="-isystem/home/michael/git/newstix/tmp/sysroots/x86_64-linux/home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/include -isystem/home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/include -fexpensive-optimizations -frename-registers -fomit-frame-pointer -O2"
export oldincludedir="/home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/include"
export LANG="en_US.UTF-8"
export BUILD_CCLD="gcc"
export USER="michael"
export XDG_DATA_DIRS="/home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/share"
export TOASTIX_PLATFORM="soekris-4xxx"
export QMAKE_MKSPEC_PATH="/home/michael/git/newstix/tmp/sysroots/x86_64-linux/share/qmake"
export palmtopdir="/home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/lib/opie"
export SDK_CPPFLAGS="-isystem/home/michael/git/newstix/tmp/sysroots/x86_64-linux/home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/include -isystem/home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/include"
export CC="gcc"
export LOGNAME="michael"
export TARGET_CFLAGS="-isystem/home/michael/git/newstix/tmp/sysroots/i486-oe-linux/home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/include -fexpensive-optimizations -frename-registers -fomit-frame-pointer -O2"
export RANLIB="ranlib"
export CXX="g++"
export BUILD_RANLIB="ranlib"
export COLORTERM="1"
export sbindir="/home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/bin"
export mandir="/home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/share/man"
export OBJCOPY="objcopy"
unset LIBC
export servicedir="/home/michael/git/newstix/tmp/sysroots/x86_64-linux/srv"
export SDK_LDFLAGS="-L/home/michael/git/newstix/tmp/sysroots/x86_64-linux/home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/lib -Wl,-rpath-link,/home/michael/git/newstix/tmp/sysroots/x86_64-linux/home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/lib -Wl,-O1"
export BB_ENV_EXTRAWHITE="TOASTIX_BASE TOASTIX_PLATFORM"
export sysconfdir="/home/michael/git/newstix/tmp/sysroots/x86_64-linux/etc"
export CCLD="gcc"
export base_bindir="/home/michael/git/newstix/tmp/sysroots/x86_64-linux/bin"
export CFLAGS="-isystem/home/michael/git/newstix/tmp/sysroots/x86_64-linux/include -O2 -g"
export HOSTNAME="sles10-64"
export TARGET_LDFLAGS="-L/home/michael/git/newstix/tmp/sysroots/i486-oe-linux/home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/lib -Wl,-rpath-link,/home/michael/git/newstix/tmp/sysroots/i486-oe-linux/home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/lib -Wl,-O1 -Wl,--hash-style=gnu"
export PKG_CONFIG_DISABLE_UNINSTALLED="yes"
export BUILD_F77="g77"
export PWD="/home/michael/git/newstix"
export _="/home/michael/git/newstix/bitbake/bin/bitbake"
export PATCH_GET="0"
export CXXFLAGS="-isystem/home/michael/git/newstix/tmp/sysroots/x86_64-linux/include -O2 -g"
export NM="nm"
export F77="g77"
export SSH_AUTH_SOCK="/tmp/ssh-WJdyrw6510/agent.6510"
export QTDIR="/qt2"
export LDFLAGS="-L/home/michael/git/newstix/tmp/sysroots/x86_64-linux/lib -Wl,-rpath-link,/home/michael/git/newstix/tmp/sysroots/x86_64-linux/lib -Wl,-rpath,/home/michael/git/newstix/tmp/sysroots/x86_64-linux/lib -Wl,-O1"
export MAKE="make"
export CONFIG_SITE="/home/michael/git/newstix/public/site/common-glibc /home/michael/git/newstix/oe/site/endian-little /home/michael/git/newstix/oe/site/common-linux /home/michael/git/newstix/oe/site/common-glibc /home/michael/git/newstix/oe/site/x86_64-linux /home/michael/git/newstix/oe/site/common"
unset TARGET_ARCH
export SHELLCMDS="bash --rcfile $TERMRCFILE"
export BBPATH="/home/michael/git/newstix/private:/home/michael/git/newstix/public:/home/michael/git/newstix/oe:/home/michael/git/newstix/private/recipes:/home/michael/git/newstix/public/recipes:/home/michael/git/newstix/oe/recipes:/home/michael/git/newstix/proj/common/clusterfun:/home/michael/git/newstix/proj/common/cfgswap:/home/michael/git/newstix/proj/common/firehol:/home/michael/git/newstix/proj/common/ledblinker:/home/michael/git/newstix/proj/common/lldplite:/home/michael/git/newstix/proj/common/phonehome:/home/michael/git/newstix/proj/common/periodic:/home/michael/git/newstix/proj/common/pkgtools:/home/michael/git/newstix/proj/common/pki:/home/michael/git/newstix/proj/common/suse-fw:/home/michael/git/newstix/proj/common/threeg:/home/michael/git/newstix/proj/common/tmpl-script:/home/michael/git/newstix/proj/common/libcfg:/home/michael/git/newstix/proj/common/libcommon:/home/michael/git/newstix/proj/common/pinghome:/home/michael/git/newstix/proj/common/mockbrazo:/home/michael/git/newstix/proj/common/softup-client:/home/michael/git/newstix/proj/common/webrazo:/home/michael/git/newstix/proj/common/wireless"
export BUILD_CPP="cpp"
export BUILD_CFLAGS="-isystem/home/michael/git/newstix/tmp/sysroots/x86_64-linux/include -O2 -g"
export docdir="/home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/share/doc"
export infodir="/home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/share/info"
export base_prefix="/home/michael/git/newstix/tmp/sysroots/x86_64-linux"
export TERM="xterm"
export base_sbindir="/home/michael/git/newstix/tmp/sysroots/x86_64-linux/bin"
export PKG_CONFIG_PATH="/home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/lib/pkgconfig:/home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/share/pkgconfig:/home/michael/git/newstix/tmp/sysroots/x86_64-linux/lib/pkgconfig:/home/michael/git/newstix/tmp/sysroots/x86_64-linux/share/pkgconfig"
export SDK_CXXFLAGS="-isystem/home/michael/git/newstix/tmp/sysroots/x86_64-linux/home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/include -isystem/home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/include -fexpensive-optimizations -frename-registers -fomit-frame-pointer -O2 -fpermissive"
export AS="as"
export AR="ar"
export BUILD_CPPFLAGS="-isystem/home/michael/git/newstix/tmp/sysroots/x86_64-linux/include"
export CPP="gcc -E"
export BUILD_CXXFLAGS="-isystem/home/michael/git/newstix/tmp/sysroots/x86_64-linux/include -O2 -g -fpermissive"
export HOME="/home/michael"
export TARGET_CPPFLAGS="-isystem/home/michael/git/newstix/tmp/sysroots/i486-oe-linux/home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/include"
export exec_prefix="/home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486"
export base_libdir="/home/michael/git/newstix/tmp/sysroots/x86_64-linux/lib"
export STAGING_IDLDIR="/home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/share/idl"
export PATH="/home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/bin:/home/michael/git/newstix/tmp/sysroots/x86_64-linux/home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/bin:/home/michael/git/newstix/tmp/sysroots/x86_64-linux/bin:/home/michael/git/newstix/tmp/sysroots/x86_64-linux/home/michael/git/newstix/tmp/sysroots/x86_64-linux/bin:/home/michael/git/newstix/tmp/sysroots/x86_64-linux//bin:/home/michael/git/newstix/bitbake/bin:/home/michael/bin:/usr/local/bin:/usr/bin:/usr/X11R6/bin:/bin:/usr/games:/opt/gnome/bin:/usr/lib/mit/bin:/usr/lib/mit/sbin"
unset MACHINE
export BUILD_AR="ar"
export sharedstatedir="/home/michael/git/newstix/tmp/sysroots/x86_64-linux/com"
export OBJDUMP="objdump"
unset DISTRO
export libdir="/home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/lib"
export SHELL="/bin/bash"
export palmqtdir="/home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/lib/opie"
export BUILD_STRIP="strip"
do_fetchall() {
:
}
base_do_configure() {
:
}
autotools_do_configure() {
case gcc-cross-initial in
autoconf*)
;;
automake*)
;;
*)
# WARNING: gross hack follows:
# An autotools built package generally needs these scripts, however only
# automake or libtoolize actually install the current versions of them.
# This is a problem in builds that do not use libtool or automake, in the case
# where we -need- the latest version of these scripts. e.g. running a build
# for a package whose autotools are old, on an x86_64 machine, which the old
# config.sub does not support. Work around this by installing them manually
# regardless.
( for ac in `find /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/gcc-4.3.3 -name configure.in -o -name configure.ac`; do
rm -f `dirname $ac`/configure
done )
if [ -e /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/gcc-4.3.3/configure.in -o -e /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/gcc-4.3.3/configure.ac ]; then
olddir=`pwd`
cd /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/gcc-4.3.3
if [ x"default" = xdefault ]; then
acpaths=
for i in `find /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/gcc-4.3.3 -maxdepth 2 -name \*.m4|grep -v 'aclocal.m4'| \
grep -v 'acinclude.m4' | sed -e 's,\(.*/\).*$,\1,'|sort -u`; do
acpaths="$acpaths -I $i"
done
else
acpaths="default"
fi
AUTOV=`automake --version |head -n 1 |sed "s/.* //;s/\.[0-9]\+$//"`
automake --version
echo "AUTOV is $AUTOV"
install -d /home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/share/aclocal
install -d /home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/share/aclocal-$AUTOV
acpaths="$acpaths -I/home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/share/aclocal-$AUTOV -I /home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/share/aclocal"
# autoreconf is too shy to overwrite aclocal.m4 if it doesn't look
# like it was auto-generated. Work around this by blowing it away
# by hand, unless the package specifically asked not to run aclocal.
if ! echo --exclude=autopoint | grep -q "aclocal"; then
rm -f aclocal.m4
fi
if [ -e configure.in ]; then
CONFIGURE_AC=configure.in
else
CONFIGURE_AC=configure.ac
fi
if grep "^[[:space:]]*AM_GLIB_GNU_GETTEXT" $CONFIGURE_AC >/dev/null; then
if grep "sed.*POTFILES" $CONFIGURE_AC >/dev/null; then
: do nothing -- we still have an old unmodified configure.ac
else
oenote Executing glib-gettextize --force --copy
echo "no" | glib-gettextize --force --copy
fi
else if grep "^[[:space:]]*AM_GNU_GETTEXT" $CONFIGURE_AC >/dev/null; then
if [ -e /home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/share/gettext/config.rpath ]; then
cp /home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/share/gettext/config.rpath /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/gcc-4.3.3/
else
oenote /home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/share/gettext/config.rpath not found. gettext is not installed.
fi
fi
fi
mkdir -p m4
oenote Executing autoreconf --verbose --install --force --exclude=autopoint $acpaths
autoreconf -Wcross --verbose --install --force --exclude=autopoint $acpaths || oefatal "autoreconf execution failed."
if grep "^[[:space:]]*[AI][CT]_PROG_INTLTOOL" $CONFIGURE_AC >/dev/null; then
oenote Executing intltoolize --copy --force --automake
intltoolize --copy --force --automake
fi
cd $olddir
fi
;;
esac
if [ -e /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/gcc-4.3.3/configure ]; then
oe_runconf $@
else
oenote "nothing to configure"
fi
}
sysroot_stage_libdir() {
src="$1"
dest="$2"
if [ "no" = "no" ]; then
olddir=`pwd`
cd $src
las=$(find . -name \*.la -type f)
cd $olddir
echo "Found la files: $las"
for i in $las
do
sed -e 's/^installed=yes$/installed=no/' \
-e '/^dependency_libs=/s,/home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1[[:alnum:]/\._+-]*/\([[:alnum:]\._+-]*\),/home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/lib/\1,g' \
-e "/^dependency_libs=/s,\([[:space:]']\)/home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/lib,\1/home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/lib,g" \
-e "/^libdir=/s,.*,libdir=/home/michael/git/newstix/tmp/sysroots/i486-oe-linux/lib,g" -e "/^dependency_libs=/s,\([[:space:]']\)-L/home/michael/git/newstix/tmp/sysroots/x86_64-linux/lib,,g" \
-i $src/$i
done
fi
sysroot_stage_dir $src $dest
}
die() {
oefatal "$*"
}
base_do_install() {
:
}
do_package_stage_all() {
:
}
base_do_package() {
:
}
oe_soinstall() {
# Purpose: Install shared library file and
# create the necessary links
# Example:
#
# oe_
#
#oenote installing shared library $1 to $2
#
libname=`basename $1`
install -m 755 $1 $2/$libname
sonamelink=`readelf -d $1 |grep 'Library soname:' |sed -e 's/.*\[\(.*\)\].*/\1/'`
solink=`echo $libname | sed -e 's/\.so\..*/.so/'`
ln -sf $libname $2/$sonamelink
ln -sf $libname $2/$solink
}
package_stagefile_shell() {
if [ "$PSTAGING_ACTIVE" = "1" ]; then
srcfile=$1
destfile=`echo $srcfile | sed s#/home/michael/git/newstix/tmp#/home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/staging-pkg#`
destdir=`dirname $destfile`
mkdir -p $destdir
cp -dp $srcfile $destfile
fi
}
oe_libinstall() {
# Purpose: Install a library, in all its forms
# Example
#
# oe_libinstall libltdl /home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/lib/
# oe_libinstall -C src/libblah libblah /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/image//home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/lib/
dir=""
libtool=""
silent=""
require_static=""
require_shared=""
staging_install=""
while [ "$#" -gt 0 ]; do
case "$1" in
-C)
shift
dir="$1"
;;
-s)
silent=1
;;
-a)
require_static=1
;;
-so)
require_shared=1
;;
-*)
oefatal "oe_libinstall: unknown option: $1"
;;
*)
break;
;;
esac
shift
done
libname="$1"
shift
destpath="$1"
if [ -z "$destpath" ]; then
oefatal "oe_libinstall: no destination path specified"
fi
if echo "$destpath/" | egrep '^/home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/lib/' >/dev/null
then
staging_install=1
fi
__runcmd () {
if [ -z "$silent" ]; then
echo >&2 "oe_libinstall: $*"
fi
$*
}
if [ -z "$dir" ]; then
dir=`pwd`
fi
dotlai=$libname.lai
# Sanity check that the libname.lai is unique
number_of_files=`(cd $dir; find . -name "$dotlai") | wc -l`
if [ $number_of_files -gt 1 ]; then
oefatal "oe_libinstall: $dotlai is not unique in $dir"
fi
dir=$dir`(cd $dir;find . -name "$dotlai") | sed "s/^\.//;s/\/$dotlai\$//;q"`
olddir=`pwd`
__runcmd cd $dir
lafile=$libname.la
# If such file doesn't exist, try to cut version suffix
if [ ! -f "$lafile" ]; then
libname1=`echo "$libname" | sed 's/-[0-9.]*$//'`
lafile1=$libname.la
if [ -f "$lafile1" ]; then
libname=$libname1
lafile=$lafile1
fi
fi
if [ -f "$lafile" ]; then
# libtool archive
eval `cat $lafile|grep "^library_names="`
libtool=1
else
library_names="$libname.so* $libname.dll.a"
fi
__runcmd install -d $destpath/
dota=$libname.a
if [ -f "$dota" -o -n "$require_static" ]; then
__runcmd install -m 0644 $dota $destpath/
fi
if [ -f "$dotlai" -a -n "$libtool" ]; then
if [ -n "$staging_install" -a "no" = "no" ]
then
# stop libtool using the final directory name for libraries
# in staging:
__runcmd rm -f $destpath/$libname.la
__runcmd sed -e 's/^installed=yes$/installed=no/' \
-e '/^dependency_libs=/s,/home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1[[:alnum:]/\._+-]*/\([[:alnum:]\._+-]*\),/home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/lib/\1,g' \
-e "/^dependency_libs=/s,\([[:space:]']\)/home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/lib,\1/home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/lib,g" \
$dotlai >$destpath/$libname.la
else
__runcmd install -m 0644 $dotlai $destpath/$libname.la
fi
fi
for name in $library_names; do
files=`eval echo $name`
for f in $files; do
if [ ! -e "$f" ]; then
if [ -n "$libtool" ]; then
oefatal "oe_libinstall: $dir/$f not found."
fi
elif [ -L "$f" ]; then
__runcmd cp -P "$f" $destpath/
elif [ ! -L "$f" ]; then
libfile="$f"
__runcmd install -m 0755 $libfile $destpath/
fi
done
done
if [ -z "$libfile" ]; then
if [ -n "$require_shared" ]; then
oefatal "oe_libinstall: unable to locate shared library"
fi
elif [ -z "$libtool" ]; then
# special case hack for non-libtool .so.#.#.# links
baselibfile=`basename "$libfile"`
if (echo $baselibfile | grep -qE '^lib.*\.so\.[0-9.]*$'); then
sonamelink=`readelf -d $libfile |grep 'Library soname:' |sed -e 's/.*\[\(.*\)\].*/\1/'`
solink=`echo $baselibfile | sed -e 's/\.so\..*/.so/'`
if [ -n "$sonamelink" -a x"$baselibfile" != x"$sonamelink" ]; then
__runcmd ln -sf $baselibfile $destpath/$sonamelink
fi
__runcmd ln -sf $baselibfile $destpath/$solink
fi
fi
__runcmd cd "$olddir"
}
oe_runconf() {
if [ -x /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/gcc-4.3.3/configure ] ; then
/home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/gcc-4.3.3/configure \
--build=x86_64-linux --host=x86_64-linux --target=i486-oe-linux --prefix=/home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486 --exec_prefix=/home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486 --bindir=/home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/bin --sbindir=/home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/bin --libexecdir=/home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/libexec --datadir=/home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/share --sysconfdir=/home/michael/git/newstix/tmp/sysroots/x86_64-linux/etc --sharedstatedir=/home/michael/git/newstix/tmp/sysroots/x86_64-linux/com --localstatedir=/home/michael/git/newstix/tmp/sysroots/x86_64-linux/var --libdir=/home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/lib --includedir=/home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/include --oldincludedir=/home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/include --infodir=/home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/share/info --mandir=/home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/share/man --with-local-prefix=/home/michael/git/newstix/tmp/sysroots/i486-oe-linux --with-newlib --without-headers --disable-shared --disable-threads --disable-multilib --disable-__cxa_atexit --enable-languages=c --program-prefix=i486-oe-linux- --with-sysroot=/home/michael/git/newstix/tmp/sysroots/i486-oe-linux --with-build-sysroot=/home/michael/git/newstix/tmp/sysroots/i486-oe-linux --with-build-time-tools=/home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/bin --disable-libmudflap --disable-libgomp --disable-libssp --enable-decimal-float=no --enable-target-optspace --program-prefix=i486-oe-linux- --enable-__cxa_atexit "$@"
else
oefatal "no configure script found"
fi
}
do_install() {
oe_runmake 'DESTDIR=/home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/image' install
install -d /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/image/lib
install -d /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/image/lib
for d in i486-oe-linux/lib/nof i486-oe-linux/lib64 i486-oe-linux/lib; do
if [ -d /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/image/home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/$d/ ]; then
mv -f /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/image/home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/$d/libgcc* /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/image/lib || true
mv -f /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/image/home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/$d/* /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/image/lib || true
fi
done
# since we are moving the .la files to target sysroot we need to make sure that
# libdir points to right place within the target sysroot
for la in /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/image/lib/libstdc++.la /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/image/lib/libsupc++.la; do
if [ -f $la ]; then
sed -i -e "s:^libdir=.*:libdir='/lib':g;" $la
fi
done
# Manually run the target stripper since we won't get it run by
# the packaging.
if [ "x${OLD_INHIBIT_PACKAGE_STRIP}" != "x1" ]; then
i486-oe-linux-strip /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/image/lib/libstdc++.so.* || true
i486-oe-linux-strip /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/image/lib/libg2c.so.* || true
i486-oe-linux-strip /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/image/lib/libgcc_s.so.* || true
i486-oe-linux-strip /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/image/lib/libgfortran*.so* || true
fi
# Link gfortran to g77 to satisfy not-so-smart configure or hard coded g77
# gfortran is fully backwards compatible. This is a safe and practical solution.
if [ -f /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/image/home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/bin/i486-oe-linux-gfortran ]; then
currdir="$PWD"
cd /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/image/home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/bin/
ln -sf i486-oe-linux-gfortran i486-oe-linux-g77 || true
if [ -d /home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/i486-oe-linux/bin/ ] ; then
cd /home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/i486-oe-linux/bin/
ln -sf gfortran g77 || true
fi
cd $currdir
fi
# We use libiberty from binutils or binutils-cross
rm -f /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/image/home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/lib/libiberty.a
rm -f /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/image/lib/libiberty.a
}
sysroot_stage_dirs() {
from="$1"
to="$2"
sysroot_stage_dir $from/home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/include $to/home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/include
if [ "x86_64-linux" = "x86_64-linux" ]; then
sysroot_stage_dir $from/home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/bin $to/home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/bin
sysroot_stage_dir $from/home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/bin $to/home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/bin
sysroot_stage_dir $from/home/michael/git/newstix/tmp/sysroots/x86_64-linux/bin $to/home/michael/git/newstix/tmp/sysroots/x86_64-linux/bin
sysroot_stage_dir $from/home/michael/git/newstix/tmp/sysroots/x86_64-linux/bin $to/home/michael/git/newstix/tmp/sysroots/x86_64-linux/bin
sysroot_stage_dir $from/home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/libexec $to/home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/libexec
sysroot_stage_dir $from/home/michael/git/newstix/tmp/sysroots/x86_64-linux/etc $to/home/michael/git/newstix/tmp/sysroots/x86_64-linux/etc
if [ "/home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/lib" != "/home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/lib" ]; then
# python puts its files in here, make sure they are staged as well
sysroot_stage_dir $from//home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/lib $to/home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/lib
fi
fi
if [ -d $from/home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/lib ]
then
sysroot_stage_libdir $from//home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/lib $to/home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/lib
fi
if [ -d $from/home/michael/git/newstix/tmp/sysroots/x86_64-linux/lib ]
then
sysroot_stage_libdir $from/home/michael/git/newstix/tmp/sysroots/x86_64-linux/lib $to/home/michael/git/newstix/tmp/sysroots/x86_64-linux/lib
fi
sysroot_stage_dir $from/home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/share $to/home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/share
sysroot_stage_dir $from/home/michael/git/newstix/tmp/sysroots/x86_64-linux/etc $to/home/michael/git/newstix/tmp/sysroots/x86_64-linux/etc
}
staging_package_installer() {
#stage-manager-ipkg -f /home/michael/git/newstix/tmp/pstage/opkg.conf -force-depends -o /home/michael/git/newstix/tmp install /home/michael/git/newstix/pstage/toastixglibc/staging-gcc-cross-initial-i486-oe-linux_4.3.3-r18.1_x86_64-linux-i486-linux.ipk
STATUSFILE=/home/michael/git/newstix/tmp/lib/opkg/status
echo "Package: staging-gcc-cross-initial-i486-oe-linux" >> $STATUSFILE
echo "Version: 4.3.3-r18.1" >> $STATUSFILE
echo "Status: install user installed" >> $STATUSFILE
echo "Architecture: x86_64-linux-i486-linux" >> $STATUSFILE
echo "" >> $STATUSFILE
CTRLFILE=/home/michael/git/newstix/tmp/lib/opkg/info/staging-gcc-cross-initial-i486-oe-linux.control
echo "Package: staging-gcc-cross-initial-i486-oe-linux" > $CTRLFILE
echo "Version: 4.3.3-r18.1" >> $CTRLFILE
echo "Architecture: x86_64-linux-i486-linux" >> $CTRLFILE
cd /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/staging-pkg
find -type f | grep -v ./CONTROL | sed -e 's/^\.//' > /home/michael/git/newstix/tmp/lib/opkg/info/staging-gcc-cross-initial-i486-oe-linux.list
}
oedebug() {
test $# -ge 2 || {
echo "Usage: oedebug level \"message\""
exit 1
}
test ${OEDEBUG:-0} -ge $1 && {
shift
echo "DEBUG:" $*
}
}
sysroot_stage_all() {
sysroot_stage_dir /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/image /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/sysroot-destdir/
install -d /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/sysroot-destdir//home/michael/git/newstix/tmp/sysroots/i486-oe-linux/lib/
install -d /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/sysroot-destdir//home/michael/git/newstix/tmp/sysroots/i486-oe-linux/lib/
if [ -d /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/sysroot-destdir//lib ]; then
sysroot_stage_libdir /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/sysroot-destdir//lib /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/sysroot-destdir//home/michael/git/newstix/tmp/sysroots/i486-oe-linux/lib
fi
if [ -d /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/sysroot-destdir//lib ]; then
sysroot_stage_libdir /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/sysroot-destdir//lib /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/sysroot-destdir//home/michael/git/newstix/tmp/sysroots/i486-oe-linux/lib
fi
}
oe_runmake() {
oenote make ARCH_FLAGS_FOR_TARGET='-march=i486 -isystem/home/michael/git/newstix/tmp/sysroots/i486-oe-linux/include' "$@"
make ARCH_FLAGS_FOR_TARGET='-march=i486 -isystem/home/michael/git/newstix/tmp/sysroots/i486-oe-linux/include' "$@" || die "oe_runmake failed"
}
populate_sysroot_preamble() {
if [ "$PSTAGING_ACTIVE" = "1" ]; then
stage-manager -p /home/michael/git/newstix/tmp/sysroots -c /home/michael/git/newstix/tmp/pstage/stamp-cache-staging -u || true
fi
}
oe_machinstall() {
# Purpose: Install machine dependent files, if available
# If not available, check if there is a default
# If no default, just touch the destination
# Example:
# $1 $2 $3 $4
# oe_machinstall -m 0644 fstab /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/image/etc/fstab
#
# TODO: Check argument number?
#
filename=`basename $3`
dirname=`dirname $3`
for o in `echo task-configure:libc-glibc:libc-glibc:pn-gcc-cross-initial:fail-fast:build-linux:i486:linux:toastix::soekris-4xxx:local:i486:i486:soekris-4xxx | tr ':' ' '`; do
if [ -e $dirname/$o/$filename ]; then
oenote $dirname/$o/$filename present, installing to $4
install $1 $2 $dirname/$o/$filename $4
return
fi
done
# oenote overrides specific file NOT present, trying default=$3...
if [ -e $3 ]; then
oenote $3 present, installing to $4
install $1 $2 $3 $4
else
oenote $3 NOT present, touching empty $4
touch $4
fi
}
autotools_stage_all() {
if [ "${INHIBIT_AUTO_STAGE}" = "1" ]
then
return
fi
rm -rf /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/temp-staging
mkdir -p /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/temp-staging
oe_runmake DESTDIR="/home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/temp-staging" install
rm -rf /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/temp-staging//home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/share/man || true
rm -rf /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/temp-staging//home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/share/info || true
sysroot_stage_dirs /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/temp-staging
rm -rf /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/temp-staging
}
do_configure() {
export CC="gcc "
export AR_FOR_TARGET="i486-oe-linux-ar"
export AS_FOR_TARGET="i486-oe-linux-as"
export RANLIB_FOR_TARGET="i486-oe-linux-ranlib"
export LD_FOR_TARGET="i486-oe-linux-ld"
export NM_FOR_TARGET="i486-oe-linux-nm"
export OBJDUMP_FOR_TARGET="i486-oe-linux-objdump"
export OBJCOPY_FOR_TARGET="i486-oe-linux-objcopy"
export STRIP_FOR_TARGET="i486-oe-linux-strip"
export CC_FOR_TARGET=" i486-oe-linux-gcc -march=i486"
# Make sure we use GMP/MPFR statically
sed -i 's/^\(HOST_GMPLIBS =\) \(.*\)$/\1 -Wl,-Bstatic \2 -Wl,-Bdynamic/' /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/gcc-4.3.3/Makefile.tpl
sed -i 's/^\(HOST_GMPLIBS =\) \(.*\)$/\1 -Wl,-Bstatic \2 -Wl,-Bdynamic/' /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/gcc-4.3.3/Makefile.in
sed -i 's/^\(HOST_PPLLIBS =\) \(.*\)$/\1 -Wl,-Bstatic \2 -Wl,-Bdynamic/' /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/gcc-4.3.3/Makefile.tpl
sed -i 's/^\(HOST_PPLLIBS =\) \(.*\)$/\1 -Wl,-Bstatic \2 -Wl,-Bdynamic/' /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/gcc-4.3.3/Makefile.in
sed -i 's/^\(HOST_LIBELFLIBS =\) \(.*\)$/\1 -Wl,-Bstatic \2 -Wl,-Bdynamic/' /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/gcc-4.3.3/Makefile.tpl
sed -i 's/^\(HOST_LIBELFLIBS =\) \(.*\)$/\1 -Wl,-Bstatic \2 -Wl,-Bdynamic/' /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/gcc-4.3.3/Makefile.in
# Setup these vars for cross building only
# ... because foo_FOR_TARGET apparently gets misinterpreted inside the
# gcc build stuff when the build is producing a cross compiler - i.e.
# when the 'current' target is the 'host' system, and the host is not
# the target (because the build is actually making a cross compiler!)
if [ "x86_64-linux" != "x86_64-linux" ]; then
export CC_FOR_TARGET="gcc "
export GCC_FOR_TARGET="gcc "
export CXX_FOR_TARGET="g++ "
export AS_FOR_TARGET="as"
export LD_FOR_TARGET="ld"
export NM_FOR_TARGET="nm"
export AR_FOR_TARGET="ar"
export GFORTRAN_FOR_TARGET="gfortran"
export RANLIB_FOR_TARGET="ranlib"
fi
export CC_FOR_BUILD="gcc "
export CXX_FOR_BUILD="g++ "
export CFLAGS_FOR_BUILD="-isystem/home/michael/git/newstix/tmp/sysroots/x86_64-linux/include -O2 -g"
export CPPFLAGS_FOR_BUILD="-isystem/home/michael/git/newstix/tmp/sysroots/x86_64-linux/include"
export CXXFLAGS_FOR_BUILD="-isystem/home/michael/git/newstix/tmp/sysroots/x86_64-linux/include -O2 -g -fpermissive"
export LDFLAGS_FOR_BUILD="-L/home/michael/git/newstix/tmp/sysroots/x86_64-linux/lib -Wl,-rpath-link,/home/michael/git/newstix/tmp/sysroots/x86_64-linux/lib -Wl,-rpath,/home/michael/git/newstix/tmp/sysroots/x86_64-linux/lib -Wl,-O1"
export ARCH_FLAGS_FOR_TARGET="-march=i486 -isystem/home/michael/git/newstix/tmp/sysroots/i486-oe-linux/include"
# Make sure LDFLAGS are honored.
sed -i 's/^LDFLAGS = $/LDFLAGS = @LDFLAGS@/' /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/gcc-4.3.3/Makefile.in
sed -i 's/^LDFLAGS = $/LDFLAGS = @LDFLAGS@/' /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/gcc-4.3.3/Makefile.tpl
(cd /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/gcc-4.3.3 && gnu-configize) || die "failure running gnu-configize"
if [ "x86_64-linux" != "i486-oe-linux" ]; then
# splice our idea of where the headers live into gcc's world
echo "NATIVE_SYSTEM_HEADER_DIR = /include" > /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/temp/t-oe
sed 's%^tmake_file=.*$%& /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/temp/t-oe%' < /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/gcc-4.3.3/gcc/Makefile.in >/home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/gcc-4.3.3/gcc/Makefile.in.new
mv /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/gcc-4.3.3/gcc/Makefile.in.new /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/gcc-4.3.3/gcc/Makefile.in
cat /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/gcc-4.3.3/gcc/defaults.h | grep -v "\#endif.*GCC_DEFAULTS_H" > /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/gcc-4.3.3/gcc/defaults.h.new
echo "#ifndef STANDARD_INCLUDE_DIR" >> /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/gcc-4.3.3/gcc/defaults.h.new
echo "#define STANDARD_INCLUDE_DIR \"/include\"" >> /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/gcc-4.3.3/gcc/defaults.h.new
echo "#endif" >> /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/gcc-4.3.3/gcc/defaults.h.new
echo "#endif /* ! GCC_DEFAULTS_H */" >> /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/gcc-4.3.3/gcc/defaults.h.new
mv /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/gcc-4.3.3/gcc/defaults.h.new /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/gcc-4.3.3/gcc/defaults.h
fi
oe_runconf
# make sure that no @LDFLAG@ is left in the generated Makefile
sed -i "s/@LDFLAGS@//g" /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/gcc-4.3.3/build.x86_64-linux.i486-oe-linux/Makefile
}
SRC_DISTRIBUTECOMMAND() {
test -e "${SRC}.md5" && ln -sf "${SRC}.md5" .
ln -sf "${SRC}" .
}
PREMIRRORS() {
ftp://.*/.* http://jrz.cbnco.com/toastix/sources/
https?$://.*/.* http://jrz.cbnco.com/toastix/sources/
}
sysroot_stage_dir() {
src="$1"
dest="$2"
# This will remove empty directories so we can ignore them
rmdir "$src" 2> /dev/null || true
if [ -d "$src" ]; then
mkdir -p "$dest"
cp -fpPR "$src"/* "$dest"
fi
}
do_buildall() {
:
}
ldconfig_postinst_fragment() {
if [ x"$D" = "x" ]; then
if [ -e /etc/ld.so.conf ] ; then
[ -x /sbin/ldconfig ] && /sbin/ldconfig
fi
fi
}
autotools_do_install() {
oe_runmake 'DESTDIR=/home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/image' install
}
staging_helper() {
# Assemble appropriate opkg.conf
conffile=/home/michael/git/newstix/tmp/pstage/opkg.conf
mkdir -p /home/michael/git/newstix/tmp/pstage/pstaging_lists
arch="x86_64-linux-i486-linux"
if [ ! -e $conffile ]; then
echo "arch $arch 1" > $conffile
echo "dest root /" >> $conffile
elif [ `grep -c " $arch " $conffile` -eq 0 ]; then
priority=$(expr `grep -cE "^arch" $conffile` + 1)
sed -i -e "/dest/iarch $arch $priority" $conffile
fi
if [ ! -e /home/michael/git/newstix/tmp/lib/opkg/info/ ]; then
mkdir -p /home/michael/git/newstix/tmp/lib/opkg/info/
fi
if [ ! -e /home/michael/git/newstix/tmp/lib/ipkg/ ]; then
ln -sf opkg/ /home/michael/git/newstix/tmp/lib/ipkg || true
fi
}
populate_sysroot_postamble() {
if [ "$PSTAGING_ACTIVE" = "1" ]; then
# list the packages currently installed in staging
# stage-manager-ipkg -f /home/michael/git/newstix/tmp/pstage/opkg.conf -o /home/michael/git/newstix/tmp list_installed | awk '{print $1}' > /home/michael/git/newstix/tmp/pstage/installed-list
# exitcode == 5 is ok, it means the files change
set +e
stage-manager -p /home/michael/git/newstix/tmp/sysroots -c /home/michael/git/newstix/tmp/pstage/stamp-cache-staging -u -d /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/staging-pkg/sysroots
exitcode=$?
if [ "$exitcode" != "5" -a "$exitcode" != "0" ]; then
exit $exitcode
fi
set -e
fi
}
do_checkuriall() {
:
}
staging_packager() {
mkdir -p /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/staging-pkg/CONTROL
mkdir -p /home/michael/git/newstix/pstage/toastixglibc
echo "Package: staging-gcc-cross-initial-i486-oe-linux" > /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/staging-pkg/CONTROL/control
echo "Version: 4.3.3-r18.1" >> /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/staging-pkg/CONTROL/control
echo "Description: The GNU cc and gcc C compilers." >> /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/staging-pkg/CONTROL/control
echo "Section: devel" >> /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/staging-pkg/CONTROL/control
echo "Priority: Optional" >> /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/staging-pkg/CONTROL/control
echo "Maintainer: OpenEmbedded Team <openembedded-devel@lists.openembedded.org>" >> /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/staging-pkg/CONTROL/control
echo "Architecture: x86_64-linux-i486-linux" >> /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/staging-pkg/CONTROL/control
# Protect against empty SRC_URI
srcuri="ftp://ftp.gnu.org/gnu/gcc/gcc-4.3.3/gcc-4.3.3.tar.bz2;name=archive file://fedora/gcc43-c++-builtin-redecl.patch;striplevel=0 file://fedora/gcc43-ia64-libunwind.patch;striplevel=0 file://fedora/gcc43-java-nomulti.patch;striplevel=0 file://fedora/gcc43-ppc32-retaddr.patch;striplevel=0 file://fedora/gcc43-pr27898.patch;striplevel=0 file://fedora/gcc43-pr32139.patch;striplevel=0 file://fedora/gcc43-pr33763.patch;striplevel=0 file://fedora/gcc43-rh330771.patch;striplevel=0 file://fedora/gcc43-rh341221.patch;striplevel=0 file://fedora/gcc43-cpp-pragma.patch;striplevel=0 file://fedora/gcc43-java-debug-iface-type.patch;striplevel=0 file://fedora/gcc43-libgomp-speedup.patch;striplevel=0 file://fedora/gcc43-i386-libgomp.patch;striplevel=0 file://fedora/gcc43-rh251682.patch;striplevel=0 file://debian/arm-unbreak-eabi-armv4t.dpatch;apply=yes file://debian/armel-atomic-builtins.dpatch;apply=yes;striplevel=0 file://debian/libstdc++-pic.dpatch;apply=yes;striplevel=0 file://debian/gcc-ice-hack.dpatch;apply=yes;striplevel=0 file://debian/pr30961.dpatch;apply=yes;striplevel=0 file://100-uclibc-conf.patch file://103-uclibc-conf-noupstream.patch file://200-uclibc-locale.patch file://203-uclibc-locale-no__x.patch file://204-uclibc-locale-wchar_fix.patch file://205-uclibc-locale-update.patch file://301-missing-execinfo_h.patch file://302-c99-snprintf.patch file://303-c99-complex-ugly-hack.patch file://304-index_macro.patch file://305-libmudflap-susv3-legacy.patch file://306-libstdc++-namespace.patch file://307-locale_facets.patch file://602-sdk-libstdc++-includes.patch file://740-sh-pr24836.patch file://800-arm-bigendian.patch file://904-flatten-switch-stmt-00.patch file://arm-nolibfloat.patch file://arm-softfloat.patch file://gcc-4.4-20090519-arm-eabi-atomic-builtins-unbreak-v2.patch file://cache-amnesia.patch file://gfortran-4.3.x.patch file://gcc-4.0.2-e300c2c3.patch file://gcc-arm-frename-registers.patch file://gcc-4.3.1-ARCH_FLAGS_FOR_TARGET.patch file://zecke-xgcc-cpp.patch file://gcc-flags-for-build.patch file://gcc-pr36218.patch file://gcc-4.3.3-SYSROOT_CFLAGS_FOR_TARGET.patch file://gcc-4.3.3-fix-EXTRA_BUILD.patch file://arm-gcc-objective.patch file://Makefile.in.patch file://Makefile.in.parallel.patch file://zecke-no-host-includes.patch "
if [ "$srcuri" == "" ]; then
srcuri="OpenEmbedded"
fi
echo "Source: $srcuri" >> /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/staging-pkg/CONTROL/control
# Deal with libtool not supporting sysroots
# Need to remove hardcoded paths and fix these when we install the
# staging packages.
# Could someone please add sysroot support to libtool!
for i in `grep -Irl /home/michael/git/newstix/tmp /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/staging-pkg` ; do \
sed -i -e s:/home/michael/git/newstix/tmp/sysroots:FIXMESTAGINGDIR:g $i
echo $i | sed -e 's:/home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/staging-pkg/::' >> /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/staging-pkg/sysroots/fixmepath
done
stage-manager-ipkg-build -o 0 -g 0 /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/staging-pkg /home/michael/git/newstix/pstage/toastixglibc
}
do_compile() {
base_do_compile
}
autotools_stage_includes() {
if [ "${INHIBIT_AUTO_STAGE_INCLUDES}" != "1" ]
then
rm -rf /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/temp-staging
mkdir -p /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/temp-staging
make DESTDIR="/home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/temp-staging" install
cp -pPR /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/temp-staging//home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/include/* /home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/include
rm -rf /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/temp-staging
fi
}
oewarn() {
echo "WARNING:" "$*"
}
oefatal() {
echo "FATAL:" "$*"
exit 1
}
autotools_stage_libdir() {
sysroot_stage_libdir $1 $2
}
base_do_compile() {
if [ -e Makefile -o -e makefile -o -e GNUmakefile ]; then
oe_runmake || die "make failed"
else
oenote "nothing to compile"
fi
}
autotools_stage_dir() {
sysroot_stage_dir $1 $2
}
autotools_prepackage_lamangler() {
for i in `find /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/package -name "*.la"` ; do \
sed -i -e 's:/home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/lib:/home/michael/git/newstix/tmp/sysroots/x86_64-linux/i486/lib:g;' \
-e 's:/home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/image::g;' \
-e 's:-I/home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1\S*: :g;' \
-e 's:-L/home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1\S*: :g;' \
$i
done
}
oenote() {
echo "NOTE:" "$*"
}
do_package_write() {
:
}
MIRRORS() {
ftp://ftp.gnu.org/gnu/gcc/releases/ ftp://gcc.gnu.org/pub/gcc/releases/
ftp://ftp.gnu.org/gnu/gcc/ http://mirrors.rcn.net/pub/sourceware/gcc/releases/
ftp://ftp.gnu.org/gnu/gcc/releases/ http://gcc.get-software.com/releases/
ftp://ftp.gnu.org/gnu/gcc/ http://gcc.get-software.com/releases/
ftp://ftp.debian.org/debian/pool/main http://snapshot.debian.net/archive/pool
ftp://ftp.debian.org/debian/pool ftp://ftp.de.debian.org/debian/pool
ftp://ftp.debian.org/debian/pool ftp://ftp.au.debian.org/debian/pool
ftp://ftp.debian.org/debian/pool ftp://ftp.cl.debian.org/debian/pool
ftp://ftp.debian.org/debian/pool ftp://ftp.hr.debian.org/debian/pool
ftp://ftp.debian.org/debian/pool ftp://ftp.fi.debian.org/debian/pool
ftp://ftp.debian.org/debian/pool ftp://ftp.hk.debian.org/debian/pool
ftp://ftp.debian.org/debian/pool ftp://ftp.hu.debian.org/debian/pool
ftp://ftp.debian.org/debian/pool ftp://ftp.ie.debian.org/debian/pool
ftp://ftp.debian.org/debian/pool ftp://ftp.it.debian.org/debian/pool
ftp://ftp.debian.org/debian/pool ftp://ftp.jp.debian.org/debian/pool
ftp://ftp.debian.org/debian/pool ftp://ftp.no.debian.org/debian/pool
ftp://ftp.debian.org/debian/pool ftp://ftp.pl.debian.org/debian/pool
ftp://ftp.debian.org/debian/pool ftp://ftp.ro.debian.org/debian/pool
ftp://ftp.debian.org/debian/pool ftp://ftp.si.debian.org/debian/pool
ftp://ftp.debian.org/debian/pool ftp://ftp.es.debian.org/debian/pool
ftp://ftp.debian.org/debian/pool ftp://ftp.se.debian.org/debian/pool
ftp://ftp.debian.org/debian/pool ftp://ftp.tr.debian.org/debian/pool
ftp://ftp.gnu.org/gnu ftp://mirrors.kernel.org/gnu
ftp://ftp.gnu.org/gnu ftp://ftp.cs.ubc.ca/mirror2/gnu
ftp://ftp.gnu.org/gnu ftp://sunsite.ust.hk/pub/gnu
ftp://ftp.gnu.org/gnu ftp://ftp.ayamura.org/pub/gnu
http://kernel.org http://www.kernel.org/pub
http://kernel.org ftp://ftp.us.kernel.org/pub
http://kernel.org ftp://ftp.uk.kernel.org/pub
http://kernel.org ftp://ftp.hk.kernel.org/pub
http://kernel.org ftp://ftp.au.kernel.org/pub
http://kernel.org ftp://ftp.jp.kernel.org/pub
ftp://ftp.gnupg.org/gcrypt/ ftp://ftp.franken.de/pub/crypt/mirror/ftp.gnupg.org/gcrypt/
ftp://ftp.gnupg.org/gcrypt/ ftp://ftp.surfnet.nl/pub/security/gnupg/
ftp://ftp.gnupg.org/gcrypt/ http://gulus.USherbrooke.ca/pub/appl/GnuPG/
ftp://dante.ctan.org/tex-archive ftp://ftp.fu-berlin.de/tex/CTAN
ftp://dante.ctan.org/tex-archive http://sunsite.sut.ac.jp/pub/archives/ctan/
ftp://dante.ctan.org/tex-archive http://ctan.unsw.edu.au/
ftp://ftp.gnutls.org/pub/gnutls ftp://ftp.gnutls.org/pub/gnutls/
ftp://ftp.gnutls.org/pub/gnutls ftp://ftp.gnupg.org/gcrypt/gnutls/
ftp://ftp.gnutls.org/pub/gnutls http://www.mirrors.wiretapped.net/security/network-security/gnutls/
ftp://ftp.gnutls.org/pub/gnutls ftp://ftp.mirrors.wiretapped.net/pub/security/network-security/gnutls/
ftp://ftp.gnutls.org/pub/gnutls http://josefsson.org/gnutls/releases/
http://ftp.info-zip.org/pub/infozip/src/ http://mirror.switch.ch/ftp/mirror/infozip/src/
http://ftp.info-zip.org/pub/infozip/src/ ftp://sunsite.icm.edu.pl/pub/unix/archiving/info-zip/src/
ftp://lsof.itap.purdue.edu/pub/tools/unix/lsof/ ftp://ftp.cerias.purdue.edu/pub/tools/unix/sysutils/lsof/
ftp://lsof.itap.purdue.edu/pub/tools/unix/lsof/ ftp://ftp.tau.ac.il/pub/unix/admin/
ftp://lsof.itap.purdue.edu/pub/tools/unix/lsof/ ftp://ftp.cert.dfn.de/pub/tools/admin/lsof/
ftp://lsof.itap.purdue.edu/pub/tools/unix/lsof/ ftp://ftp.fu-berlin.de/pub/unix/tools/lsof/
ftp://lsof.itap.purdue.edu/pub/tools/unix/lsof/ ftp://ftp.kaizo.org/pub/lsof/
ftp://lsof.itap.purdue.edu/pub/tools/unix/lsof/ ftp://ftp.tu-darmstadt.de/pub/sysadmin/lsof/
ftp://lsof.itap.purdue.edu/pub/tools/unix/lsof/ ftp://ftp.tux.org/pub/sites/vic.cc.purdue.edu/tools/unix/lsof/
ftp://lsof.itap.purdue.edu/pub/tools/unix/lsof/ ftp://gd.tuwien.ac.at/utils/admin-tools/lsof/
ftp://lsof.itap.purdue.edu/pub/tools/unix/lsof/ ftp://sunsite.ualberta.ca/pub/Mirror/lsof/
ftp://lsof.itap.purdue.edu/pub/tools/unix/lsof/ ftp://the.wiretapped.net/pub/security/host-security/lsof/
http://www.apache.org/dist http://archive.apache.org/dist
ftp://.*/.* http://mirrors.openembedded.org/
https?$://.*/.* http://mirrors.openembedded.org/
ftp://.*/.* http://sources.openembedded.org/
https?$://.*/.* http://sources.openembedded.org/
ftp://.*/.* http://jrz.cbnco.com/toastix/sources/
https?$://.*/.* http://jrz.cbnco.com/toastix/sources/
}
packagedstaging_fastpath() {
mkdir -p /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/staging-pkg/sysroots/
cp -fpPR /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/sysroot-destdir///home/michael/git/newstix/tmp/sysroots/* /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/staging-pkg/sysroots/ || /bin/true
}
create_wrapper() {
# Create a wrapper script
#
# These are useful to work around relocation issues, by setting environment
# variables which point to paths in the filesystem.
#
# Usage: create_wrapper FILENAME [[VAR=VALUE]..]
cmd=$1
shift
# run echo via env to test syntactic validity of the variable arguments
env $@ echo "Generating wrapper script for $cmd"
mv $cmd $cmd.real
cmdname=`basename $cmd`.real
cat <<END >$cmd
#!/bin/sh
exec env $@ \`dirname \$0\`/$cmdname "\$@"
END
chmod +x $cmd
}
cd /home/michael/git/newstix/tmp/work/i486-oe-linux/gcc-cross-initial-4.3.3-r18.1/gcc-4.3.3/build.x86_64-linux.i486-oe-linux
do_configure