r2182 - jhalfs/trunk

manuel at linuxfromscratch.org manuel at linuxfromscratch.org
Wed Nov 16 10:16:53 PST 2005


Author: manuel
Date: 2005-11-16 11:16:52 -0700 (Wed, 16 Nov 2005)
New Revision: 2182

Modified:
   jhalfs/trunk/dump-lfs-scripts.xsl
   jhalfs/trunk/jhalfs
   jhalfs/trunk/jhalfs.conf
Log:
Added suppot to download and build the vim-lang package (can be skipped using a switch).

Modified: jhalfs/trunk/dump-lfs-scripts.xsl
===================================================================
--- jhalfs/trunk/dump-lfs-scripts.xsl	2005-11-13 19:11:46 UTC (rev 2181)
+++ jhalfs/trunk/dump-lfs-scripts.xsl	2005-11-16 18:16:52 UTC (rev 2182)
@@ -1,4 +1,9 @@
 <?xml version="1.0"?>
+<!DOCTYPE xsl:stylesheet [
+ <!ENTITY % general-entities SYSTEM "FAKEDIR/general.ent">
+  %general-entities;
+]>
+
 <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
     xmlns:exsl="http://exslt.org/common"
     extension-element-prefixes="exsl"
@@ -12,6 +17,9 @@
   <!-- Run toolchain test suites? -->
   <xsl:param name="toolchaintest" select="1"/>
 
+  <!-- Install vim-lang package? -->
+  <xsl:param name="vim-lang" select="1"/>
+
   <xsl:template match="/">
     <xsl:apply-templates select="//sect1"/>
   </xsl:template>
@@ -65,6 +73,9 @@
                 @id='ch-tools-adjusting' or
                 @id='ch-system-readjusting'">
           <xsl:text>cd $PKGDIR&#xA;</xsl:text>
+          <xsl:if test="@id='ch-system-vim' and $vim-lang = '1'">
+            <xsl:text>tar -xvf ../vim-&vim-version;-lang.*&#xA;</xsl:text>
+          </xsl:if>
         </xsl:if>
         <xsl:apply-templates select=".//para/userinput | .//screen"/>
         <xsl:text>exit</xsl:text>

Modified: jhalfs/trunk/jhalfs
===================================================================
--- jhalfs/trunk/jhalfs	2005-11-13 19:11:46 UTC (rev 2181)
+++ jhalfs/trunk/jhalfs	2005-11-16 18:16:52 UTC (rev 2182)
@@ -63,6 +63,8 @@
                                 LFS system. If not specified, a default
                                 /etc/fstab file with dummy values is
                                 created.
+  
+  --no-vim-lang                 don't install the optional vim-lang package
 
   -C, --kernel-config FILE      use the kernel configuration file specified
                                 in FILE to build the kernel. If the file is
@@ -105,12 +107,6 @@
   exit 1"
   cd $JHALFSDIR
 
-  # Test to make sure the LFS version is set
-  if [ -z $LFSVRS ] ; then LFSVRS=development ; fi
-
-  # Set the book's sources directory
-  if [ -z $BOOK ] ; then BOOK=lfs-$LFSVRS ; fi
-
   if [ -z $WC ] ; then
     echo -n "Downloading the LFS Book, version $LFSVRS... "
 
@@ -159,8 +155,8 @@
 
   # Dump the commands in shell script form from the LFS book.
   xsltproc --nonet --xinclude --stringparam testsuite $TEST \
-    --stringparam toolchaintest $TOOLCHAINTEST -o ./commands/ \
-    $XSL $BOOK/index.xml >>$LOGDIR/$LOG 2>&1
+    --stringparam toolchaintest $TOOLCHAINTEST --stringparam vim-lang $VIMLANG \
+    -o ./commands/ $XSL $BOOK/index.xml >>$LOGDIR/$LOG 2>&1
 
   # Make the scripts executable.
   chmod -R +x $JHALFSDIR/commands
@@ -171,6 +167,10 @@
   grep "\-version" $BOOK/general.ent | sed -e 's@<!ENTITY @@' -e 's@">@"@' \
   -e '/generic/d' >> packages
   echo `grep "glibc" packages | sed 's at glibc@&-linuxthreads@'` >> packages
+  # Download the vim-lang package if it must be installed
+  if [ "$VIMLANG" = "1" ] ; then
+    echo `grep "vim" packages | sed 's at vim@&-lang@'` >> packages
+  fi
   echo `grep "udev-config-file" $BOOK/general.ent | sed -e 's@<!ENTITY @@' -e 's@">@"@'` >> packages
   # Download the module-init-tools-testsuite package only 
   # if the test suite will be run.
@@ -262,6 +262,9 @@
       VRS=`echo $i | sed -e 's/.* //' -e 's/"//g'`
       if [ "$PKG" = "tcl" ] ; then
         FILE="$PKG$VRS-src.tar.bz2"
+      elif [ "$PKG" = "vim-lang" ] ; then
+        PKG="vim"
+        FILE="vim-$VRS-lang.tar.bz2"
       elif [ "$PKG" = "udev-config" ] ; then
         PKG="udev"
         FILE="$VRS"
@@ -918,6 +921,8 @@
     --run-make | -M )		RUNMAKE=1 ;;
 
     --no-toolchain-test )	TOOLCHAINTEST=0 ;;
+
+    --no-vim-lang )	VIMLANG=0 ;;
     
     --page_size )
       test $# = 1 && eval "$exit_missing_arg"
@@ -989,7 +994,9 @@
 fi
 
 [[ ! -d $JHALFSDIR ]]        && mkdir -pv $JHALFSDIR
-[[ "$PWD" != "$JHALFSDIR" ]] && cp -v $FILES $JHALFSDIR/
+[[ "$PWD" != "$JHALFSDIR" ]] && cp -v $FILES $JHALFSDIR/ && \
+  sed -e 's/FAKEDIR/'$BOOK'/' $XSL > $JHALFSDIR/dump-lfs-scripts.xsl && \
+  export XSL=$JHALFSDIR/dump-lfs-scripts.xsl
 [[ ! -d $LOGDIR ]]           && mkdir -v $LOGDIR
 >$LOGDIR/$LOG
 

Modified: jhalfs/trunk/jhalfs.conf
===================================================================
--- jhalfs/trunk/jhalfs.conf	2005-11-13 19:11:46 UTC (rev 2181)
+++ jhalfs/trunk/jhalfs.conf	2005-11-16 18:16:52 UTC (rev 2182)
@@ -6,20 +6,11 @@
 
 declare -r SVN="svn://svn.linuxfromscratch.org"
 declare -r HTTP=http://ftp.lfs-matrix.net/pub/lfs/conglomeration
-declare -r XSL=dump-lfs-scripts.xsl
 declare -r LOG=000-jhalfs.log
 
-#--- Files that will be copied to $JHALFSDIR
-FILES="functions dump-lfs-scripts.xsl"
-
 #--- Mount point for the build
 BUILDDIR=/mnt/lfs
 
-#--- Working directories
-JHALFSDIR=$BUILDDIR/jhalfs
-   LOGDIR=$JHALFSDIR/logs
-   MKFILE=$JHALFSDIR/Makefile
-   
 #--- Download the source packages 0(no)/1(yes)
 HPKG=0
 
@@ -38,6 +29,33 @@
 #--- set default timezone.
 TIMEZONE=Europe/London
 
+#--- install the optional vim-lang package  0(no)/1(yes)
+VIMLANG=1
+
+#--- Location of fstab file (if empty, a template is created)
+FSTAB=
+
 #--- Location of kernel config file (if the kernel is to be compiled)
 CONFIG=
 
+
+
+#==== INTERNAL VARIABLES ====
+# Don't edit it unless you know what you are doing
+
+#--- Default stylesheet
+XSL=dump-lfs-scripts.xsl
+
+#--- Files that will be copied to $JHALFSDIR
+FILES="functions"
+
+#--- Working directories
+JHALFSDIR=$BUILDDIR/jhalfs
+   LOGDIR=$JHALFSDIR/logs
+   MKFILE=$JHALFSDIR/Makefile
+   
+#--- Book version
+LFSVRS=development
+
+#--- Book's sources directory
+BOOK=lfs-$LFSVRS




More information about the alfs-log mailing list