# Distributed under the GPL v2
# $Id$
+ 25 Jun 2011; Matt Turner <mattst88@gentoo.org>
+ targets/support/chroot-functions.sh:
+ Use get_libdir instead of hard-coding lib for distcc
+
25 Jun 2011; Matt Turner <mattst88@gentoo.org>
modules/catalyst/arch/mips.py: add multilib (and missing n64) classes
# This sets up automatic cross-distcc-fu according to
# http://www.gentoo.org/doc/en/cross-compiling-distcc.xml
CHOST=$(portageq envvar CHOST)
- # TODO: change to use get_libdir
- cd /usr/lib/distcc/bin
+ LIBDIR=$(get_libdir)
+ cd /usr/${LIBDIR}/distcc/bin
rm cc gcc g++ c++ 2>/dev/null
- echo -e '#!/bin/bash\nexec /usr/lib/distcc/bin/'${CHOST}'-g${0:$[-2]} "$@"' > ${CHOST}-wrapper
- chmod a+x /usr/lib/distcc/bin/${CHOST}-wrapper
+ echo -e '#!/bin/bash\nexec /usr/'${LIBDIR}'/distcc/bin/'${CHOST}'-g${0:$[-2]} "$@"' > ${CHOST}-wrapper
+ chmod a+x /usr/${LIBDIR}/distcc/bin/${CHOST}-wrapper
for i in cc gcc g++ c++; do ln -s ${CHOST}-wrapper ${i}; done
fi
}
cleanup_distcc() {
+ LIBDIR=$(get_libdir)
rm -rf /etc/distcc/hosts
for i in cc gcc c++ g++; do
- # TODO: change to use get_libdir
- rm -f /usr/lib/distcc/bin/${i}
- ln -s /usr/bin/distcc /usr/lib/distcc/bin/${i}
+ rm -f /usr/${LIBDIR}/distcc/bin/${i}
+ ln -s /usr/bin/distcc /usr/${LIBDIR}/distcc/bin/${i}
done
- rm -f /usr/lib/distcc/bin/*-wrapper
+ rm -f /usr/${LIBDIR}/distcc/bin/*-wrapper
}
cleanup_icecream() {