Don't copy XSL files to $JHALFSDIR.
Removed the now unneeded packages.xsl code.
This commit is contained in:
parent
41d8577919
commit
f1f871c564
4 changed files with 10 additions and 122 deletions
|
@ -157,60 +157,7 @@ extract_commands() { #
|
||||||
# Make the scripts executable.
|
# Make the scripts executable.
|
||||||
chmod -R +x $JHALFSDIR/${PROGNAME}-commands
|
chmod -R +x $JHALFSDIR/${PROGNAME}-commands
|
||||||
|
|
||||||
# Create the packages file. We need it for proper Makefile creation
|
|
||||||
create_package_list
|
|
||||||
|
|
||||||
# Done. Moving on...
|
# Done. Moving on...
|
||||||
get_sources
|
get_sources
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
#----------------------------#
|
|
||||||
create_package_list() { #
|
|
||||||
#----------------------------#
|
|
||||||
|
|
||||||
# Create the packages file. We need it for proper Makefile creation
|
|
||||||
rm -f pkg_tarball_list
|
|
||||||
echo -n "Creating <${PROGNAME}> list of tarball names for $BOOK"
|
|
||||||
if [ ! -z $ARCH ] ; then echo -n " $ARCH" ; fi
|
|
||||||
echo -n "... "
|
|
||||||
case ${PROGNAME} in
|
|
||||||
clfs | clfs2 | clfs3 )
|
|
||||||
xsltproc --nonet --xinclude -o pkg_tarball_list packages.xsl \
|
|
||||||
$BOOK/materials/${ARCH}-chapter.xml >>$LOGDIR/$LOG 2>&1
|
|
||||||
;;
|
|
||||||
hlfs)
|
|
||||||
xsltproc --nonet --xinclude \
|
|
||||||
--stringparam model $MODEL \
|
|
||||||
--stringparam kernel $KERNEL \
|
|
||||||
-o pkg_tarball_list packages.xsl \
|
|
||||||
$BOOK/chapter04/chapter04.xml >>$LOGDIR/$LOG 2>&1
|
|
||||||
;;
|
|
||||||
lfs)
|
|
||||||
xsltproc --nonet --xinclude -o pkg_tarball_list packages.xsl \
|
|
||||||
$BOOK/chapter03/chapter03.xml >>$LOGDIR/$LOG 2>&1
|
|
||||||
;;
|
|
||||||
esac
|
|
||||||
|
|
||||||
if [[ "${BLFS_TOOL}" = "y" ]] ; then
|
|
||||||
(
|
|
||||||
cat << EOF
|
|
||||||
$LIBXML_PKG
|
|
||||||
$LIBXSLT_PKG
|
|
||||||
$TIDY_PKG
|
|
||||||
$UNZIP_PKG
|
|
||||||
$DBXML_PKG
|
|
||||||
$DBXSL_PKG
|
|
||||||
$LYNX_PKG
|
|
||||||
$SUDO_PKG
|
|
||||||
$WGET_PKG
|
|
||||||
$SVN_PKG
|
|
||||||
$GPM_PKG
|
|
||||||
EOF
|
|
||||||
) >> pkg_tarball_list
|
|
||||||
fi
|
|
||||||
|
|
||||||
echo "done"
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
|
@ -137,7 +137,7 @@ create_urls() { #
|
||||||
xsltproc --nonet --xinclude \
|
xsltproc --nonet --xinclude \
|
||||||
--stringparam server $SERVER \
|
--stringparam server $SERVER \
|
||||||
--stringparam family clfs \
|
--stringparam family clfs \
|
||||||
-o $BUILDDIR/sources/urls.lst urls.xsl \
|
-o $BUILDDIR/sources/urls.lst $CODE_DIR/$COMMON_DIR/urls.xsl \
|
||||||
$BOOK/materials/$ARCH-chapter.xml >>$LOGDIR/$LOG 2>&1
|
$BOOK/materials/$ARCH-chapter.xml >>$LOGDIR/$LOG 2>&1
|
||||||
echo " ...OK"
|
echo " ...OK"
|
||||||
;;
|
;;
|
||||||
|
@ -146,7 +146,7 @@ create_urls() { #
|
||||||
xsltproc --nonet --xinclude \
|
xsltproc --nonet --xinclude \
|
||||||
--stringparam server $SERVER \
|
--stringparam server $SERVER \
|
||||||
--stringparam family clfs \
|
--stringparam family clfs \
|
||||||
-o $BUILDDIR/sources/urls.lst urls.xsl \
|
-o $BUILDDIR/sources/urls.lst $CODE_DIR/$COMMON_DIR/urls.xsl \
|
||||||
$BOOK/materials/$ARCH-chapter.xml >>$LOGDIR/$LOG 2>&1
|
$BOOK/materials/$ARCH-chapter.xml >>$LOGDIR/$LOG 2>&1
|
||||||
echo " ...OK"
|
echo " ...OK"
|
||||||
;;
|
;;
|
||||||
|
@ -155,7 +155,7 @@ create_urls() { #
|
||||||
xsltproc --nonet --xinclude \
|
xsltproc --nonet --xinclude \
|
||||||
--stringparam server $SERVER \
|
--stringparam server $SERVER \
|
||||||
--stringparam family clfs \
|
--stringparam family clfs \
|
||||||
-o $BUILDDIR/sources/urls.lst urls.xsl \
|
-o $BUILDDIR/sources/urls.lst $CODE_DIR/$COMMON_DIR/urls.xsl \
|
||||||
$BOOK/materials/$ARCH-chapter.xml >>$LOGDIR/$LOG 2>&1
|
$BOOK/materials/$ARCH-chapter.xml >>$LOGDIR/$LOG 2>&1
|
||||||
echo " ...OK"
|
echo " ...OK"
|
||||||
;;
|
;;
|
||||||
|
@ -166,7 +166,7 @@ create_urls() { #
|
||||||
--stringparam family lfs \
|
--stringparam family lfs \
|
||||||
--stringparam model $MODEL \
|
--stringparam model $MODEL \
|
||||||
--stringparam kernel $KERNEL \
|
--stringparam kernel $KERNEL \
|
||||||
-o $BUILDDIR/sources/urls.lst urls.xsl \
|
-o $BUILDDIR/sources/urls.lst $CODE_DIR/$COMMON_DIR/urls.xsl \
|
||||||
$BOOK/chapter04/chapter04.xml >>$LOGDIR/$LOG 2>&1
|
$BOOK/chapter04/chapter04.xml >>$LOGDIR/$LOG 2>&1
|
||||||
echo " ...OK"
|
echo " ...OK"
|
||||||
;;
|
;;
|
||||||
|
@ -175,7 +175,7 @@ create_urls() { #
|
||||||
xsltproc --nonet --xinclude \
|
xsltproc --nonet --xinclude \
|
||||||
--stringparam server $SERVER \
|
--stringparam server $SERVER \
|
||||||
--stringparam family lfs \
|
--stringparam family lfs \
|
||||||
-o ../sources/urls.lst urls.xsl \
|
-o ../sources/urls.lst $CODE_DIR/$COMMON_DIR/urls.xsl \
|
||||||
$BOOK/chapter03/chapter03.xml >>$LOGDIR/$LOG 2>&1
|
$BOOK/chapter03/chapter03.xml >>$LOGDIR/$LOG 2>&1
|
||||||
echo " ...OK"
|
echo " ...OK"
|
||||||
;;
|
;;
|
||||||
|
|
|
@ -1,56 +0,0 @@
|
||||||
<?xml version='1.0' encoding='ISO-8859-1'?>
|
|
||||||
|
|
||||||
<!-- $Id$ -->
|
|
||||||
|
|
||||||
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
|
|
||||||
version="1.0">
|
|
||||||
|
|
||||||
<xsl:output method="text"/>
|
|
||||||
|
|
||||||
<!-- The libc model used for HLFS -->
|
|
||||||
<xsl:param name="model" select="glibc"/>
|
|
||||||
|
|
||||||
<!-- The kernel series used for HLFS -->
|
|
||||||
<xsl:param name="kernel" select="2.6"/>
|
|
||||||
|
|
||||||
<xsl:template match="/">
|
|
||||||
<xsl:apply-templates select="//para"/>
|
|
||||||
</xsl:template>
|
|
||||||
|
|
||||||
<xsl:template match="para">
|
|
||||||
<xsl:if test="contains(string(),'Download:') and
|
|
||||||
(ancestor::varlistentry[@condition=$model]
|
|
||||||
or not(ancestor::varlistentry[@condition])) and
|
|
||||||
(ancestor::varlistentry[@vendor=$kernel]
|
|
||||||
or not(ancestor::varlistentry[@vendor]))">
|
|
||||||
<xsl:call-template name="package_name">
|
|
||||||
<xsl:with-param name="url" select="ulink/@url"/>
|
|
||||||
</xsl:call-template>
|
|
||||||
<xsl:text>
</xsl:text>
|
|
||||||
</xsl:if>
|
|
||||||
</xsl:template>
|
|
||||||
|
|
||||||
<xsl:template name="package_name">
|
|
||||||
<xsl:param name="url" select="foo"/>
|
|
||||||
<xsl:param name="sub-url" select="substring-after($url,'/')"/>
|
|
||||||
<xsl:choose>
|
|
||||||
<xsl:when test="contains($sub-url,'/')">
|
|
||||||
<xsl:call-template name="package_name">
|
|
||||||
<xsl:with-param name="url" select="$sub-url"/>
|
|
||||||
</xsl:call-template>
|
|
||||||
</xsl:when>
|
|
||||||
<xsl:otherwise>
|
|
||||||
<xsl:choose>
|
|
||||||
<xsl:when test="contains($sub-url,'.patch')"/>
|
|
||||||
<xsl:when test="contains($sub-url,'?')">
|
|
||||||
<xsl:value-of select="substring-before($sub-url,'?')"/>
|
|
||||||
</xsl:when>
|
|
||||||
<xsl:otherwise>
|
|
||||||
<xsl:value-of select="$sub-url"/>
|
|
||||||
</xsl:otherwise>
|
|
||||||
</xsl:choose>
|
|
||||||
</xsl:otherwise>
|
|
||||||
</xsl:choose>
|
|
||||||
</xsl:template>
|
|
||||||
|
|
||||||
</xsl:stylesheet>
|
|
13
jhalfs
13
jhalfs
|
@ -249,10 +249,14 @@ declare -r LOG=000-masterscript.log
|
||||||
declare -r SVN_2="svn://svn.linuxfromscratch.org"
|
declare -r SVN_2="svn://svn.linuxfromscratch.org"
|
||||||
|
|
||||||
# Set true internal variables
|
# Set true internal variables
|
||||||
|
CODE_DIR=`pwd`
|
||||||
COMMON_DIR="common"
|
COMMON_DIR="common"
|
||||||
PACKAGE_DIR=$(echo $PROGNAME | tr '[a-z]' '[A-Z]')
|
PACKAGE_DIR=$(echo $PROGNAME | tr '[a-z]' '[A-Z]')
|
||||||
MODULE=$PACKAGE_DIR/master.sh
|
MODULE=$PACKAGE_DIR/master.sh
|
||||||
|
|
||||||
|
# Qick fix until have the new code ready
|
||||||
|
XSL=$CODE_DIR/$PACKAGE_DIR/$XSL
|
||||||
|
|
||||||
[[ $VERBOSITY > 0 ]] && echo -n "Loading common-functions module..."
|
[[ $VERBOSITY > 0 ]] && echo -n "Loading common-functions module..."
|
||||||
source $COMMON_DIR/common-functions
|
source $COMMON_DIR/common-functions
|
||||||
[[ $? > 0 ]] && echo " $COMMON_DIR/common-functions did not load.." && exit
|
[[ $? > 0 ]] && echo " $COMMON_DIR/common-functions did not load.." && exit
|
||||||
|
@ -357,16 +361,9 @@ if [[ "$REBUILD_MAKEFILE" = "n" ]] ; then
|
||||||
>$LOGDIR/$LOG
|
>$LOGDIR/$LOG
|
||||||
#
|
#
|
||||||
# Copy common helper files
|
# Copy common helper files
|
||||||
cp $COMMON_DIR/{makefile-functions,progress_bar.sh,packages.xsl} $JHALFSDIR/
|
cp $COMMON_DIR/{makefile-functions,progress_bar.sh} $JHALFSDIR/
|
||||||
#
|
|
||||||
# Fix the XSL book parser
|
|
||||||
sed 's,FAKEDIR,'$BOOK',' $PACKAGE_DIR/$XSL > $JHALFSDIR/${XSL}
|
|
||||||
export XSL=$JHALFSDIR/${XSL}
|
|
||||||
#
|
#
|
||||||
|
|
||||||
# Copy urls.xsl, if needed
|
|
||||||
[[ "$GETPKG" = "y" ]] && cp $COMMON_DIR/urls.xsl $JHALFSDIR/
|
|
||||||
#
|
|
||||||
# Create the test-log directory, if needed
|
# Create the test-log directory, if needed
|
||||||
[[ "$TEST" != "0" ]] && [[ ! -d $TESTLOGDIR ]] && install -d -m 1777 $TESTLOGDIR
|
[[ "$TEST" != "0" ]] && [[ ! -d $TESTLOGDIR ]] && install -d -m 1777 $TESTLOGDIR
|
||||||
#
|
#
|
||||||
|
|
Reference in a new issue