Index: BLFS/xsl/gen_config.xsl
===================================================================
--- BLFS/xsl/gen_config.xsl	(revision 05b955b62c1cf4afda76c08587303cd95e4eb4c6)
+++ BLFS/xsl/gen_config.xsl	(revision ca368adbe562917cf8814577b6793bb694c5d224)
@@ -310,5 +310,8 @@
 &#9;&#9;&#9;default&#9;</xsl:text>
       <xsl:choose>
-        <xsl:when test="contains(../name,'xorg')">
+      <!-- for compound packages, default to selecting all the subpackages-->
+        <xsl:when test="contains(../name,'xorg') or
+                        contains(../name,'plasma') or
+                        contains(../name,'kf5')">
           <xsl:text>y
 
Index: BLFS/xsl/gen_pkg_list.xsl
===================================================================
--- BLFS/xsl/gen_pkg_list.xsl	(revision 05b955b62c1cf4afda76c08587303cd95e4eb4c6)
+++ BLFS/xsl/gen_pkg_list.xsl	(revision ca368adbe562917cf8814577b6793bb694c5d224)
@@ -359,6 +359,8 @@
 <!-- do not depend on something which is not a dependency -->
         <xsl:when test="@role='nodep'"/>
-<!-- Call list expansion when we have an xorg7 series of packages -->
-        <xsl:when test="contains(@linkend,'xorg7-')">
+<!-- Call list expansion when we have a compound package -->
+        <xsl:when test="contains(@linkend,'xorg7-') or
+                        @linkend='kf5-frameworks' or
+                        @linkend='plasma5-build'">
           <xsl:call-template name="expand-deps">
             <xsl:with-param name="section">
Index: BLFS/xsl/make_book.xsl
===================================================================
--- BLFS/xsl/make_book.xsl	(revision 05b955b62c1cf4afda76c08587303cd95e4eb4c6)
+++ BLFS/xsl/make_book.xsl	(revision ca368adbe562917cf8814577b6793bb694c5d224)
@@ -58,17 +58,19 @@
      Normally, those items are id of nodes.
      Those nodes can be sect1 (normal case),
-     sect2 (python modules or DBus bindings)
-     bridgehead (perl modules)
-     para (dependency of perl modules).
+     sect2 (python/perl modules/dependencies )
      The templates after this one treat each of those cases.
-     However, some items are xorg package names, and not id.
+     However, some items are sub-packages of compound packages (xorg7-*,
+     kf5, plasma), and not id.
      We need special instructions in that case.
      The difficulty is that some of those names *are* id's,
      because they are referenced in the index.
-     Hopefully, none of those id's are sect{1,2}, bridgehead or para...-->
+     Hopefully, none of those id's are sect{1,2}...
+     We also need a special template for plasma-post-install,
+     because this one is not an id at all!-->
   <xsl:template name="apply-list">
     <xsl:param name="list" select="''"/>
     <xsl:if test="string-length($list) &gt; 0">
       <xsl:choose>
+        <!-- iterate if there are several packages in list -->
         <xsl:when test="contains($list,' ')">
           <xsl:call-template name="apply-list">
@@ -81,4 +83,6 @@
           </xsl:call-template>
         </xsl:when>
+        <!-- From now on, $list contains only one package -->
+        <!-- If it is a group, do nothing -->
         <xsl:when test="contains($list,'groupxx')"/>
         <xsl:otherwise>
@@ -91,4 +95,5 @@
           <xsl:choose>
             <xsl:when test="$is-lfs='true'">
+            <!-- LFS package -->
               <xsl:message>
                 <xsl:value-of select="$list"/>
@@ -101,5 +106,5 @@
             </xsl:when>
             <xsl:when test="contains(concat($list,' '),'-pass1 ')">
-<!-- We need to do it only for sect1 and sect2, because of libva -->
+<!-- We need to do it for both sect1 and sect2, because of libva -->
               <xsl:variable
                    name="real-id"
@@ -112,10 +117,19 @@
               </xsl:if>
             </xsl:when>
-            <xsl:when test="not(id($list)[self::sect1 or self::sect2 or self::para or self::bridgehead])">
+            <xsl:when test="$list='plasma-post-install'">
               <xsl:apply-templates
-                   select="//sect1[contains(@id,'xorg7')
-                               and contains(string(.//userinput),
-                                            concat($list,'-'))]"
-                   mode="xorg">
+                select="//sect1[@id='plasma5-build']"
+                mode="plasma-post-install"/>
+            </xsl:when>
+            <xsl:when test="not(id($list)[self::sect1 or self::sect2])">
+              <!-- This is a sub-package: parse the corresponding compound
+                   package-->
+              <xsl:apply-templates
+                select="//sect1[(contains(@id,'xorg7') or
+                                 contains(@id,'frameworks') or
+                                 contains(@id,'plasma5'))
+                                 and .//userinput/literal[contains(string(),
+                                            concat($list,'-'))]]"
+                 mode="compound">
                 <xsl:with-param name="package" select="$list"/>
               </xsl:apply-templates>
@@ -496,5 +510,5 @@
      but now we need to make an autonomous page from the global
      one -->
-  <xsl:template match="sect1" mode="xorg">
+  <xsl:template match="sect1" mode="compound">
     <xsl:param name="package"/>
     <xsl:variable name="tarball">
@@ -505,97 +519,131 @@
       </xsl:call-template>
     </xsl:variable>
-    <xsl:variable name="md5sum">
-      <xsl:call-template name="md5sum">
-        <xsl:with-param name="package" select="concat(' ',$package,'-')"/>
-        <xsl:with-param name="cat-md5"
-                        select=".//userinput[starts-with(string(),'cat ')]"/>
-      </xsl:call-template>
-    </xsl:variable>
-    <xsl:variable name="download-dir">
-      <xsl:call-template name="download-dir">
-        <xsl:with-param name="package" select="concat(' ',$package,'-')"/>
-        <xsl:with-param name="cat-md5"
-                        select=".//userinput[starts-with(string(),'cat ')]"/>
-      </xsl:call-template>
-    </xsl:variable>
-    <xsl:variable name="install-instructions">
-      <xsl:call-template name="inst-instr">
-        <xsl:with-param name="inst-instr"
-                        select=".//userinput[starts-with(string(),'for ')]"/>
-      </xsl:call-template>
-    </xsl:variable>
-    <xsl:element name="sect1">
-      <xsl:attribute name="id"><xsl:value-of select="$package"/></xsl:attribute>
-      <xsl:processing-instruction name="dbhtml">
-         filename="<xsl:value-of select='$package'/>.html"
-      </xsl:processing-instruction>
-      <title><xsl:value-of select="$package"/></title>
-      <sect2 role="package">
-        <title>Introduction to <xsl:value-of select="$package"/></title>
-        <bridgehead renderas="sect3">Package Information</bridgehead>
-        <itemizedlist spacing="compact">
-          <listitem>
-            <para>Download (HTTP): <xsl:element name="ulink">
-              <xsl:attribute name="url">
-                <xsl:value-of
-                   select=".//para[contains(string(),'(HTTP)')]/ulink/@url"/>
-                <xsl:value-of select="$download-dir"/>
-                <xsl:value-of select="$tarball"/>
-              </xsl:attribute>
-             </xsl:element>
-            </para>
-          </listitem>
-          <listitem>
-            <para>Download (FTP): <xsl:element name="ulink">
-              <xsl:attribute name="url">
-                <xsl:value-of
-                   select=".//para[contains(string(),'(FTP)')]/ulink/@url"/>
-                <xsl:value-of select="$download-dir"/>
-                <xsl:value-of select="$tarball"/>
-              </xsl:attribute>
-             </xsl:element>
-            </para>
-          </listitem>
-          <listitem>
-            <para>
-              Download MD5 sum: <xsl:value-of select="$md5sum"/>
-            </para>
-          </listitem>
-        </itemizedlist>
-        <!-- If there is an additional download, we need to output that -->
-        <xsl:if test=".//bridgehead[contains(string(),'Additional')]">
-          <xsl:copy-of
-                 select=".//bridgehead[contains(string(),'Additional')]"/>
-          <xsl:copy-of
-                 select=".//bridgehead[contains(string(),'Additional')]
-                         /following-sibling::itemizedlist[1]"/>
-        </xsl:if>
-      </sect2>
-      <sect2 role="installation">
-        <title>Installation of <xsl:value-of select="$package"/></title>
-
-        <para>
-          Install <application><xsl:value-of select="$package"/></application>
-          by running the following commands:
-        </para>
-
-        <screen><userinput>packagedir=<xsl:value-of
-                    select="substring-before($tarball,'.tar.')"/>
-          <xsl:text>&#xA;</xsl:text>
-          <xsl:value-of select="substring-before($install-instructions,
-                                                 'as_root')"/>
-        </userinput></screen>
-
-        <para>
-          Now as the <systemitem class="username">root</systemitem> user:
-        </para>
-        <screen role='root'>
-          <userinput><xsl:value-of select="substring-after(
-                                                 $install-instructions,
-                                                 'as_root')"/>
-          </userinput>
-        </screen>
-      </sect2>
-    </xsl:element><!-- sect1 -->
+    <!-- Unfortunately, there are packages in kf5 and plasma5 that
+         starts in the same way: for example kwallet in kf5
+         and kwallet-pam in plasma. So we may arrive here with
+         package=kwallet and tarball=kwallet-pam-(version).tar.xz.
+         We should not continue in this case. For checking, transform
+         digits into X, and check that package-X occurs in tarball. We
+         have to translate package too, since it may contain digits.-->
+    <xsl:if test=
+        "contains(translate($tarball,'0123456789','XXXXXXXXXX'),
+                  concat(translate($package,'0123456789','XXXXXXXXXX'),'-X'))">
+      <xsl:variable name="md5sum">
+        <xsl:call-template name="md5sum">
+          <xsl:with-param name="package" select="concat(' ',$package,'-')"/>
+          <xsl:with-param name="cat-md5"
+                          select=".//userinput[starts-with(string(),'cat ')]"/>
+        </xsl:call-template>
+      </xsl:variable>
+      <xsl:variable name="download-dir">
+        <xsl:call-template name="download-dir">
+          <xsl:with-param name="package" select="concat(' ',$package,'-')"/>
+          <xsl:with-param name="cat-md5"
+                          select=".//userinput[starts-with(string(),'cat ')]"/>
+        </xsl:call-template>
+      </xsl:variable>
+      <xsl:variable name="install-instructions">
+        <xsl:call-template name="inst-instr">
+          <xsl:with-param name="inst-instr"
+            select=
+              "substring-after(
+                 substring-after(.//userinput[starts-with(string(),'for ') or
+                                              starts-with(string(),'while ')],
+                                 'pushd'),
+                 '&#xA;')"/>
+          <xsl:with-param name="package" select="$package"/>
+        </xsl:call-template>
+      </xsl:variable>
+      <xsl:element name="sect1">
+        <xsl:attribute name="id">
+          <xsl:value-of select="$package"/>
+        </xsl:attribute>
+        <xsl:processing-instruction name="dbhtml">
+           filename="<xsl:value-of select='$package'/>.html"
+        </xsl:processing-instruction>
+        <title><xsl:value-of select="$package"/></title>
+        <sect2 role="package">
+          <title>Introduction to <xsl:value-of select="$package"/></title>
+          <bridgehead renderas="sect3">Package Information</bridgehead>
+          <itemizedlist spacing="compact">
+            <listitem>
+              <para>Download (HTTP): <xsl:element name="ulink">
+                <xsl:attribute name="url">
+                  <xsl:value-of
+                     select=".//para[contains(string(),'(HTTP)')]/ulink/@url"/>
+                  <xsl:value-of select="$download-dir"/>
+                  <!-- $download-dir contains the trailing / for xorg,
+                       but not for KDE... -->
+                  <xsl:if test="contains(@id,'frameworks') or
+                                contains(@id,'plasma5')">
+                    <xsl:text>/</xsl:text>
+                  </xsl:if>
+                  <!-- Some kf5 packages are in a subdirectory -->
+                  <xsl:if test="$package='khtml' or
+                                $package='kdelibs4support' or
+                                $package='kdesignerplugin' or
+                                $package='kdewebkit' or
+                                $package='kjs' or
+                                $package='kjsembed' or
+                                $package='kmediaplayer' or
+                                $package='kross' or
+                                $package='kxmlrpcclient'">
+                    <xsl:text>portingAids/</xsl:text>
+                  </xsl:if>
+                  <xsl:value-of select="$tarball"/>
+                </xsl:attribute>
+               </xsl:element>
+              </para>
+            </listitem>
+            <!-- don't use FTP, although they are available for xorg -->
+            <listitem>
+              <para>Download (FTP): <ulink url=" "/>
+              </para>
+            </listitem>
+            <listitem>
+              <para>
+                Download MD5 sum: <xsl:value-of select="$md5sum"/>
+              </para>
+            </listitem>
+          </itemizedlist>
+          <!-- If there is an additional download, we need to output that -->
+          <xsl:if test=".//bridgehead[contains(string(),'Additional')]">
+            <xsl:copy-of
+                   select=".//bridgehead[contains(string(),'Additional')]"/>
+            <xsl:copy-of
+                   select=".//bridgehead[contains(string(),'Additional')]
+                           /following-sibling::itemizedlist[1]"/>
+          </xsl:if>
+        </sect2>
+        <sect2 role="installation">
+          <title>Installation of <xsl:value-of select="$package"/></title>
+
+          <para>
+            Install <application><xsl:value-of select="$package"/></application>
+            by running the following commands:
+          </para>
+          <!-- packagedir is used in xorg lib instructions -->
+          <screen><userinput>packagedir=<xsl:value-of
+                      select="substring-before($tarball,'.tar.')"/>
+           <!-- name is used in kf5 instructions -->
+            <xsl:text>
+name=$(echo $packagedir | sed 's/-[[:digit:]].*//')
+</xsl:text>
+            <xsl:value-of select="substring-before($install-instructions,
+                                                   'as_root')"/>
+          </userinput></screen>
+
+          <para>
+            Now as the <systemitem class="username">root</systemitem> user:
+          </para>
+          <screen role='root'>
+            <userinput><xsl:value-of select="substring-after(
+                                                   $install-instructions,
+                                                   'as_root')"/>
+            </userinput>
+          </screen>
+        </sect2>
+      </xsl:element><!-- sect1 -->
+    </xsl:if>
 
   </xsl:template>
@@ -603,14 +651,12 @@
 <!-- get the tarball name from the text that comes from the .md5 file -->
   <xsl:template name="tarball">
+    <!-- $package must start with a space, and finish with a "-", to be
+         sure to match exactly the package. Note that if we have two
+         packages named e.g. "pkg1" and "pkg1-add", the second one may be
+         matched by " pkg1-". So this only works if "pkg1" comes before
+         "pkg1-add" in the md5 file. Presently this is the case in the book...
+    -->
     <xsl:param name="package"/>
     <xsl:param name="cat-md5"/>
-<!-- DEBUG
-<xsl:message><xsl:text>Entering "tarball" template:
-  package is: </xsl:text>
-<xsl:value-of select="$package"/><xsl:text>
-  cat-md5 is: </xsl:text>
-<xsl:value-of select="$cat-md5"/>
-</xsl:message>
-END DEBUG -->
     <xsl:choose>
       <xsl:when test="contains(substring-before($cat-md5,$package),'&#xA;')">
@@ -680,18 +726,91 @@
 
   <xsl:template name="inst-instr">
+    <!-- This template is necessary because of the "kapidox" case in kf5:
+         Normally, the general instructions extract the package and change
+         to the extracted dir for running the installation instructions.
+         When installing a sub-package of a compound package, the installation
+         instructions to be run are located between a pushd and a popd,
+         *except* for kf5, where a popd occurs inside a case for kapidox...
+         So we call this template with a "inst-instr" string that contains
+         everything after the pushd.-->
     <xsl:param name="inst-instr"/>
-    <xsl:choose>
-      <xsl:when test="contains($inst-instr,'pushd')">
-        <xsl:call-template name="inst-instr">
-          <xsl:with-param name="inst-instr"
-                          select="substring-after(
-                                   substring-after($inst-instr,'pushd'),
-                                   '&#xA;')"/>
-        </xsl:call-template>
-      </xsl:when>
-      <xsl:otherwise>
+    <xsl:param name="package"/>
+    <xsl:choose>
+      <!-- first the case of kf5: there are two "popd"-->
+      <xsl:when test="contains(substring-after($inst-instr,'popd'),'popd')">
+        <xsl:choose>
+          <xsl:when test="$package='kapidox'">
+            <!-- only the instructions inside the "case" and before popd -->
+            <xsl:copy-of select="substring-after(substring-before($inst-instr,'popd'),'kapidox)')"/>
+          </xsl:when>
+          <xsl:otherwise>
+            <!-- all what is after the esac -->
+            <xsl:call-template name="inst-instr">
+              <xsl:with-param
+                name="inst-instr"
+                select="substring-after($inst-instr,'esac&#xA;')"/>
+            </xsl:call-template>
+          </xsl:otherwise>
+        </xsl:choose>
+      </xsl:when>
+      <xsl:otherwise>
+        <!-- normal case: everything that is before popd -->
         <xsl:copy-of select="substring-before($inst-instr,'popd')"/>
       </xsl:otherwise>
     </xsl:choose>
   </xsl:template>
+
+  <xsl:template match="sect1" mode="plasma-post-install">
+    <xsl:variable name="package" select="'plasma-post-install'"/>
+    <xsl:element name="sect1">
+      <xsl:attribute name="id">
+        <xsl:value-of select="$package"/>
+      </xsl:attribute>
+      <xsl:processing-instruction name="dbhtml">
+         filename="<xsl:value-of select='$package'/>.html"
+      </xsl:processing-instruction>
+      <title><xsl:value-of select="$package"/></title>
+      <sect2 role="installation">
+        <title>Installation of <xsl:value-of select="$package"/></title>
+
+        <para>
+          Install <application><xsl:value-of select="$package"/></application>
+          by running the following commands:
+        </para>
+        <screen role="root">
+          <userinput>
+            <xsl:call-template name="plasma-sessions">
+              <xsl:with-param
+                name="p-sessions-text"
+                select="string(.//userinput[contains(text(),'xsessions')])"/>
+            </xsl:call-template>
+          </userinput>
+        </screen>
+        <xsl:copy-of select=".//screen[@role='root']"/>
+      </sect2>
+    </xsl:element><!-- sect1 -->
+  </xsl:template>
+
+  <xsl:template name="plasma-sessions">
+    <xsl:param name="p-sessions-text"/>
+    <xsl:choose>
+      <xsl:when test="string-length($p-sessions-text)=0"/>
+      <xsl:when test="contains($p-sessions-text,'as_root')">
+        <xsl:call-template name="plasma-sessions">
+          <xsl:with-param
+            name="p-sessions-text"
+            select="substring-before($p-sessions-text,'as_root')"/>
+        </xsl:call-template>
+        <xsl:call-template name="plasma-sessions">
+          <xsl:with-param
+            name="p-sessions-text"
+            select="substring-after($p-sessions-text,'as_root ')"/>
+        </xsl:call-template>
+      </xsl:when>
+      <xsl:otherwise>
+        <xsl:copy-of select="$p-sessions-text"/>
+      </xsl:otherwise>
+    </xsl:choose>
+  </xsl:template>
+
 </xsl:stylesheet>
Index: BLFS/xsl/process-prompt.xsl
===================================================================
--- BLFS/xsl/process-prompt.xsl	(revision ca368adbe562917cf8814577b6793bb694c5d224)
+++ BLFS/xsl/process-prompt.xsl	(revision ca368adbe562917cf8814577b6793bb694c5d224)
@@ -0,0 +1,99 @@
+<?xml version="1.0" encoding="ISO-8859-1"?>
+<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
+    version="1.0">
+
+  <xsl:template name="process-prompt">
+    <xsl:param name="instructions"/>
+    <xsl:param name="root-seen"/>
+    <xsl:param name="prompt-seen"/>
+
+<!-- Isolate the current instruction -->
+    <xsl:variable name="current-instr" select="$instructions[1]"/>
+
+    <xsl:choose>
+<!--============================================================-->
+<!-- First, if we have an empty tree, close everything and exit -->
+      <xsl:when test="not($current-instr)">
+        <xsl:if test="$prompt-seen">
+          <xsl:call-template name="end-prompt"/>
+        </xsl:if>
+        <xsl:if test="$root-seen">
+          <xsl:call-template name="end-root"/>
+        </xsl:if>
+      </xsl:when><!-- end empty tree -->
+<!--============================================================-->
+      <xsl:when test="$current-instr[@role='root']">
+        <xsl:choose>
+          <xsl:when test="$current-instr//prompt">
+            <xsl:if test="not($root-seen)">
+              <xsl:call-template name="begin-root"/>
+            </xsl:if>
+            <xsl:text>&#xA;</xsl:text>
+            <xsl:if test="not($prompt-seen)">
+              <xsl:copy-of
+                select="substring-before($current-instr//text()[1],'&#xA;')"/>
+              <xsl:text> &lt;&lt; PROMPT_EOF
+</xsl:text>
+            </xsl:if>
+            <xsl:apply-templates
+              select="$current-instr/userinput/node()[position()>1]"/>
+            <xsl:call-template name="process-prompt">
+              <xsl:with-param
+                 name="instructions"
+                 select="$instructions[position()>1]"/>
+              <xsl:with-param name="root-seen" select="boolean(1)"/>
+              <xsl:with-param name="prompt-seen" select="boolean(1)"/>
+            </xsl:call-template>
+          </xsl:when><!-- end prompt as root -->
+<!--____________________________________________________________ -->
+          <xsl:otherwise><!-- we have no prompt -->
+            <xsl:if test="$prompt-seen">
+              <xsl:text>
+quit
+PROMPT_EOF</xsl:text>
+            </xsl:if>
+            <xsl:apply-templates
+              select="$current-instr"
+              mode="config"/>
+            <!-- the above will call "end-root" if the next screen
+                 sibling is not role="root". We need to pass root-seen=false
+                 in this case. Otherwise, we need to pass root-seen=true.
+                 So create a variable -->
+            <xsl:variable name="rs"
+              select="$instructions[2][@role='root']"/>
+            <xsl:call-template name="process-prompt">
+              <xsl:with-param
+                 name="instructions"
+                 select="$instructions[position()>1]"/>
+              <xsl:with-param name="root-seen" select="boolean($rs)"/>
+              <xsl:with-param name="prompt-seen" select="boolean(0)"/>
+            </xsl:call-template>
+          </xsl:otherwise><!-- end no prompt -->
+<!--____________________________________________________________ -->
+        </xsl:choose>
+      </xsl:when><!-- role="root" -->
+<!--============================================================-->
+      <xsl:otherwise><!-- no role -->
+        <xsl:if test="$prompt-seen">
+          <xsl:text>
+quit
+PROMPT_EOF</xsl:text>
+        </xsl:if>
+        <xsl:if test="$root-seen">
+          <xsl:call-template name="end-root"/>
+        </xsl:if>
+        <xsl:apply-templates select="$current-instr/userinput"/>
+        <xsl:call-template name="process-prompt">
+          <xsl:with-param
+             name="instructions"
+             select="$instructions[position()>1]"/>
+          <xsl:with-param name="root-seen" select="boolean(0)"/>
+          <xsl:with-param name="prompt-seen" select="boolean(0)"/>
+        </xsl:call-template>
+      </xsl:otherwise><!-- no role -->
+<!--============================================================-->
+    </xsl:choose>
+  </xsl:template>
+
+  <xsl:template match="prompt"/>
+</xsl:stylesheet>
Index: BLFS/xsl/process-replaceable.xsl
===================================================================
--- BLFS/xsl/process-replaceable.xsl	(revision 05b955b62c1cf4afda76c08587303cd95e4eb4c6)
+++ BLFS/xsl/process-replaceable.xsl	(revision ca368adbe562917cf8814577b6793bb694c5d224)
@@ -113,4 +113,7 @@
       <xsl:when test="string()='&lt;EXAMPLE.ORG&gt;'">
         <xsl:copy-of select="$DOMAINNAME"/>
+        <xsl:if test="contains(preceding-sibling::text()[1],'kdb5_util')">
+          <xsl:text> -P rtpw </xsl:text>
+        </xsl:if>
       </xsl:when>
       <xsl:when test="string()='&lt;example.org&gt;'">
@@ -122,5 +125,14 @@
 <!-- in this case, even root can be used -->
       <xsl:when test="string()='&lt;loginname&gt;'">
+        <xsl:if test="contains(preceding-sibling::text()[1],'-policy')">
+          <xsl:text>-pw lupw </xsl:text>
+        </xsl:if>
         <xsl:text>$USER</xsl:text>
+        <xsl:if test="contains(preceding-sibling::text()[1],'kinit')">
+          <xsl:text> &lt;&lt; PASS_EOF
+lupw
+PASS_EOF
+</xsl:text>
+        </xsl:if>
       </xsl:when>
 <!-- for xorg environment. Note that libreoffice too uses &lt;PREFIX&gt; -->
Index: BLFS/xsl/scripts.xsl
===================================================================
--- BLFS/xsl/scripts.xsl	(revision 05b955b62c1cf4afda76c08587303cd95e4eb4c6)
+++ BLFS/xsl/scripts.xsl	(revision ca368adbe562917cf8814577b6793bb694c5d224)
@@ -80,4 +80,7 @@
 <!-- include the template for replaceable tags -->
   <xsl:include href="process-replaceable.xsl"/>
+
+<!-- include the template for prompt tags -->
+  <xsl:include href="process-prompt.xsl"/>
 
 <!--=================== Begin processing ========================-->
@@ -386,6 +389,19 @@
       <xsl:when test="@role = 'configuration'">
         <xsl:text>&#xA;</xsl:text>
-        <xsl:apply-templates mode="config"
-             select=".//screen[not(@role = 'nodump') and ./userinput]"/>
+        <xsl:choose>
+          <xsl:when test=".//screen/userinput/prompt">
+            <xsl:call-template name="process-prompt">
+              <xsl:with-param
+                name="instructions"
+                select=".//screen[not(@role = 'nodump') and ./userinput]"/>
+              <xsl:with-param name="root-seen" select="false"/>
+              <xsl:with-param name="prompt-seen" select="false"/>
+            </xsl:call-template>
+          </xsl:when>
+          <xsl:otherwise>
+            <xsl:apply-templates mode="config"
+                 select=".//screen[not(@role = 'nodump') and ./userinput]"/>
+          </xsl:otherwise>
+        </xsl:choose>
       </xsl:when><!-- @role="configuration" -->
 
