diff options
author | DJ Delorie <dj@delorie.com> | 2012-07-03 17:52:57 -0400 |
---|---|---|
committer | DJ Delorie <dj@delorie.com> | 2012-07-03 17:52:57 -0400 |
commit | 682b4ba85c22ab9862304cb883a7234373e3f893 (patch) | |
tree | c8f5f090dbe0e324d377c629a8f6361db4fd68cd /stage1 | |
parent | 3d5366a613c9b6b5f76dd091c1b4b46ca3d5710e (diff) | |
download | bootstrap.git.DONOTUSE-682b4ba85c22ab9862304cb883a7234373e3f893.tar.gz bootstrap.git.DONOTUSE-682b4ba85c22ab9862304cb883a7234373e3f893.tar.xz bootstrap.git.DONOTUSE-682b4ba85c22ab9862304cb883a7234373e3f893.zip |
script->make, ccache move
Convert build iteration logic (stage 2) from list driven to Makefile
driven. Add actual dependencies to recipe files and use them to control
build sequence.
ccache is moved to stage1 and configured to be used in stage2.
Diffstat (limited to 'stage1')
-rwxr-xr-x | stage1 | 30 |
1 files changed, 27 insertions, 3 deletions
@@ -359,6 +359,7 @@ case "$1" in go xz go grep go distcc + go ccache go stage2 @@ -776,6 +777,7 @@ EOF notparallel make $J make $J install DESTDIR=${ROOTFS} + ln -s gcc ${ROOTFS}/usr/bin/cc ;; make | tar | gzip | diffutils | findutils | gawk | which | grep ) @@ -912,11 +914,27 @@ EOF mcd $ROOTFS/stage2/distcc-bin for p in gcc cc g++ c++ as ${TARGET}-gcc ${TARGET}-g++ ${TARGET}-as do - test -f $p && rm $p + test -e $p && rm $p ln -s /usr/bin/distcc $p done ;; + ccache ) + srpm ccache + mcd $BUILDDIR ccache + $SRC/${1}-*/configure $TCONFIGARGS + notparallel + make $J V=1 + make $J install DESTDIR=${ROOTFS} + + mcd $ROOTFS/stage2/ccache-bin + for p in gcc cc g++ c++ as ${TARGET}-gcc ${TARGET}-g++ ${TARGET}-as + do + test -e $p && rm $p + ln -s /usr/bin/ccache $p + done + ;; + stage2 ) # install source trees in rootfs, so stage2 will have them for # its builds. @@ -939,6 +957,8 @@ EOF # before they can be used. cp $MYDIR/recipe.d/* $ROOTFS/stage2/recipe.d + cp $MYDIR/macros.bashrc $ROOTFS/stage2 + cp $MYDIR/script2makefile $ROOTFS/stage2 for PKG in $ROOTFS/stage2/recipe.d/[0-9][0-9][0-9][0-9]-* do @@ -963,9 +983,13 @@ EOF ( newJ=$(echo $J | sed 's/-j//') echo J=-j$newJ + echo DISTCC_HOSTS=$(host $(hostname) | sed 's/.* //'):${DISTCC_PORT}/999 echo DISTCC_BACKOFF_PERIOD=0 echo PATH=/stage2/distcc-bin:\$PATH + + echo PATH=/stage2/ccache-bin:\$PATH + echo TARGET=$TARGET echo RPMTARGET=$RPMTARGET echo TCONFIGARGS=\"$TCONFIGARGS\" \ @@ -980,10 +1004,10 @@ EOF ) > $ROOTFS/stage2/local.conf mcd $PREFIX/distccd-bin - rm -f gcc cc g++ c++ as + rm -f gcc cc g++ c++ as ${TARGET}-gcc ${TARGET}-g++ ${TARGET}-as ln -s $PREFIX/bin/${TARGET}-gcc gcc - ln -s $PREFIX/bin/${TARGET}-gcc ${TARGET}-gcc ln -s $PREFIX/bin/${TARGET}-gcc cc + ln -s $PREFIX/bin/${TARGET}-gcc ${TARGET}-gcc ln -s $PREFIX/bin/${TARGET}-g++ ${TARGET}-g++ ln -s $PREFIX/bin/${TARGET}-g++ g++ ln -s $PREFIX/bin/${TARGET}-g++ c++ |