Bug 398263 - kdoctools man page build should depend on all-l10n.xml
Summary: kdoctools man page build should depend on all-l10n.xml
Status: RESOLVED FIXED
Alias: None
Product: frameworks-kdoctools
Classification: Frameworks and Libraries
Component: general (show other bugs)
Version: 5.49.0
Platform: Other Linux
: NOR normal
Target Milestone: ---
Assignee: Documentation Editorial Team
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2018-09-04 18:01 UTC by Bernhard M. Wiedemann
Modified: 2018-10-29 17:49 UTC (History)
2 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Bernhard M. Wiedemann 2018-09-04 18:01:34 UTC
While working on reproducible builds for openSUSE, I found that
there is a parallelism-related race:
When building openSUSE's kdoctools package with a 1-core-VM using
osc build -j1

it creates different man-pages than with a 4-core-VM
osc build -j4


diffs include:

--- old//usr/share/man/man1/checkXML5.1 2018-08-26 03:25:41.086296212 +0000
+++ new//usr/share/man/man1/checkXML5.1 2018-08-26 03:25:41.098296086 +0000
@@ -5,9 +5,9 @@
 .\"      Date: 2014-03-04
 .\"    Manual: checkXML5 User's Manual
 .\"    Source: KDE Frameworks Frameworks 5.0
-.\"  Language: English
+.\"  Language:

-.SH "NAME"
+.SH ""
 checkXML5 \- An XML lint tool for KDE DocBook XML documents\&.
-.SH "SYNOPSIS"
+.SH ""
 .HP \w'\fBcheckXML5\fR\ 'u
 \fBcheckXML5\fR [\fIfilename\fR]
-.SH "DESCRIPTION"
+.SH "Description"



I think, this comes from a
I/O warning : failed to load external entity "/home/abuild/rpmbuild/BUILD/kdoctools-5.49.0/build/src/customization/xsl/all-l10n.xml" 
that only happens in the -j1 case
in the output of kdoctools-5.49.0/build/bin/meinproc5


Looking through the source, all-l10n.xml seems to be generated by docbookl10n
but there is nothing telling cmake about this dependency, so it is scheduled at different times before/after the man pages get generated:

difflog | grep "Built target docbookl10n"
+ [  8%] Built target docbookl10nhelper_autogen
+ [ 25%] Built target docbookl10nhelper
- [ 94%] Built target docbookl10nhelper_autogen
- [100%] Built target docbookl10nhelper
Comment 1 Albert Astals Cid 2018-10-28 23:00:02 UTC
Can you give https://phabricator.kde.org/D16500 a try?
Comment 2 Bernhard M. Wiedemann 2018-10-29 09:49:21 UTC
Yes, that patch fixes the race.
Comment 3 Albert Astals Cid 2018-10-29 17:49:43 UTC
Git commit 002940d2e0c35ba3968180fa3769eb5673be4a66 by Albert Astals Cid.
Committed on 29/10/2018 at 17:49.
Pushed by aacid into branch 'master'.

Wait for docbookl10nhelper to be built before building our own manpages

Subscribers: kde-frameworks-devel, kde-doc-english, ltoscano

Tags: #frameworks, #documentation

Differential Revision: https://phabricator.kde.org/D16500

M  +4    -1    KF5DocToolsMacros.cmake

https://commits.kde.org/kdoctools/002940d2e0c35ba3968180fa3769eb5673be4a66