# HG changeset patch
# User Rob Landley
# Date 1351644935 18000
# Node ID c3b91b70cc428a3a0e1b8626229604b1fbb28638
# Parent 125462a318c6b2e2c5d9be878f9fabb78d00373d
Remove USE_ALT option, I have a better idea (upcoming patch).
diff -r 125462a318c6 -r c3b91b70cc42 config
--- a/config Tue Oct 09 00:05:38 2012 -0500
+++ b/config Tue Oct 30 19:55:35 2012 -0500
@@ -81,13 +81,6 @@
# export NO_SANITIZE_ENVIRONMENT=1
-# Use alternative versions of these packages, using the ALT= URL in download.sh
-# to fetch an alt-$PACKAGE-0 tarball. (This is mostly used to test unstable
-# versions of packages out of source control systems. There are no checksums
-# or versioning performed on alt packages, it's all done by hand.)
-
-# export USE_ALT=uClibc,busybox,linux,binutils,make,gcc-core,gcc-g++
-
# Debugging option to leave source in build/temp-$ARCH after build.
# export NO_CLEANUP=1
diff -r 125462a318c6 -r c3b91b70cc42 download.sh
--- a/download.sh Tue Oct 09 00:05:38 2012 -0500
+++ b/download.sh Tue Oct 30 19:55:35 2012 -0500
@@ -23,12 +23,10 @@
URL=http://uclibc.org/downloads/uClibc-0.9.33.2.tar.bz2 \
SHA1=4d8d67d6754409bd10015d67d1ce7a04c0b001ba \
-ALT=http://uclibc.org/downloads/uClibc-snapshot.tar.bz2 \
maybe_fork "download || dienow"
URL=http://www.kernel.org/pub/linux/kernel/v3.x/linux-3.6.tar.bz2 \
SHA1=9beb98fddbd7246381b1dbb08cd9a170f03fd67b \
-ALT=http://kernel.org/pub/linux/kernel/v3.0/testing/linux-3.0-rc1.tar.bz2 \
maybe_fork "download || dienow"
@@ -45,14 +43,12 @@
URL=ftp://ftp.gnu.org/gnu/gcc/gcc-4.2.1/gcc-core-4.2.1.tar.bz2 \
SHA1=43a138779e053a864bd16dfabcd3ffff04103213 \
-#ALT=ftp://ftp.gnu.org/gnu/gcc/gcc-4.4.1/gcc-core-4.4.1.tar.bz2 \
maybe_fork "download || dienow"
# The g++ version must match gcc version.
URL=http://ftp.gnu.org/gnu/gcc/gcc-4.2.1/gcc-g++-4.2.1.tar.bz2 \
SHA1=8f3785bd0e092f563e14ecd26921cd04275496a6 \
-#ALT=http://ftp.gnu.org/gnu/gcc/gcc-4.4.1/gcc-g++-4.4.1.tar.bz2 \
maybe_fork "download || dienow"
# Building a native root filesystem requires linux and uClibc (above) plus
@@ -65,7 +61,6 @@
URL=http://www.busybox.net/downloads/busybox-1.20.2.tar.bz2 \
SHA1=dd2e3684b13c0071d480e97b569041e69538e798 \
-#ALT=http://busybox.net/downloads/busybox-snapshot.tar.bz2 \
maybe_fork "download || dienow"
URL=ftp://ftp.gnu.org/gnu/make/make-3.81.tar.bz2 \
@@ -119,8 +114,8 @@
# Create a MANIFEST file listing package versions.
-# This can optionally call source control systems (hg and svn) to get version
-# information for the build scripts and any USE_ALT packages. These
+# This can optionally call source control systems (git, hg and svn) to get
+# version information for the packages and build scripts. These
# are intentionally excluded from the new path setup by host-tools.sh, so
# just in case we've already run that use $OLDPATH for this.
diff -r 125462a318c6 -r c3b91b70cc42 host-tools.sh
--- a/host-tools.sh Tue Oct 09 00:05:38 2012 -0500
+++ b/host-tools.sh Tue Oct 30 19:55:35 2012 -0500
@@ -190,7 +190,7 @@
cleanup
fi
-# Squashfs is an alternate packaging option.
+# Squashfs is the default packaging option.
if [ ! -f "${STAGE_DIR}"/mksquashfs ] &&
([ -z "$SYSIMAGE_TYPE" ] || [ "$SYSIMAGE_TYPE" == squashfs ])
diff -r 125462a318c6 -r c3b91b70cc42 more/alt-patches.sh
--- a/more/alt-patches.sh Tue Oct 09 00:05:38 2012 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,21 +0,0 @@
-#!/bin/bash
-
-# Setup alt-$PACKAGE-*.patch symlinks for a package
-
-if [ $# -eq 0 ]
-then
- echo "usage: more/alt-patches.sh PACKAGE"
- exit 1
-fi
-
-# Remove existing symlinks, but keep files
-
-for i in sources/patches/alt-$1-*.patch
-do
- [ -L $i ] && rm $i
-done
-
-for i in $(cd sources/patches; ls $1-*.patch)
-do
- ln -s $i sources/patches/alt-$i
-done
diff -r 125462a318c6 -r c3b91b70cc42 sources/README
--- a/sources/README Tue Oct 09 00:05:38 2012 -0500
+++ b/sources/README Tue Oct 30 19:55:35 2012 -0500
@@ -30,8 +30,7 @@
This is duplicate code factored out into a common location.
patches: Patches applied to the packages listed in download.sh by "setupfor".
- Each package has "$PACKAGE-*.patch" applied in alphabetical order,
- or "alt-$PACKAGE-*.patch" for USE_ALT versions.
+ Each package has "$PACKAGE-*.patch" applied in alphabetical order.
targets: Configuration for each target platform, parsed by load_target()
and getconfig() in functions.sh. Each entry is a target name,
@@ -41,12 +40,8 @@
settings: Environment variables needed by the build.
miniconfig-linux: linux kernel .config compressed by toys/miniconfig.sh
- (If miniconfig-alt-linux exists, USE_ALT=linux
- will use that instead.)
miniconfig-uClibc: uClibc .config compressed by toys/miniconfig.sh
- (If miniconfig-alt-uClibc exists, USE_ALT=uClibc
- will use that instead.)
root-filesystem: Files to be copied verbatim into the target filesystem.
Used by simple-root-filesystem.sh.
diff -r 125462a318c6 -r c3b91b70cc42 sources/download_functions.sh
--- a/sources/download_functions.sh Tue Oct 09 00:05:38 2012 -0500
+++ b/sources/download_functions.sh Tue Oct 30 19:55:35 2012 -0500
@@ -57,10 +57,7 @@
{
mkdir -p "$SRCTREE" || dienow
- # Figure out whether we're using an alternative version of a package.
-
PACKAGE="$1"
- is_in_list "$PACKAGE" $USE_ALT && PACKAGE=alt-"$PACKAGE"
# Announce to the world that we're cracking open a new package
@@ -193,7 +190,6 @@
{
FILENAME=`echo "$URL" | sed 's .*/ '`
[ -z "$RENAME" ] || FILENAME="$(echo "$FILENAME" | sed -r "$RENAME")"
- ALTFILENAME=alt-"$(noversion "$FILENAME" -0)"
if [ -z "$(sha1sum < /dev/null)" ]
then
@@ -203,37 +199,13 @@
echo -ne "checking $FILENAME\r"
- # Update timestamps on both stable and alternative tarballs (if any)
- # so cleanup_oldfiles doesn't delete stable when we're building alt
- # or vice versa
+ # Update timestamp on tarball (if it exists) so cleanup_oldfiles keeps it
- touch -c "$SRCDIR"/{"$FILENAME","$ALTFILENAME"} 2>/dev/null
+ touch -c "$SRCDIR"/"$FILENAME" 2>/dev/null
# Give package name, minus file's version number and archive extension.
BASENAME="$(noversion "$FILENAME")"
- # If alternative version selected, try from listed location, and fall back
- # to PREFERRED_MIRROR. Do not try normal mirror locations for alt packages.
-
- if is_in_list "$BASENAME" $USE_ALT
- then
- # If extracted source directory exists, don't download alt-tarball.
- if [ -e "$SRCTREE/alt-$BASENAME" ]
- then
- echo "Using $SRCTREE/alt-$BASENAME"
- return 0
- fi
-
- # Download new one as alt-packagename.tar.ext
- FILENAME="$ALTFILENAME"
- SHA1=
-
- ([ ! -z "$PREFERRED_MIRROR" ] &&
- download_from "$PREFERRED_MIRROR/$ALTFILENAME") ||
- download_from "$ALT"
- return $?
- fi
-
# If environment variable specifies a preferred mirror, try that first.
if [ ! -z "$PREFERRED_MIRROR" ]
diff -r 125462a318c6 -r c3b91b70cc42 sources/functions.sh
--- a/sources/functions.sh Tue Oct 09 00:05:38 2012 -0500
+++ b/sources/functions.sh Tue Oct 30 19:55:35 2012 -0500
@@ -106,8 +106,7 @@
getconfig()
{
- for i in $(is_in_list $1 $USE_ALT && echo {$ARCH_NAME,$ARCH}/miniconfig-alt-$1) \
- {$ARCH_NAME,$ARCH}/miniconfig-$1
+ for i in {$ARCH_NAME,$ARCH}/miniconfig-$1
do
[ -f "$CONFIG_DIR/$i" ] && cat "$CONFIG_DIR/$i" && return
done
@@ -250,42 +249,20 @@
identify_release()
{
- if is_in_list "$1" $USE_ALT
+ DIR="$SRCDIR/$1"
+ if [ -d "$DIR" ]
then
- for i in "b" ""
- do
- FILE="$(echo "$SRCDIR/alt-$1-"*.tar.$i*)"
- if [ -f "$FILE" ]
- then
- GITID="$(${i}zcat "$FILE" 2> /dev/null | git get-tar-commit-id 2>/dev/null)"
- if [ ! -z "$GITID" ]
- then
- # The first dozen chars should form a unique id.
-
- echo $GITID | sed 's/^\(................\).*/git \1/'
- return
- fi
- fi
- done
+ (
+ cd "$DIR" || dienow
+ ID="$(git show --pretty=oneline | cut -b 1-16)"
+ [ ! -z "$ID" ] && echo git "$ID" && return
- # Need to extract alt packages to determine source control version.
-
- extract_package "$1" >&2
- DIR="${BUILD}/packages/alt-$1"
+ ID="$(hg identify -n)"
+ [ ! -z "$ID" ] && echo hg "$ID" && return
- if [ -d "$DIR/.svn" ]
- then
- ( cd "$DIR"; echo subversion rev \
- $(svn info | sed -n "s/^Revision: //p")
- )
- return 0
- elif [ -d "$DIR/.hg" ]
- then
- ( echo mercurial rev \
- $(hg tip | sed -n 's/changeset: *\([0-9]*\).*/\1/p')
- )
- return 0
- fi
+ ID="$(svn info | sed -n "s/^Revision: //p")"
+ [ ! -z "$ID" ] && echo svn "$ID" && return
+ )
fi
echo release version $(get_download_version $1)
diff -r 125462a318c6 -r c3b91b70cc42 www/FAQ.html
--- a/www/FAQ.html Tue Oct 09 00:05:38 2012 -0500
+++ b/www/FAQ.html Tue Oct 30 19:55:35 2012 -0500
@@ -403,9 +403,7 @@
source directory, and when it doesn't find one it extracts the source tarballs
from the "packages" directory, applies the appropriate patches from
"sources/patches/$PACKAGENAME-*.patch", and saves the results into its own
-directory (named after the package) under "build/packages". (USE_UNSTABLE
-packages work the same way, but insert an "alt-" prefix on the package
-name.)
+directory (named after the package) under "build/packages".
When the package cache has an existing copy of the package, extract_package
checks the list of sha1sums in that copy's "sha1-for-source.txt" file against
@@ -756,7 +754,7 @@
the new system() syscall as appropriate, resulting in an -ENOSYS error
on older kernels that doesn't implement the new system call.
-You can use the alternate package mechanism to build against an older
+
You can run the build against an older
kernel (such as 2.6.35) and then run ./native-build.sh static-tools.hdc in
the resulting system-image-powerpc to get dropbearmulti and busybox binaries
that restrict themselves to the old system calls.