annotate sources/native-builds/gentoo-bootstrap/build/portage-build @ 1252:ba951c11fb48

Refactor the gentoo bootstrap build some more. Add "build" and "files" subdirectories, split each package build into a separate file, break out reusable shell functions into functions.sh. Flow control now init chrooting into run-build-stages.sh calling the individual package scripts.
author Rob Landley <rob@landley.net>
date Sat, 25 Sep 2010 13:40:04 -0500
parents
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
1252
ba951c11fb48 Refactor the gentoo bootstrap build some more. Add "build" and "files" subdirectories, split each package build into a separate file, break out reusable shell functions into functions.sh. Flow control now init chrooting into run-build-stages.sh calling the individual package scripts.
Rob Landley <rob@landley.net>
parents:
diff changeset
1 #!/bin/sh
ba951c11fb48 Refactor the gentoo bootstrap build some more. Add "build" and "files" subdirectories, split each package build into a separate file, break out reusable shell functions into functions.sh. Flow control now init chrooting into run-build-stages.sh calling the individual package scripts.
Rob Landley <rob@landley.net>
parents:
diff changeset
2
ba951c11fb48 Refactor the gentoo bootstrap build some more. Add "build" and "files" subdirectories, split each package build into a separate file, break out reusable shell functions into functions.sh. Flow control now init chrooting into run-build-stages.sh calling the individual package scripts.
Rob Landley <rob@landley.net>
parents:
diff changeset
3 . /mnt/functions.sh
ba951c11fb48 Refactor the gentoo bootstrap build some more. Add "build" and "files" subdirectories, split each package build into a separate file, break out reusable shell functions into functions.sh. Flow control now init chrooting into run-build-stages.sh calling the individual package scripts.
Rob Landley <rob@landley.net>
parents:
diff changeset
4
ba951c11fb48 Refactor the gentoo bootstrap build some more. Add "build" and "files" subdirectories, split each package build into a separate file, break out reusable shell functions into functions.sh. Flow control now init chrooting into run-build-stages.sh calling the individual package scripts.
Rob Landley <rob@landley.net>
parents:
diff changeset
5 # Portage isn't really designed to be portable, so this script contains
ba951c11fb48 Refactor the gentoo bootstrap build some more. Add "build" and "files" subdirectories, split each package build into a separate file, break out reusable shell functions into functions.sh. Flow control now init chrooting into run-build-stages.sh calling the individual package scripts.
Rob Landley <rob@landley.net>
parents:
diff changeset
6 # the "make install" stage that portage really should have within itself.
ba951c11fb48 Refactor the gentoo bootstrap build some more. Add "build" and "files" subdirectories, split each package build into a separate file, break out reusable shell functions into functions.sh. Flow control now init chrooting into run-build-stages.sh calling the individual package scripts.
Rob Landley <rob@landley.net>
parents:
diff changeset
7
ba951c11fb48 Refactor the gentoo bootstrap build some more. Add "build" and "files" subdirectories, split each package build into a separate file, break out reusable shell functions into functions.sh. Flow control now init chrooting into run-build-stages.sh calling the individual package scripts.
Rob Landley <rob@landley.net>
parents:
diff changeset
8 set_titlebar "portage" && cd /mnt/portage &&
ba951c11fb48 Refactor the gentoo bootstrap build some more. Add "build" and "files" subdirectories, split each package build into a separate file, break out reusable shell functions into functions.sh. Flow control now init chrooting into run-build-stages.sh calling the individual package scripts.
Rob Landley <rob@landley.net>
parents:
diff changeset
9
ba951c11fb48 Refactor the gentoo bootstrap build some more. Add "build" and "files" subdirectories, split each package build into a separate file, break out reusable shell functions into functions.sh. Flow control now init chrooting into run-build-stages.sh calling the individual package scripts.
Rob Landley <rob@landley.net>
parents:
diff changeset
10 # Install portage user/group, and libraries.
ba951c11fb48 Refactor the gentoo bootstrap build some more. Add "build" and "files" subdirectories, split each package build into a separate file, break out reusable shell functions into functions.sh. Flow control now init chrooting into run-build-stages.sh calling the individual package scripts.
Rob Landley <rob@landley.net>
parents:
diff changeset
11
ba951c11fb48 Refactor the gentoo bootstrap build some more. Add "build" and "files" subdirectories, split each package build into a separate file, break out reusable shell functions into functions.sh. Flow control now init chrooting into run-build-stages.sh calling the individual package scripts.
Rob Landley <rob@landley.net>
parents:
diff changeset
12 echo portage:x:250:250:portage:/var/tmp/portage:/bin/false >> /etc/passwd &&
ba951c11fb48 Refactor the gentoo bootstrap build some more. Add "build" and "files" subdirectories, split each package build into a separate file, break out reusable shell functions into functions.sh. Flow control now init chrooting into run-build-stages.sh calling the individual package scripts.
Rob Landley <rob@landley.net>
parents:
diff changeset
13 echo portage::250:portage >> /etc/group &&
ba951c11fb48 Refactor the gentoo bootstrap build some more. Add "build" and "files" subdirectories, split each package build into a separate file, break out reusable shell functions into functions.sh. Flow control now init chrooting into run-build-stages.sh calling the individual package scripts.
Rob Landley <rob@landley.net>
parents:
diff changeset
14 mkdir -p /usr/lib/portage &&
ba951c11fb48 Refactor the gentoo bootstrap build some more. Add "build" and "files" subdirectories, split each package build into a separate file, break out reusable shell functions into functions.sh. Flow control now init chrooting into run-build-stages.sh calling the individual package scripts.
Rob Landley <rob@landley.net>
parents:
diff changeset
15 cp -a bin pym /usr/lib/portage/ &&
ba951c11fb48 Refactor the gentoo bootstrap build some more. Add "build" and "files" subdirectories, split each package build into a separate file, break out reusable shell functions into functions.sh. Flow control now init chrooting into run-build-stages.sh calling the individual package scripts.
Rob Landley <rob@landley.net>
parents:
diff changeset
16
ba951c11fb48 Refactor the gentoo bootstrap build some more. Add "build" and "files" subdirectories, split each package build into a separate file, break out reusable shell functions into functions.sh. Flow control now init chrooting into run-build-stages.sh calling the individual package scripts.
Rob Landley <rob@landley.net>
parents:
diff changeset
17 # Add portage python modules to the python search path.
ba951c11fb48 Refactor the gentoo bootstrap build some more. Add "build" and "files" subdirectories, split each package build into a separate file, break out reusable shell functions into functions.sh. Flow control now init chrooting into run-build-stages.sh calling the individual package scripts.
Rob Landley <rob@landley.net>
parents:
diff changeset
18
ba951c11fb48 Refactor the gentoo bootstrap build some more. Add "build" and "files" subdirectories, split each package build into a separate file, break out reusable shell functions into functions.sh. Flow control now init chrooting into run-build-stages.sh calling the individual package scripts.
Rob Landley <rob@landley.net>
parents:
diff changeset
19 echo /usr/lib/portage/pym > /usr/lib/python2.6/site-packages/gentoo.pth ||
ba951c11fb48 Refactor the gentoo bootstrap build some more. Add "build" and "files" subdirectories, split each package build into a separate file, break out reusable shell functions into functions.sh. Flow control now init chrooting into run-build-stages.sh calling the individual package scripts.
Rob Landley <rob@landley.net>
parents:
diff changeset
20 exit 1
ba951c11fb48 Refactor the gentoo bootstrap build some more. Add "build" and "files" subdirectories, split each package build into a separate file, break out reusable shell functions into functions.sh. Flow control now init chrooting into run-build-stages.sh calling the individual package scripts.
Rob Landley <rob@landley.net>
parents:
diff changeset
21
ba951c11fb48 Refactor the gentoo bootstrap build some more. Add "build" and "files" subdirectories, split each package build into a separate file, break out reusable shell functions into functions.sh. Flow control now init chrooting into run-build-stages.sh calling the individual package scripts.
Rob Landley <rob@landley.net>
parents:
diff changeset
22 # Install portage binaries into bin and sbin
ba951c11fb48 Refactor the gentoo bootstrap build some more. Add "build" and "files" subdirectories, split each package build into a separate file, break out reusable shell functions into functions.sh. Flow control now init chrooting into run-build-stages.sh calling the individual package scripts.
Rob Landley <rob@landley.net>
parents:
diff changeset
23
ba951c11fb48 Refactor the gentoo bootstrap build some more. Add "build" and "files" subdirectories, split each package build into a separate file, break out reusable shell functions into functions.sh. Flow control now init chrooting into run-build-stages.sh calling the individual package scripts.
Rob Landley <rob@landley.net>
parents:
diff changeset
24 for i in archive-conf dispatch-conf emaint emerge-webrsync env-update \
ba951c11fb48 Refactor the gentoo bootstrap build some more. Add "build" and "files" subdirectories, split each package build into a separate file, break out reusable shell functions into functions.sh. Flow control now init chrooting into run-build-stages.sh calling the individual package scripts.
Rob Landley <rob@landley.net>
parents:
diff changeset
25 etc-update fixpackages quickpkg regenworld
ba951c11fb48 Refactor the gentoo bootstrap build some more. Add "build" and "files" subdirectories, split each package build into a separate file, break out reusable shell functions into functions.sh. Flow control now init chrooting into run-build-stages.sh calling the individual package scripts.
Rob Landley <rob@landley.net>
parents:
diff changeset
26 do
ba951c11fb48 Refactor the gentoo bootstrap build some more. Add "build" and "files" subdirectories, split each package build into a separate file, break out reusable shell functions into functions.sh. Flow control now init chrooting into run-build-stages.sh calling the individual package scripts.
Rob Landley <rob@landley.net>
parents:
diff changeset
27 ln /usr/lib/portage/bin/$i /usr/sbin/$i || exit 1
ba951c11fb48 Refactor the gentoo bootstrap build some more. Add "build" and "files" subdirectories, split each package build into a separate file, break out reusable shell functions into functions.sh. Flow control now init chrooting into run-build-stages.sh calling the individual package scripts.
Rob Landley <rob@landley.net>
parents:
diff changeset
28 done
ba951c11fb48 Refactor the gentoo bootstrap build some more. Add "build" and "files" subdirectories, split each package build into a separate file, break out reusable shell functions into functions.sh. Flow control now init chrooting into run-build-stages.sh calling the individual package scripts.
Rob Landley <rob@landley.net>
parents:
diff changeset
29
ba951c11fb48 Refactor the gentoo bootstrap build some more. Add "build" and "files" subdirectories, split each package build into a separate file, break out reusable shell functions into functions.sh. Flow control now init chrooting into run-build-stages.sh calling the individual package scripts.
Rob Landley <rob@landley.net>
parents:
diff changeset
30 for i in ebuild egencache emerge portageq repoman
ba951c11fb48 Refactor the gentoo bootstrap build some more. Add "build" and "files" subdirectories, split each package build into a separate file, break out reusable shell functions into functions.sh. Flow control now init chrooting into run-build-stages.sh calling the individual package scripts.
Rob Landley <rob@landley.net>
parents:
diff changeset
31 do
ba951c11fb48 Refactor the gentoo bootstrap build some more. Add "build" and "files" subdirectories, split each package build into a separate file, break out reusable shell functions into functions.sh. Flow control now init chrooting into run-build-stages.sh calling the individual package scripts.
Rob Landley <rob@landley.net>
parents:
diff changeset
32 ln /usr/lib/portage/bin/$i /usr/bin/$i || exit 1
ba951c11fb48 Refactor the gentoo bootstrap build some more. Add "build" and "files" subdirectories, split each package build into a separate file, break out reusable shell functions into functions.sh. Flow control now init chrooting into run-build-stages.sh calling the individual package scripts.
Rob Landley <rob@landley.net>
parents:
diff changeset
33 done
ba951c11fb48 Refactor the gentoo bootstrap build some more. Add "build" and "files" subdirectories, split each package build into a separate file, break out reusable shell functions into functions.sh. Flow control now init chrooting into run-build-stages.sh calling the individual package scripts.
Rob Landley <rob@landley.net>
parents:
diff changeset
34
ba951c11fb48 Refactor the gentoo bootstrap build some more. Add "build" and "files" subdirectories, split each package build into a separate file, break out reusable shell functions into functions.sh. Flow control now init chrooting into run-build-stages.sh calling the individual package scripts.
Rob Landley <rob@landley.net>
parents:
diff changeset
35 # Install portage man pages
ba951c11fb48 Refactor the gentoo bootstrap build some more. Add "build" and "files" subdirectories, split each package build into a separate file, break out reusable shell functions into functions.sh. Flow control now init chrooting into run-build-stages.sh calling the individual package scripts.
Rob Landley <rob@landley.net>
parents:
diff changeset
36
ba951c11fb48 Refactor the gentoo bootstrap build some more. Add "build" and "files" subdirectories, split each package build into a separate file, break out reusable shell functions into functions.sh. Flow control now init chrooting into run-build-stages.sh calling the individual package scripts.
Rob Landley <rob@landley.net>
parents:
diff changeset
37 cp cnf/make.globals /etc/ &&
ba951c11fb48 Refactor the gentoo bootstrap build some more. Add "build" and "files" subdirectories, split each package build into a separate file, break out reusable shell functions into functions.sh. Flow control now init chrooting into run-build-stages.sh calling the individual package scripts.
Rob Landley <rob@landley.net>
parents:
diff changeset
38 cp man/*.1 /usr/man/man1 &&
ba951c11fb48 Refactor the gentoo bootstrap build some more. Add "build" and "files" subdirectories, split each package build into a separate file, break out reusable shell functions into functions.sh. Flow control now init chrooting into run-build-stages.sh calling the individual package scripts.
Rob Landley <rob@landley.net>
parents:
diff changeset
39 cp man/*.5 /usr/man/man5 &&
ba951c11fb48 Refactor the gentoo bootstrap build some more. Add "build" and "files" subdirectories, split each package build into a separate file, break out reusable shell functions into functions.sh. Flow control now init chrooting into run-build-stages.sh calling the individual package scripts.
Rob Landley <rob@landley.net>
parents:
diff changeset
40
ba951c11fb48 Refactor the gentoo bootstrap build some more. Add "build" and "files" subdirectories, split each package build into a separate file, break out reusable shell functions into functions.sh. Flow control now init chrooting into run-build-stages.sh calling the individual package scripts.
Rob Landley <rob@landley.net>
parents:
diff changeset
41 mkdir -p /var/log /etc/portage/profile || exit 1