Bug 222857 - Failed to "make po" for the handbook
Summary: Failed to "make po" for the handbook
Status: Closed FIXED
Alias: None
Product: Documentation
Classification: Unclassified
Component: Books & Articles (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Only Me
Assignee: Wolfram Schneider
URL:
Keywords:
Depends on: 222631
Blocks:
  Show dependency treegraph
 
Reported: 2017-10-08 08:57 UTC by Guangyuan Yang
Modified: 2018-08-01 19:36 UTC (History)
7 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Guangyuan Yang freebsd_committer freebsd_triage 2017-10-08 08:57:53 UTC
I am trying to switch zh_CN/books/handbook to use PO translate. Following the instruction in FDP Primer, I cleared the directory, copied and modified the Makefile. However, I still cannot make po out of it. The error message is as follow:

➜  handbook make po
warning: failed to load external entity "/usr/home/guangyuan/fbdev/doc/en_US.ISO8859-1/books/handbook/mirrors.xml.ftp.index.inc"
/usr/home/guangyuan/fbdev/doc/en_US.ISO8859-1/books/handbook/mirrors/chapter.xml:129: parser error : Failure to process entity chap.mirrors.ftp.index.inc
    &chap.mirrors.ftp.index.inc;
                                ^
/usr/home/guangyuan/fbdev/doc/en_US.ISO8859-1/books/handbook/mirrors/chapter.xml:129: parser error : Entity 'chap.mirrors.ftp.index.inc' not defined
    &chap.mirrors.ftp.index.inc;
                                ^
warning: failed to load external entity "/usr/home/guangyuan/fbdev/doc/en_US.ISO8859-1/books/handbook/mirrors.lastmod.inc"
/usr/home/guangyuan/fbdev/doc/en_US.ISO8859-1/books/handbook/mirrors/chapter.xml:131: parser error : Failure to process entity chap.mirrors.lastmod.inc
    &chap.mirrors.lastmod.inc;
                              ^
/usr/home/guangyuan/fbdev/doc/en_US.ISO8859-1/books/handbook/mirrors/chapter.xml:131: parser error : Entity 'chap.mirrors.lastmod.inc' not defined
    &chap.mirrors.lastmod.inc;
                              ^
warning: failed to load external entity "/usr/home/guangyuan/fbdev/doc/en_US.ISO8859-1/books/handbook/mirrors.xml.ftp.inc"
/usr/home/guangyuan/fbdev/doc/en_US.ISO8859-1/books/handbook/mirrors/chapter.xml:133: parser error : Failure to process entity chap.mirrors.ftp.inc
    &chap.mirrors.ftp.inc;
                          ^
/usr/home/guangyuan/fbdev/doc/en_US.ISO8859-1/books/handbook/mirrors/chapter.xml:133: parser error : Entity 'chap.mirrors.ftp.inc' not defined
    &chap.mirrors.ftp.inc;
                          ^
/usr/home/guangyuan/fbdev/doc/en_US.ISO8859-1/books/handbook/mirrors/chapter.xml:538: parser error : chunk is not well balanced

^
/usr/home/guangyuan/fbdev/doc/en_US.ISO8859-1/books/handbook/book.xml:310: parser error : Failure to process entity chap.mirrors
    &chap.mirrors;
                  ^
/usr/home/guangyuan/fbdev/doc/en_US.ISO8859-1/books/handbook/book.xml:310: parser error : Entity 'chap.mirrors' not defined
    &chap.mirrors;
                  ^
warning: failed to load external entity "/usr/home/guangyuan/fbdev/doc/en_US.ISO8859-1/books/handbook/eresources.xml.www.index.inc"
/usr/home/guangyuan/fbdev/doc/en_US.ISO8859-1/books/handbook/eresources/chapter.xml:2408: parser error : Failure to process entity chap.eresources.www.index.inc
    &chap.eresources.www.index.inc;
                                   ^
/usr/home/guangyuan/fbdev/doc/en_US.ISO8859-1/books/handbook/eresources/chapter.xml:2408: parser error : Entity 'chap.eresources.www.index.inc' not defined
    &chap.eresources.www.index.inc;
                                   ^
warning: failed to load external entity "/usr/home/guangyuan/fbdev/doc/en_US.ISO8859-1/books/handbook/mirrors.lastmod.inc"
/usr/home/guangyuan/fbdev/doc/en_US.ISO8859-1/books/handbook/eresources/chapter.xml:2410: parser error : Failure to process entity chap.mirrors.lastmod.inc
    &chap.mirrors.lastmod.inc;
                              ^
/usr/home/guangyuan/fbdev/doc/en_US.ISO8859-1/books/handbook/eresources/chapter.xml:2410: parser error : Entity 'chap.mirrors.lastmod.inc' not defined
    &chap.mirrors.lastmod.inc;
                              ^
warning: failed to load external entity "/usr/home/guangyuan/fbdev/doc/en_US.ISO8859-1/books/handbook/eresources.xml.www.inc"
/usr/home/guangyuan/fbdev/doc/en_US.ISO8859-1/books/handbook/eresources/chapter.xml:2412: parser error : Failure to process entity chap.eresources.www.inc
    &chap.eresources.www.inc;
                             ^
/usr/home/guangyuan/fbdev/doc/en_US.ISO8859-1/books/handbook/eresources/chapter.xml:2412: parser error : Entity 'chap.eresources.www.inc' not defined
    &chap.eresources.www.inc;
                             ^
/usr/home/guangyuan/fbdev/doc/en_US.ISO8859-1/books/handbook/eresources/chapter.xml:2449: parser error : chunk is not well balanced

^
/usr/home/guangyuan/fbdev/doc/en_US.ISO8859-1/books/handbook/book.xml:312: parser error : Failure to process entity chap.eresources
    &chap.eresources;
                     ^
/usr/home/guangyuan/fbdev/doc/en_US.ISO8859-1/books/handbook/book.xml:312: parser error : Entity 'chap.eresources' not defined
    &chap.eresources;
                     ^
*** Error code 1

Stop.
make: stopped in /usr/home/guangyuan/fbdev/doc/zh_CN.UTF-8/books/handbook
Comment 1 Guangyuan Yang freebsd_committer freebsd_triage 2017-10-08 13:13:54 UTC
For the reference, I tried "make po" under zh_TW.UTF-8/books/handbook with only its Makefile existing, it failed and gave me the same error.
Comment 2 Fukang Chen freebsd_committer freebsd_triage 2017-10-08 17:50:58 UTC
Those .inc files were generated from en_US.ISO8859-1/share/xml/mirrors.xml by xsltproc,
please try to run 'make' in en_US.ISO8859-1/books/handbook/ first.
Comment 3 Fukang Chen freebsd_committer freebsd_triage 2017-10-09 04:08:48 UTC
Thanks wosch@,  it seems the ${DOC}.translate.xml: target only builds the ${SRCS}
https://svnweb.freebsd.org/doc/head/share/mk/doc.docbook.mk?revision=50877&view=markup&pathrev=50951#l347

and ${EXTRAS} files are only used in the mirrors chapter,  just a thought:

Index: en_US.ISO8859-1/books/handbook/Makefile
===================================================================
--- en_US.ISO8859-1/books/handbook/Makefile	(revision 51083)
+++ en_US.ISO8859-1/books/handbook/Makefile	(working copy)
@@ -251,6 +251,6 @@
 
 XMLDOCS_NO_SRCS=YES
 CLEANFILES+= ${EXTRAS}
-index.html ${DOC}.html: ${EXTRAS}
+mirrors/chapter.xml: ${EXTRAS}
 
 .include "${DOC_PREFIX}/share/mk/doc.project.mk"
Comment 4 commit-hook freebsd_committer freebsd_triage 2017-10-11 11:30:03 UTC
A commit references this bug:

Author: wosch
Date: Wed Oct 11 11:29:30 UTC 2017
New revision: 51099
URL: https://svnweb.freebsd.org/changeset/doc/51099

Log:
  improve dependencies checking for the mirror chapter

  Submitted by: loader
  PR: 222857
  (and in part PR: 222631)

Changes:
  head/en_US.ISO8859-1/books/handbook/Makefile