Mercurial > hg > control-images
annotate images/lfs-bootstrap/download.sh @ 0:bcd2e358d57f
Start by copying the existing control image building infrastructure from Aboriginal Linux, and shuffling the layout around a bit.
author | Rob Landley <rob@landley.net> |
---|---|
date | Sun, 03 Jul 2011 17:23:26 -0500 |
parents | |
children | 0bdce741ba83 |
rev | line source |
---|---|
0
bcd2e358d57f
Start by copying the existing control image building infrastructure from Aboriginal Linux, and shuffling the layout around a bit.
Rob Landley <rob@landley.net>
parents:
diff
changeset
|
1 # Build Linux From Scratch 6.7 packages under target environment. |
bcd2e358d57f
Start by copying the existing control image building infrastructure from Aboriginal Linux, and shuffling the layout around a bit.
Rob Landley <rob@landley.net>
parents:
diff
changeset
|
2 |
bcd2e358d57f
Start by copying the existing control image building infrastructure from Aboriginal Linux, and shuffling the layout around a bit.
Rob Landley <rob@landley.net>
parents:
diff
changeset
|
3 # Note: this doesn't rebuild the toolchain packages (libc, binutils, |
bcd2e358d57f
Start by copying the existing control image building infrastructure from Aboriginal Linux, and shuffling the layout around a bit.
Rob Landley <rob@landley.net>
parents:
diff
changeset
|
4 # gcc, linux-headers), but reuses the toolchain we've got, because: |
bcd2e358d57f
Start by copying the existing control image building infrastructure from Aboriginal Linux, and shuffling the layout around a bit.
Rob Landley <rob@landley.net>
parents:
diff
changeset
|
5 |
bcd2e358d57f
Start by copying the existing control image building infrastructure from Aboriginal Linux, and shuffling the layout around a bit.
Rob Landley <rob@landley.net>
parents:
diff
changeset
|
6 # 1) Building a new toolchain is a target-dependent can of worms. |
bcd2e358d57f
Start by copying the existing control image building infrastructure from Aboriginal Linux, and shuffling the layout around a bit.
Rob Landley <rob@landley.net>
parents:
diff
changeset
|
7 # 2) Doing so would lose distcc acceleration. |
bcd2e358d57f
Start by copying the existing control image building infrastructure from Aboriginal Linux, and shuffling the layout around a bit.
Rob Landley <rob@landley.net>
parents:
diff
changeset
|
8 # 3) Building glibc under uClibc is buggy because glibc expects that a |
bcd2e358d57f
Start by copying the existing control image building infrastructure from Aboriginal Linux, and shuffling the layout around a bit.
Rob Landley <rob@landley.net>
parents:
diff
changeset
|
9 # 2.6 kernel will have TLS, and uClibc without NPTL doesn't. (Yes, |
bcd2e358d57f
Start by copying the existing control image building infrastructure from Aboriginal Linux, and shuffling the layout around a bit.
Rob Landley <rob@landley.net>
parents:
diff
changeset
|
10 # repeat after me, "autoconf is useless".) |
bcd2e358d57f
Start by copying the existing control image building infrastructure from Aboriginal Linux, and shuffling the layout around a bit.
Rob Landley <rob@landley.net>
parents:
diff
changeset
|
11 |
bcd2e358d57f
Start by copying the existing control image building infrastructure from Aboriginal Linux, and shuffling the layout around a bit.
Rob Landley <rob@landley.net>
parents:
diff
changeset
|
12 # Download upstream tarball |
bcd2e358d57f
Start by copying the existing control image building infrastructure from Aboriginal Linux, and shuffling the layout around a bit.
Rob Landley <rob@landley.net>
parents:
diff
changeset
|
13 |
bcd2e358d57f
Start by copying the existing control image building infrastructure from Aboriginal Linux, and shuffling the layout around a bit.
Rob Landley <rob@landley.net>
parents:
diff
changeset
|
14 URL=http://ftp.osuosl.org/pub/lfs/lfs-packages/lfs-packages-6.7.tar \ |
bcd2e358d57f
Start by copying the existing control image building infrastructure from Aboriginal Linux, and shuffling the layout around a bit.
Rob Landley <rob@landley.net>
parents:
diff
changeset
|
15 SHA1=9bda969efdfd4d51bda8fafeff082f2397249876 \ |
bcd2e358d57f
Start by copying the existing control image building infrastructure from Aboriginal Linux, and shuffling the layout around a bit.
Rob Landley <rob@landley.net>
parents:
diff
changeset
|
16 RENAME='s/-sources//' \ |
bcd2e358d57f
Start by copying the existing control image building infrastructure from Aboriginal Linux, and shuffling the layout around a bit.
Rob Landley <rob@landley.net>
parents:
diff
changeset
|
17 download || dienow |
bcd2e358d57f
Start by copying the existing control image building infrastructure from Aboriginal Linux, and shuffling the layout around a bit.
Rob Landley <rob@landley.net>
parents:
diff
changeset
|
18 |
bcd2e358d57f
Start by copying the existing control image building infrastructure from Aboriginal Linux, and shuffling the layout around a bit.
Rob Landley <rob@landley.net>
parents:
diff
changeset
|
19 URL=ftp://penma.de/code/gettext-stub/gettext-stub-1.tar.gz \ |
bcd2e358d57f
Start by copying the existing control image building infrastructure from Aboriginal Linux, and shuffling the layout around a bit.
Rob Landley <rob@landley.net>
parents:
diff
changeset
|
20 SHA1=ef706667010893c5492173c543d2c5b715abb8a7 \ |
bcd2e358d57f
Start by copying the existing control image building infrastructure from Aboriginal Linux, and shuffling the layout around a bit.
Rob Landley <rob@landley.net>
parents:
diff
changeset
|
21 download || dienow |
bcd2e358d57f
Start by copying the existing control image building infrastructure from Aboriginal Linux, and shuffling the layout around a bit.
Rob Landley <rob@landley.net>
parents:
diff
changeset
|
22 |
bcd2e358d57f
Start by copying the existing control image building infrastructure from Aboriginal Linux, and shuffling the layout around a bit.
Rob Landley <rob@landley.net>
parents:
diff
changeset
|
23 cleanup_oldfiles |
bcd2e358d57f
Start by copying the existing control image building infrastructure from Aboriginal Linux, and shuffling the layout around a bit.
Rob Landley <rob@landley.net>
parents:
diff
changeset
|
24 |
bcd2e358d57f
Start by copying the existing control image building infrastructure from Aboriginal Linux, and shuffling the layout around a bit.
Rob Landley <rob@landley.net>
parents:
diff
changeset
|
25 # Extract the individual packages from the upstream tarball |
bcd2e358d57f
Start by copying the existing control image building infrastructure from Aboriginal Linux, and shuffling the layout around a bit.
Rob Landley <rob@landley.net>
parents:
diff
changeset
|
26 |
bcd2e358d57f
Start by copying the existing control image building infrastructure from Aboriginal Linux, and shuffling the layout around a bit.
Rob Landley <rob@landley.net>
parents:
diff
changeset
|
27 SRCDIR="$SRCTREE/lfs-packages" |
bcd2e358d57f
Start by copying the existing control image building infrastructure from Aboriginal Linux, and shuffling the layout around a bit.
Rob Landley <rob@landley.net>
parents:
diff
changeset
|
28 PATCHDIR="$SRCDIR" |
bcd2e358d57f
Start by copying the existing control image building infrastructure from Aboriginal Linux, and shuffling the layout around a bit.
Rob Landley <rob@landley.net>
parents:
diff
changeset
|
29 |
bcd2e358d57f
Start by copying the existing control image building infrastructure from Aboriginal Linux, and shuffling the layout around a bit.
Rob Landley <rob@landley.net>
parents:
diff
changeset
|
30 # Fixups for tarball names the Aboriginal extract scripts can't parse |
bcd2e358d57f
Start by copying the existing control image building infrastructure from Aboriginal Linux, and shuffling the layout around a bit.
Rob Landley <rob@landley.net>
parents:
diff
changeset
|
31 |
bcd2e358d57f
Start by copying the existing control image building infrastructure from Aboriginal Linux, and shuffling the layout around a bit.
Rob Landley <rob@landley.net>
parents:
diff
changeset
|
32 mv "$SRCDIR"/sysvinit-2.88{dsf,}.tar.bz2 && |
bcd2e358d57f
Start by copying the existing control image building infrastructure from Aboriginal Linux, and shuffling the layout around a bit.
Rob Landley <rob@landley.net>
parents:
diff
changeset
|
33 mv "$SRCDIR"/tcl{8.5.8-src,-src-8.5.8}.tar.gz && |
bcd2e358d57f
Start by copying the existing control image building infrastructure from Aboriginal Linux, and shuffling the layout around a bit.
Rob Landley <rob@landley.net>
parents:
diff
changeset
|
34 mv "$SRCDIR"/udev-{161-testfiles,testfiles-161}.tar.bz2 || exit 1 |
bcd2e358d57f
Start by copying the existing control image building infrastructure from Aboriginal Linux, and shuffling the layout around a bit.
Rob Landley <rob@landley.net>
parents:
diff
changeset
|
35 |
bcd2e358d57f
Start by copying the existing control image building infrastructure from Aboriginal Linux, and shuffling the layout around a bit.
Rob Landley <rob@landley.net>
parents:
diff
changeset
|
36 # Remove damaged patches (whitespace damaged, don't apply without "fuzz"). |
bcd2e358d57f
Start by copying the existing control image building infrastructure from Aboriginal Linux, and shuffling the layout around a bit.
Rob Landley <rob@landley.net>
parents:
diff
changeset
|
37 |
bcd2e358d57f
Start by copying the existing control image building infrastructure from Aboriginal Linux, and shuffling the layout around a bit.
Rob Landley <rob@landley.net>
parents:
diff
changeset
|
38 rm "$SRCDIR"/gcc-4.5.1-startfiles_fix-1.patch && |
bcd2e358d57f
Start by copying the existing control image building infrastructure from Aboriginal Linux, and shuffling the layout around a bit.
Rob Landley <rob@landley.net>
parents:
diff
changeset
|
39 rm "$SRCDIR"/tar-1.23-overflow_fix-1.patch || exit 1 |
bcd2e358d57f
Start by copying the existing control image building infrastructure from Aboriginal Linux, and shuffling the layout around a bit.
Rob Landley <rob@landley.net>
parents:
diff
changeset
|
40 |
bcd2e358d57f
Start by copying the existing control image building infrastructure from Aboriginal Linux, and shuffling the layout around a bit.
Rob Landley <rob@landley.net>
parents:
diff
changeset
|
41 # Break down upstream tarball |
bcd2e358d57f
Start by copying the existing control image building infrastructure from Aboriginal Linux, and shuffling the layout around a bit.
Rob Landley <rob@landley.net>
parents:
diff
changeset
|
42 |
bcd2e358d57f
Start by copying the existing control image building infrastructure from Aboriginal Linux, and shuffling the layout around a bit.
Rob Landley <rob@landley.net>
parents:
diff
changeset
|
43 for i in $(cd "$SRCDIR"; ls *.tar.*) |
bcd2e358d57f
Start by copying the existing control image building infrastructure from Aboriginal Linux, and shuffling the layout around a bit.
Rob Landley <rob@landley.net>
parents:
diff
changeset
|
44 do |
bcd2e358d57f
Start by copying the existing control image building infrastructure from Aboriginal Linux, and shuffling the layout around a bit.
Rob Landley <rob@landley.net>
parents:
diff
changeset
|
45 extract_package $(noversion $i) |
bcd2e358d57f
Start by copying the existing control image building infrastructure from Aboriginal Linux, and shuffling the layout around a bit.
Rob Landley <rob@landley.net>
parents:
diff
changeset
|
46 done |
bcd2e358d57f
Start by copying the existing control image building infrastructure from Aboriginal Linux, and shuffling the layout around a bit.
Rob Landley <rob@landley.net>
parents:
diff
changeset
|
47 |
bcd2e358d57f
Start by copying the existing control image building infrastructure from Aboriginal Linux, and shuffling the layout around a bit.
Rob Landley <rob@landley.net>
parents:
diff
changeset
|
48 rm -rf "$SRCDIR" |