wok view slitaz-toolchain/receipt @ rev 9743
Fix: pam BUILD_DEPENDS
author | Christophe Lincoln <pankso@slitaz.org> |
---|---|
date | Tue May 10 02:34:00 2011 +0200 (2011-05-10) |
parents | 757a3f3c6bb1 |
children | dad9a35bd4f6 |
line source
1 # SliTaz package receipt.
3 PACKAGE="slitaz-toolchain"
4 VERSION="4.0"
5 CATEGORY="meta"
6 SHORT_DESC="SliTaz meta package to rebuild or install current toolchain."
7 MAINTAINER="pankso@slitaz.org"
8 WEB_SITE="http://www.slitaz.org/"
10 DEPENDS="binutils linux-api-headers glibc-dev gcc make elfkickers"
12 #
13 # The goal here is to build and install SliTaz toolchain. We build the toolchain
14 # from SliTaz packages, on SliTaz and for SliTaz so in case of new and important
15 # toolchain upgrade we must build Binutils a first time, then GCC so it use the
16 # new Binutils. After we cook Glibc and then rebuild Binutils + GCC a second
17 # time so they are linked with the new main GNU libc. We usually also due a
18 # bootstrap by recooking slitaz-toolchain a second time so we are sure it can
19 # rebuild itself.
20 #
21 # SliTaz does one big toolchain by year just after the stable release, any change
22 # here or in the toolchain packages version must be discuss on the mailing list.
23 #
25 # Rules to configure and make the package.
26 compile_rules()
27 {
28 [ -x /usr/bin/cook ] || exit 0
29 tmplog=$LOGS/$PACKAGE.tmplog
30 echo "Cook: $PACKAGE $VERSION" > $tmplog
31 separator >> $tmplog
32 echo "cook: started $(date '+%Y-%m-%d %H:%M')" >> $tmplog
34 # 1. binutils (first pass)
35 echo "cook: binutils first pass: $(date '+%Y-%m-%d %H:%M')" >> $tmplog
36 cook binutils --install
38 # 2. gcc (first pass)
39 echo "cook: GCC first pass: $(date '+%Y-%m-%d %H:%M')" >> $tmplog
40 cook gcc --install --first-pass
42 # 3. linux-api-headers
43 echo "cook: linux API headers: $(date '+%Y-%m-%d %H:%M')" >> $tmplog
44 cook linux-api-headers --install
46 # 4. glibc
47 for i in glibc glibc-base glibc-extra-samba glibc-locale glibc-dev
48 do
49 echo "cook: $i: $(date '+%Y-%m-%d %H:%M')" >> $tmplog
50 cook $i --install
51 done
53 # 5. binutils (final)
54 echo "cook: binutils final: $(date '+%Y-%m-%d %H:%M')" >> $tmplog
55 cook binutils --install
57 # 6. gcc (final)
58 echo "cook: GCC final: $(date '+%Y-%m-%d %H:%M')" >> $tmplog
59 cook gcc --install
61 # All packages cooked got ther own log so we dont keep them.
62 separator >> $tmplog && echo "" >> $tmplog
63 mv -f $tmplog $LOGS/$PACKAGE.log
64 }
66 # Rules to gen a SliTaz package suitable for Tazpkg.
67 genpkg_rules()
68 {
69 binutils=$(grep ^VERSION $WOK/binutils/receipt | cut -d '"' -f 2)
70 linux=$(grep ^VERSION $WOK/linux/receipt | cut -d '"' -f 2)
71 gcc=$(grep ^VERSION $WOK/linux/receipt | cut -d '"' -f 2)
72 glibc=$(grep ^VERSION $WOK/linux/receipt | cut -d '"' -f 2)
74 mkdir -p $fs/usr/share/doc/slitaz
75 cat > $fs/usr/share/doc/slitaz/toolchain.txt << EOT
76 SliTaz GNU/Linux toolchain
77 ================================================================================
78 Build date: $(date "+%Y-%m-%d")
79 Packages:
81 * Binutils $binutils
82 * Linux API headers $linux
83 * GCC $gcc
84 * Glibc $glibc
86 ================================================================================
88 EOT
89 }