Merge trunk r3712

This commit is contained in:
Pierre Labastie 2013-09-14 10:31:49 +00:00
parent f62e4c5591
commit 27c5769103
3 changed files with 44 additions and 22 deletions

View file

@ -16,20 +16,30 @@ get_book() { #
case $PROGNAME in
lfs) svn_root="LFS" ;;
hlfs) svn_root="HLFS" ;;
clfs) svn_root="cross-lfs" ;;
clfs2) svn_root="cross-lfs" ;;
clfs3) svn_root="cross-lfs" ;;
clfs*) svn_root="cross-lfs" ;;
*) echo "BOOK not defined in function <get_book>"
exit 1 ;;
esac
# Grab a fresh book if it's missing, otherwise, update it from the
# repo. If we've already extracted the commands, move on to getting the
# sources.
if ! [ -d ${PROGNAME}-$LFSVRS ] || ! [ -d ${PROGNAME}-$LFSVRS/.svn ]; then
if [ $PROGNAME == "lfs" ] || [ $PROGNAME == "hlfs" ] && [ ! -d ${PROGNAME}-${LFSVRS}/.svn ]; then
svn co $SVN/${svn_root}/${TREE} ${PROGNAME}-$LFSVRS >>$LOGDIR/$LOG 2>&1
elif [ $PROGNAME == "clfs" ] || [ $PROGNAME == "clfs2" ] || [ $PROGNAME == "clfs3" ] && [ ! -d ${PROGNAME}-${LFSVRS}/.git ]; then
echo $TREE
git clone $GIT ${PROGNAME}-$LFSVRS >>$LOGDIR/$LOG 2>&1
if [ ! $TREE == "development" ]; then
cd ${PROGNAME}-$LFSVRS
echo "Checking out $LFSVRS at $PWD in $TREE"
git checkout ${TREE} >>$LOGDIR/$LOG 2>&1
fi
else
cd ${PROGNAME}-$LFSVRS
svn up >>$LOGDIR/$LOG 2>&1
case $PROGNAME in
clfs*) git pull >>$LOGDIR/$LOG 2>&1 ;;
lfs | hlfs) svn up >>$LOGDIR/$LOG 2>&1 ;;
*) ;;
esac
fi
echo -ne "done\n"
@ -48,8 +58,8 @@ extract_commands() { #
cd $JHALFSDIR
case $PROGNAME in
clfs | clfs2 | clfs3 )
VERSION=$(xmllint --noent $BOOK/prologue/$ARCH/bookinfo.xml 2>/dev/null | grep subtitle | sed -e 's/^.*ion //' -e 's/<\/.*//') ;;
clfs*)
VERSION=$(xmllint --noent BOOK/prologue/$ARCH/bookinfo.xml 2>/dev/null | grep subtitle | sed -e 's/^.*ion //' -e 's/<\/.*//') ;;
*)
VERSION=$(xmllint --noent $BOOK/prologue/bookinfo.xml 2>/dev/null | grep subtitle | sed -e 's/^.*ion //' -e 's/<\/.*//') ;;
esac
@ -75,7 +85,7 @@ extract_commands() { #
--stringparam page $PAGE \
--stringparam lang $LANG \
--stringparam sparc $SPARC64_PROC \
-o ./${PROGNAME}-commands/ $XSL $BOOK/$ARCH-index.xml >>$LOGDIR/$LOG 2>&1
-o ./${PROGNAME}-commands/ $XSL $BOOK/BOOK/$ARCH-index.xml >>$LOGDIR/$LOG 2>&1
;;
clfs2)
@ -86,7 +96,7 @@ extract_commands() { #
--stringparam timezone $TIMEZONE \
--stringparam page $PAGE \
--stringparam lang $LANG \
-o ./${PROGNAME}-commands/ $XSL $BOOK/$ARCH-index.xml >>$LOGDIR/$LOG 2>&1
-o ./${PROGNAME}-commands/ $XSL $BOOK/BOOK/$ARCH-index.xml >>$LOGDIR/$LOG 2>&1
;;
clfs3)
@ -97,7 +107,7 @@ extract_commands() { #
--stringparam timezone $TIMEZONE \
--stringparam page $PAGE \
--stringparam lang $LANG \
-o ./${PROGNAME}-commands/ $XSL $BOOK/$ARCH-index.xml >>$LOGDIR/$LOG 2>&1
-o ./${PROGNAME}-commands/ $XSL $BOOK/BOOK/$ARCH-index.xml >>$LOGDIR/$LOG 2>&1
;;
hlfs)
@ -161,9 +171,9 @@ create_package_list() { #
if [ ! -z $ARCH ] ; then echo -n " $ARCH" ; fi
echo -n "... "
case ${PROGNAME} in
clfs | clfs2 | clfs3 )
clfs*)
xsltproc --nonet --xinclude -o pkg_tarball_list packages.xsl \
$BOOK/materials/${ARCH}-chapter.xml >>$LOGDIR/$LOG 2>&1
$BOOK/BOOK/materials/${ARCH}-chapter.xml >>$LOGDIR/$LOG 2>&1
;;
hlfs)
xsltproc --nonet --xinclude \
@ -178,6 +188,7 @@ create_package_list() { #
-o pkg_tarball_list packages.xsl \
$BOOK/chapter03/chapter03.xml >>$LOGDIR/$LOG 2>&1
;;
*)
esac
if [[ "${BLFS_TOOL}" = "y" ]] ; then

View file

@ -89,7 +89,12 @@ check_prerequisites() { #
#----------------------------#
# Maybe we should check xsltproc first?
eval $(xsltproc $COMMON_DIR/hostreqs.xsl $BOOK/prologue/hostreqs.xml)
case $PROGNAME in
clfs | clfs2 | clfs3) HOSTREQS="BOOK/prologue/common/hostreqs.xml" ;;
*) HOSTREQS="prologue/hostreqs.xml" ;;
esac
eval $(xsltproc $COMMON_DIR/hostreqs.xsl $BOOK/$HOSTREQS)
# Avoid translation of version strings
local LC_ALL=C
export LC_ALL

22
jhalfs
View file

@ -152,8 +152,7 @@ BRANCH_ID=${BRANCH_ID:=development}
case $BRANCH_ID in
development )
case $PROGNAME in
clfs2 ) TREE=branches/clfs-sysroot/BOOK ;;
clfs3 ) TREE=branches/clfs-embedded/BOOK ;;
clfs* ) TREE="" ;;
*) TREE=trunk/BOOK ;;
esac
LFSVRS=development
@ -178,10 +177,11 @@ case $BRANCH_ID in
LFSVRS=${BRANCH_ID}
TREE=tags/${BRANCH_ID}/BOOK
;;
clfs | clfs2 | clfs3)
clfs* )
LFSVRS=${BRANCH_ID}
TREE=tags/${BRANCH_ID}
TREE=tags/clfs-${BRANCH_ID}
;;
* )
esac
;;
esac
@ -193,8 +193,10 @@ BOOK=${BOOK:=$JHALFSDIR/$PROGNAME-$LFSVRS}
#--- Envars not sourced from configuration
case $PROGNAME in
# TODO: clfs is now on git
# clfs* ) declare -r SVN="http://svn.cross-lfs.org/svn/repos" ;;
* ) declare -r SVN="svn://svn.linuxfromscratch.org" ;;
clfs ) declare -r GIT="git://git.cross-lfs.org/cross-lfs" ;;
clfs2 ) declare -r GIT="git://git.cross-lfs.org/clfs-sysroot" ;;
clfs3 ) declare -r GIT="git://git.cross-lfs.org/clfs-embedded" ;;
*) declare -r SVN="svn://svn.linuxfromscratch.org" ;;
esac
declare -r LOG=000-masterscript.log
# Needed for fetching BLFS book sources when building CLFS
@ -321,7 +323,11 @@ if [[ "$REBUILD_MAKEFILE" = "n" ]] ; then
cp $COMMON_DIR/{makefile-functions,progress_bar.sh,packages.xsl} $JHALFSDIR/
#
# Fix the XSL book parser
sed 's,FAKEDIR,'$BOOK',' $PACKAGE_DIR/$XSL > $JHALFSDIR/${XSL}
case $PROGNAME in
clfs* ) sed 's,FAKEDIR,'${BOOK}/BOOK',' ${PACKAGE_DIR}/${XSL} > $JHALFSDIR/${XSL} ;;
lfs | hlfs ) sed 's,FAKEDIR,'$BOOK',' $PACKAGE_DIR/$XSL > $JHALFSDIR/${XSL} ;;
* ) ;;
esac
export XSL=$JHALFSDIR/${XSL}
#
@ -382,7 +388,7 @@ fi
# canonical book version
if [[ "$REBUILD_MAKEFILE" = "y" ]] ; then
case $PROGNAME in
clfs | clfs2 | clfs3 )
clfs* )
VERSION=$(xmllint --noent $JHALFSDIR/$BOOK/prologue/$ARCH/bookinfo.xml 2>/dev/null | grep subtitle | sed -e 's/^.*ion //' -e 's/<\/.*//') ;;
*)
VERSION=$(xmllint --noent $JHALFSDIR/$BOOK/prologue/bookinfo.xml 2>/dev/null | grep subtitle | sed -e 's/^.*ion //' -e 's/<\/.*//') ;;