Add non-versioned packages in packages.xml. This allows for example to list dependencies of CA certificates
This commit is contained in:
parent
d7c07e0b34
commit
5fb012da9a
1 changed files with 38 additions and 1 deletions
|
@ -11,7 +11,10 @@
|
|||
# - If a package is part of a group of xorg packages (proto, fonts, etc)
|
||||
# there is no easy way to extract it from the xml. We use the ENTITY at
|
||||
# the top of each file x7*.xml
|
||||
# - If a pacakge is versioned but the version is not mentioned in the book
|
||||
# - Some non-versioned packages are needed as dependencies of others: we
|
||||
# attribute version 1.0.0 to them. It is just used to know if the package
|
||||
# is installed, by checking inst-version.
|
||||
# - If a package is versioned but the version is not mentioned in the book
|
||||
# (currently only udev), we retrieve the version by other means
|
||||
#-------------------------------------------------------------------------
|
||||
# Arguments:
|
||||
|
@ -34,6 +37,10 @@ if test -z "${BLFS_DIR}"; then BLFS_DIR=$(cd $(dirname ${BLFS_XML})/.. ; pwd);fi
|
|||
EXCEPTIONS=$(grep 'ENTITY.*version[ ]*"[^0-9"&.].*[0-9]' $BLFS_XML |
|
||||
sed 's@^[^"]*"\([^"]*\)".*@\1@')
|
||||
|
||||
# Non-versioned packages:
|
||||
NV_LIST="cacerts xorg-env kde-pre-install-config kf5-intro lxqt-pre-install \
|
||||
ojdk-conf tex-path"
|
||||
|
||||
# Set PATH to be sure to find udevadm
|
||||
SAVPATH=$PATH
|
||||
PATH=/bin:/sbin:/usr/bin:/usr/sbin
|
||||
|
@ -75,6 +82,36 @@ cat >$SPECIAL_FILE << EOF
|
|||
<xsl:when test="@id='xorg7'"/>
|
||||
EOF
|
||||
|
||||
# Non-versionned packages. Add to NV_LIST if you need more.
|
||||
for nv_id in $NV_LIST; do
|
||||
cat >>$SPECIAL_FILE << EOF
|
||||
<xsl:when test="@id='$nv_id'">
|
||||
<xsl:text> </xsl:text>
|
||||
<package><xsl:text>
 </xsl:text>
|
||||
<xsl:element name="name">$nv_id</xsl:element>
|
||||
<xsl:text>
 </xsl:text>
|
||||
<xsl:element name="version">1.0.0</xsl:element>
|
||||
<xsl:if
|
||||
test="document(\$installed-packages)//package[name=current()/@id]">
|
||||
<xsl:text>
 </xsl:text>
|
||||
<xsl:element name="inst-version">
|
||||
<xsl:value-of
|
||||
select="document(\$installed-packages
|
||||
)//package[name=current()/@id]/version"/>
|
||||
</xsl:element>
|
||||
</xsl:if>
|
||||
<!-- Dependencies -->
|
||||
<xsl:apply-templates select=".//para[@role='required' or
|
||||
@role='recommended' or
|
||||
@role='optional']"
|
||||
mode="dependency"/>
|
||||
<!-- End dependencies -->
|
||||
<xsl:text>
 </xsl:text>
|
||||
</package><xsl:text>
</xsl:text>
|
||||
</xsl:when>
|
||||
EOF
|
||||
done
|
||||
|
||||
# Taking packages inside x7proto etc, as versionned modules.
|
||||
# We also write a dependency expansion when a dep is of the form
|
||||
# xorg7-something. Since that is another template, we need
|
||||
|
|
Reference in a new issue