make CFLAGS="$CFLAGS" BOOT_CFLAGS="$CFLAGS" LDFLAGS="$LDFLAGS" \
- profiledbootstrap
+ profiledbootstrap &&
+make DESTDIR=$SOURCE_DIRECTORY.install install-no-fixedincludes &&
+
+# set up specs file handling
+local SPECSDIR=$SOURCE_DIRECTORY.install/usr/lib/gcc/$HOST/$VERSION
&&
+mkdir -p $SPECSDIR/specs-local &&
+cp gcc/specs $SPECSDIR/specs-local/specs-gcc &&
+if [[ $HOST == x86_64-* && $GCC_NOLIB64 == n ]]
+then
+ # make sure the linker gets compiled in as a /lib64 one
+ sed -i 's#/lib/ld-linux-x86-64.so.2#/lib64/ld-linux-x86-64.so.2#'
$SPECSDIR/specs-local/specs-gcc
+fi &&
+# make sure installwatch tracks it, the cat alone doesn't do that
+touch $SPECSDIR/specs &&
+cat $SPECSDIR/specs-local/* > $SPECSDIR/specs
+
diff --git a/gnu/gcc/FINAL b/gnu/gcc/FINAL
index 907a1a0..41b42d3 100755
--- a/gnu/gcc/FINAL
+++ b/gnu/gcc/FINAL
@@ -1 +1,4 @@
rm_source_dir $SOURCE_DIRECTORY.bld
+rm_source_dir $SOURCE_DIRECTORY.install
+ln -sf gcc-${VERSION%.*} ${TRACK_ROOT}/usr/bin/gcc
+ln -sf gcc ${TRACK_ROOT}/usr/bin/cc
diff --git a/gnu/gcc/HISTORY b/gnu/gcc/HISTORY
index 42d227d..81f1ad7 100644
--- a/gnu/gcc/HISTORY
+++ b/gnu/gcc/HISTORY
@@ -1,3 +1,9 @@
+2007-10-20 David Brown <dmlb2000 AT gmail.com>
+ * BUILD: added install to stage area and program prefix
+ * FINAL: removed stage area
+ * INSTALL: installed gcc from stage area to system
+ * PRE_BUILD: created stage area
+
2007-10-20 David Brown <dmlb2000 AT gmail.com>
* INSTALL: make sure if they are using lib64 to compile in the linker
as if it was in /lib64
diff --git a/gnu/gcc/INSTALL b/gnu/gcc/INSTALL
index 7ed5d01..d4bbdb5 100755
--- a/gnu/gcc/INSTALL
+++ b/gnu/gcc/INSTALL
@@ -1,32 +1,20 @@
#
# Bug #10647, also fixed in devel Sorcery
#
-cd $SOURCE_DIRECTORY.bld &&
+cd $SOURCE_DIRECTORY.install &&
+local libdir=lib
+[[ -d usr/lib64 ]] && libdir=lib64
-# in some weird cases, this actually fails with multiple jobs
-make_single &&
-make CFLAGS="$CFLAGS" BOOT_CFLAGS="$CFLAGS" LDFLAGS="$LDFLAGS" \
- install-no-fixedincludes &&
-
-if [[ "$HOST" == x86_64-* ]]; then
- [ -d /lib64 -a ! -f /lib/ld-linux-x86-64.so.2 -a -f
/lib64/ld-linux-x86-64.so.2 ] &&
- ln -s $TRACK_ROOT/lib64/ld-linux-x86-64.so.2 /lib/ld-linux-x86-64.so.2
- true # see bug 8626 for info about this conditional
-fi &&
-
-# make some extra symlinks
-ln -sf gcc ${INSTALL_ROOT}/usr/bin/cc &&
-ln -sf ${TRACK_ROOT}/usr/bin/cpp ${INSTALL_ROOT}/lib &&
-
-# set up specs file handling
-local SPECSDIR=${INSTALL_ROOT}/usr/lib/gcc/$HOST/$VERSION &&
-mkdir -p $SPECSDIR/specs-local &&
-cp gcc/specs $SPECSDIR/specs-local/specs-gcc &&
-if [[ $HOST == x86_64-* && $GCC_NOLIB64 == n ]]
-then
- # make sure the linker gets compiled in as a /lib64 one
- sed -i 's#/lib/ld-linux-x86-64.so.2#/lib64/ld-linux-x86-64.so.2#'
$SPECSDIR/specs-local/specs-gcc
-fi &&
-# make sure installwatch tracks it, the cat alone doesn't do that
-touch $SPECSDIR/specs &&
-cat $SPECSDIR/specs-local/* > $SPECSDIR/specs
+for file in usr/bin \
+ usr/lib/gcc \
+ usr/include \
+ usr/$libdir \
+ usr/libexec/gcc \
+ usr/share
+do
+ local dir=$(dirname $file)
+ local dest=$file
+ [[ -e /$dir ]] || mkdir -p /$dir
+ [[ -d /$file ]] && dest=$dir
+ cp -va $file /$dest
+done
diff --git a/gnu/gcc/PRE_BUILD b/gnu/gcc/PRE_BUILD
index 0b6e506..69eac77 100755
--- a/gnu/gcc/PRE_BUILD
+++ b/gnu/gcc/PRE_BUILD
@@ -1,5 +1,6 @@
default_pre_build &&
mk_source_dir $SOURCE_DIRECTORY.bld &&
+mk_source_dir $SOURCE_DIRECTORY.install &&
cd $SOURCE_DIRECTORY &&
# see http://gcc.gnu.org/bugzilla/show_bug.cgi?id=26539 for the rationale for
# the below
[SM-Commit] GIT changes to devel-gcc-parallel grimoire by David Brown (4782d404bd4d44b993944274e932c69033b2b0c2),
David Brown, 10/20/2007