/[gentoo-projects]/bsd/fbsd/extract.sh
Gentoo

Contents of /bsd/fbsd/extract.sh

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.6 - (show annotations) (download) (as text)
Sun Apr 23 18:27:58 2006 UTC (8 years, 7 months ago) by flameeyes
Branch: MAIN
CVS Tags: HEAD
Changes since 1.5: +4 -3 lines
File MIME type: text/x-sh
Fix versioning.

1 #!/bin/bash
2
3 if [[ $# -lt 1 ]]; then
4 echo "You must specify the version of the packages to build."
5 exit 1
6 fi
7
8 # These are the base packages recognized by original script:
9 # base bin contrib crypto etc games gnu include krb5 lib libexec release
10 # rescue sbin secure share sys tools ubin usbin
11
12 if [[ -z $2 ]]; then
13 dists="bin contrib crypto gnu include lib libexec sbin share ubin usbin sys etc rescue"
14 else
15 dists="$2"
16 fi
17
18 MIRROR=${FTPMIRROR:-ftp.FreeBSD.org}
19 echo "Using mirror ${MIRROR}"
20
21 P=$1
22 MY_P=${P/_rc/-RC}
23 MY_P=${MY_P/_beta/-BETA}
24 echo "Getting version ${P} [${MY_P}].."
25 if [[ ${MY_P} == ${P} ]]; then
26 MY_P="${MY_P}-RELEASE"
27 fi
28
29 echo "Downloading files..."
30 wget -nv -c "ftp://${MIRROR}/pub/FreeBSD/releases/i386/${MY_P}/src/CHECKSUM.MD5"
31
32 sed -e 's:MD5 (\(.*\)) = \(.*\):\2 \1:' CHECKSUM.MD5 > MD5SUM
33
34 for i in $dists; do
35 wget -nv -c -t0 "ftp://${MIRROR}/pub/FreeBSD/releases/i386/${MY_P}/src/s$i*"
36 done
37 echo "Done downloading files."
38
39 echo "Repackaging files..."
40 for i in $dists; do
41 echo " Repackaging source component: $i"
42 cat s${i}.?? | zcat - | bzip2 - > freebsd-${i}-$P.tar.bz2
43 done
44 echo "Done repackaging sources."
45 exit 0

  ViewVC Help
Powered by ViewVC 1.1.20