From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) by finch.gentoo.org (Postfix) with ESMTP id 17D17138010 for ; Sun, 26 Aug 2012 19:50:56 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id E8808E0540; Sun, 26 Aug 2012 19:50:48 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) by pigeon.gentoo.org (Postfix) with ESMTP id A71F4E0540 for ; Sun, 26 Aug 2012 19:50:48 +0000 (UTC) Received: from flycatcher.gentoo.org (flycatcher.gentoo.org [81.93.255.6]) (using TLSv1 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id E3C7A33D83B for ; Sun, 26 Aug 2012 19:50:47 +0000 (UTC) Received: by flycatcher.gentoo.org (Postfix, from userid 984) id 99B332082D; Sun, 26 Aug 2012 19:50:46 +0000 (UTC) From: "Fabian Groffen (grobian)" To: gentoo-commits@lists.gentoo.org Reply-To: gentoo-dev@lists.gentoo.org, grobian@gentoo.org Subject: [gentoo-commits] gentoo commit in xml/htdocs/proj/en/gentoo-alt/prefix: bootstrap-solaris.xml X-VCS-Repository: gentoo X-VCS-Files: bootstrap-solaris.xml X-VCS-Directories: xml/htdocs/proj/en/gentoo-alt/prefix X-VCS-Committer: grobian X-VCS-Committer-Name: Fabian Groffen Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Message-Id: <20120826195046.99B332082D@flycatcher.gentoo.org> Date: Sun, 26 Aug 2012 19:50:46 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org X-Archives-Salt: cbe81524-588f-4110-965d-d8c0a4064ef4 X-Archives-Hash: bba64f3760720c48e3de674a8380b1ea grobian 12/08/26 19:50:46 Modified: bootstrap-solaris.xml Log: use stage{1,2,3} in bootstrap instructions Revision Changes Path 1.98 xml/htdocs/proj/en/gentoo-alt/prefix/bootstrap-solaris.xml file : http://sources.gentoo.org/viewvc.cgi/gentoo/xml/htdocs/proj/en/gentoo-alt/prefix/bootstrap-solaris.xml?rev=1.98&view=markup plain: http://sources.gentoo.org/viewvc.cgi/gentoo/xml/htdocs/proj/en/gentoo-alt/prefix/bootstrap-solaris.xml?rev=1.98&content-type=text/plain diff : http://sources.gentoo.org/viewvc.cgi/gentoo/xml/htdocs/proj/en/gentoo-alt/prefix/bootstrap-solaris.xml?r1=1.97&r2=1.98 Index: bootstrap-solaris.xml =================================================================== RCS file: /var/cvsroot/gentoo/xml/htdocs/proj/en/gentoo-alt/prefix/bootstrap-solaris.xml,v retrieving revision 1.97 retrieving revision 1.98 diff -u -r1.97 -r1.98 --- bootstrap-solaris.xml 11 Aug 2012 13:30:14 -0000 1.97 +++ bootstrap-solaris.xml 26 Aug 2012 19:50:46 -0000 1.98 @@ -1,6 +1,6 @@ - + Gentoo Prefix Bootstrap Process for UNIX-like systems @@ -19,8 +19,8 @@ - 1.67 - 2012-08-07 + 1.68 + 2012-08-26 Bootstrapping @@ -49,14 +49,18 @@ default, e.g. make sure your shell doesn't automatically load any environment variables that setup those repositories. Think of PATH, CFFLAGS, CFLAGS, - LDFLAGS and the always harmful LD_LIBRARY_PATH. + LDFLAGS, PKG_CONFIG_PATH and the always harmful + LD_LIBRARY_PATH. This is important, because Prefix tends to be very sensitive about this. Afterall, it's whole purpose is to provide all of those tools by itself without external help!

- If you happen to run into troubles, don't despair. Feel free - to ask in the gentoo-prefix IRC channel, or mailing list + If you happen to run into trouble, don't despair + (immediately). Feel free to ask in the gentoo-prefix + IRC channel, or gentoo-alt + mailing list.

IMPORTANT: Gentoo Prefix does NOT require root-privileges. @@ -173,190 +177,62 @@ From the directory where the bootstrap script was stored execute the following commands:

-
+        
 $ chmod 755 bootstrap-prefix.sh
-$ ./bootstrap-prefix.sh $EPREFIX/tmp make
-$ ./bootstrap-prefix.sh $EPREFIX/tmp wget
-$ ./bootstrap-prefix.sh $EPREFIX/tmp sed
-$ ./bootstrap-prefix.sh $EPREFIX/tmp m4
-$ ./bootstrap-prefix.sh $EPREFIX/tmp bison
-$ ./bootstrap-prefix.sh $EPREFIX/tmp coreutils
-$ ./bootstrap-prefix.sh $EPREFIX/tmp findutils
-$ ./bootstrap-prefix.sh $EPREFIX/tmp tar
-$ ./bootstrap-prefix.sh $EPREFIX/tmp patch
-$ ./bootstrap-prefix.sh $EPREFIX/tmp grep
-$ ./bootstrap-prefix.sh $EPREFIX/tmp gawk
-$ ./bootstrap-prefix.sh $EPREFIX/tmp bash
-$ ./bootstrap-prefix.sh $EPREFIX/tmp zlib
-$ ./bootstrap-prefix.sh $EPREFIX/tmp python
+$ ./bootstrap-prefix.sh $EPREFIX/tmp stage1
         
- Please note that all tools are installed in - $EPREFIX/tmp! + Please note the usage of $EPREFIX/tmp!

- Now that we have some minimal tools to run emerge, - let's setup the $EPREFIX - directory, download a Portage tree snapshot, unpack it and - download and install Portage. Afterwards the script will try - to setup some sane defaults, watch closely if it reported to - be successful in this. If it doesn't, your system is not yet - recognised, and manual intervention to continue is necessary. -

-
-$ ./bootstrap-prefix.sh $EPREFIX tree
-$ ./bootstrap-prefix.sh $EPREFIX portage
-        
-

- Because we installed some new applications, most notably - Portage, we will instruct bash to reconsider all paths we - have: + The stage1 should have installed some basic packages + necessary to run Portage, without Portage's help. When stage1 + finished successfully, a Portage can be installed.

-
-$ hash -r
-        
- - tcsh users can use the rehash command. -

- We continue adding some necessary tools which will slowly make - the just born Prefix less fragile. + The Portage tree installed by default is a known to be good + snapshot. This can, however, for various reasons not be + good enough, in which case the lastest snapshot available can + be used instead. Only use this when you have problems with + the known to be good snapshot. If you want to use the lastest + snapshot when bootstrapping, export LATEST_TREE_YES=1 in + your environment before running the following:

-
-$ emerge --oneshot sed
+        
+$ ./bootstrap-prefix.sh $EPREFIX stage2
         

- Next, we emerge the bash shell Portage heavily relies - on. + We continue with emerging some of the core toolchain packages + that make sure we compile and link everything taking the + Prefix into account. Next to that this step emerges the full + set of applications and that Portage needs and removes the + tools installed by stage1. It finishes things by getting an + up-to-date tree (removing any hacks stage2 applied to the + activated profile) and emerging everything in the + system set.

-
-$ emerge --oneshot --nodeps bash (avoid deps that install scripts with shebang /bin/sh)
-        
-

- Now, we will emerge a compiler which will use the gnu linker. - This is a requirement for many packages that follow in the - bootstrap process, in particular Perl. The packages to emerge - include the baselayout-prefix package. Some, if not - many, scripts and tools within a Gentoo system assume the - availability of the baselayout-prefix package for all - communication using the Gentoo colour scheme. -

-
-$ emerge --oneshot --nodeps sys-apps/baselayout-prefix
-$ emerge --oneshot --nodeps app-arch/xz-utils
-$ emerge --oneshot --nodeps sys-devel/m4
-$ emerge --oneshot --nodeps sys-devel/flex
-$ emerge --oneshot --nodeps sys-devel/bison
-$ emerge --oneshot --nodeps sys-devel/binutils-config
-$ emerge --oneshot --nodeps sys-devel/gcc-config
-        
-

- Non Mac OS X users can immediately continue here with the - toolchain, and skip the bit below about Xcode. - Mac OS X users need to skip this step, and perform the step - below instead. -

-
-$ emerge --oneshot --nodeps sys-devel/binutils
-$ emerge --oneshot --nodeps "=sys-devel/gcc-4.2*"
+        
+$ ./bootstrap-prefix.sh $EPREFIX stage3
         

- If you're not on Mac OS X, you can skip this step. - Due to different versions of Xcode, the following step - requires some close watch to the output of gcc - --version. If the first line reports a version - 4.2.1, the latest binutils-apple needs to be emerged, - otherwise, version should report 4.0.1 and - =binutils-apple-3.2 must be emerged. -

-
-$ emerge --oneshot --nodeps "=sys-devel/binutils-apple-3.2" (for gcc 4.0.1)
-$ emerge --oneshot --nodeps sys-devel/binutils-apple    (for gcc 4.2.1)
-$ emerge --oneshot --nodeps sys-devel/gcc-apple
-        
-

- We continue getting more tools in our Prefix. We no longer - ignore dependencies all the time, so a lot of packages will be - emerged at this stage. Slowly our Prefix gets more robust as - we progress here. -

-
-$ emerge --oneshot sys-apps/coreutils
-$ emerge --oneshot sys-apps/findutils
-$ emerge --oneshot '<app-arch/tar-1.26-r1'
-$ emerge --oneshot sys-apps/grep
-$ emerge --oneshot sys-devel/patch
-$ emerge --oneshot sys-apps/gawk
-$ emerge --oneshot sys-devel/make
-$ emerge --oneshot sys-libs/zlib
-$ emerge --oneshot --nodeps sys-apps/file
-$ emerge --oneshot --nodeps app-admin/eselect
-$ emerge --oneshot app-misc/pax-utils
-$ emerge --oneshot "<net-misc/wget-1.13.4-r1" (until we fix #393277)
-$ emerge --oneshot virtual/os-headers
-        
-

- Now we have a good bunch of programs that Portage needs, we - can replace the bootstrapped Portage by a properly installed - one, using Portage itself. Also here a few dependencies are - first emerged, such as the language Portage is written in: - python. We need to temporarily tell Portage that the - bootstrapped Portage can be overwritten. -

-
-$ env FEATURES="-collision-protect" emerge --oneshot sys-apps/portage
-        
-

- Now we have emerged everything we bootstrapped before, we - remove the temporary directory and its use as it is no longer - necessary. + Because we installed some new applications, most notably + Portage, we will instruct bash to reconsider all paths we + have:

-
-$ rm -Rf $EPREFIX/tmp/*
+        
 $ hash -r
         
-

- Before we do any further merges, we are going to update our - tree. Updating the tree is done using: -

-
-$ emerge --sync
-        
- If you're behind a firewall that blocks rsync traffic, you can - try to run ${EPREFIX}/usr/bin/emerge-webrsync instead. + tcsh users can use the rehash command.

- Before we can finish emerging the system set, we need to work - around a circular dependency of gcc on mpc, and - mpc on gcc. Since Mac OS X systems use - gcc-apple, this step is not necessary for them. - Mac OS X users should skip this step. -

-
-$ emerge --oneshot "<dev-libs/mpc-0.9"
-        
-

- Next, we let Portage emerge all packages that complete a - system install that we eventually need to finalise this Prefix - installation. -

-
-$ env USE=-git emerge -u system
-        
-

- Now is a good time to set the preferences for our soon to be - Prefix. This includes customisations such as general - USE-flags, CFLAGS and MAKEOPTS in + Now is a good time to set the preferences for your Prefix. + This includes customisations such as general USE-flags, + CFLAGS and MAKEOPTS in $EPREFIX/etc/portage/make.conf. Be conservative with - CFLAGS! Note that the code below is an example, and is - meant for inspiration only. + CFLAGS! The stage3 function already sed some moderate + defaults.

-
-$ echo 'USE="unicode nls"' >> $EPREFIX/etc/portage/make.conf
-$ echo 'CFLAGS="-O2 -pipe"' >> $EPREFIX/etc/portage/make.conf
-$ echo 'CXXFLAGS="${CFLAGS}"' >> $EPREFIX/etc/portage/make.conf
-        
You can consider adding CPU-specific tuning flags to CFLAGS. If you don't know what your CPU is, or what @@ -375,26 +251,6 @@ value breaks things.

- For non Mac OS X users, it is likely that you emerged a newer - GCC than the 4.2 version we used during the bootstrap. Since - we reinstall all packages, we like to take advantage of this - newer GCC. By default, this newer GCC will not be enabled. - Check the output of gcc-config -l, and make sure that - the newest compiler is selected (marked by an asterisk). - Another GCC can be selected by running gcc-config - <number>. -

-
-$ gcc-config -l
- [1] i386-pc-solaris2.10-4.2.4 *
- [2] i386-pc-solaris2.10-4.5.3
-$ gcc-config 2
- * Switching native-compiler to i386-pc-solaris2.10-4.5.3 ...
-$ gcc-config -l
- [1] i386-pc-solaris2.10-4.2.4
- [2] i386-pc-solaris2.10-4.5.3 *
-        
-

Since we have everything in place for a self-catered rebuild, we can start the final stage to install the Prefix system. This final stage recompiles everything in the system, but now