The preceding fix is just a workaround, but the correct fix is:

- the problem is when a .dep file contains pack-A pack-B pack-A. If pack-A
and pack-B have some dep in common, say pack-C, that dep is erased from
pack-B, with the idea that it will be built as a dep of pack-A. But when
the program encounters the second pack-A, it removes the first one, so that
pack-C is built before the second pack-A, but after pack-B. Sorting was
a good workaround, but removing the last line instead of the first is
much better.
- Otherwise, add Xfce and Lxde to the list of packages whose preceding
sibling is a required dep.
This commit is contained in:
Pierre Labastie 2015-02-22 21:20:37 +00:00
parent d607ac3717
commit bd07ef520f
2 changed files with 5 additions and 3 deletions

View file

@ -113,7 +113,6 @@ of ${BOLD}${DepFile%.dep}${OFF}"
../xsl/dependencies.xsl ../packages.xml
if [[ -f ${id_of_dep}.dep ]]; then
sort ${id_of_dep}.dep -o ${id_of_dep}.dep
sed -i "1i${rootlink[*]} $count" ${id_of_dep}.dep
generate_dependency_tree ${id_of_dep}.dep
# Test return value, in case we exchange dependencies
@ -152,7 +151,7 @@ echo -en "\n End: $depth${spaceSTR:0:$depth}${GREEN}$DepFile${OFF}"
# so first get the number of first line and then delete
# that line
for line in $lines_to_remove
do lineno=$(sed -n /^$line\$/= $DepFile | head -n1)
do lineno=$(sed -n /^$line\$/= $DepFile | tail -n1)
sed -i ${lineno}d $DepFile
done
return 0

View file

@ -202,7 +202,10 @@
<!-- Dependencies -->
<!-- If in Xorg (not anymore) or KDE chapter, consider that the preceding
package is the first dependency (not always noted in the book)-->
<xsl:if test="ancestor::chapter[@id='kde4-core']">
<xsl:if test="ancestor::chapter[@id='kde4-core'
or @id='xfce-core'
or @id='lxde-desktop']
and preceding-sibling::sect1[1]">
<xsl:text>
</xsl:text>
<xsl:element name="dependency">