Bug 222488 - `make all' does not work together with `make obj'
Summary: `make all' does not work together with `make obj'
Status: Closed Overcome By Events
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:
Blocks:
 
Reported: 2017-09-21 11:51 UTC by Wolfram Schneider
Modified: 2017-10-06 10:44 UTC (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Wolfram Schneider freebsd_committer freebsd_triage 2017-09-21 11:51:34 UTC
I tried to run `make obj' first, and then `make all'. It fails with the error message:

===> en_US.ISO8859-1/articles/pam (all)
fatal: pam_app.c: no such path in the working tree.
Use 'git <command> -- <path>...' to specify paths that do not exist locally.
make[3]: "/home/projects/freebsd-doc/en_US.ISO8859-1/articles/pam/../../../share/mk/doc.docbook.mk" line 101: warning: "cd /home/projects/freebsd-doc/en_US.ISO8859-1/articles/pam && /usr/local/bin/git log -1 --pretty=format:' --stringparam latestrevision.timestamp "%ci"  --stringparam latestrevision.committer "%cn"  --stringparam latestrevision.number "%h"' article.xml pam_app.c pam_conv.c pam_module.c" returned non-zero status
sed -e '/^[\/ ]\*/d' /home/projects/freebsd-doc/en_US.ISO8859-1/articles/pam/su.c >pam_app.c
sed -e '/^[\/ ]\*/d' /home/projects/freebsd-doc/en_US.ISO8859-1/articles/pam/converse.c >pam_conv.c
sed -e '/^[\/ ]\*/d' /home/projects/freebsd-doc/en_US.ISO8859-1/articles/pam/pam_unix.c >pam_module.c
install /home/projects/freebsd-doc/share/xml/catalog-cwd.xml /usr/obj/home/projects/freebsd-doc/en_US.ISO8859-1/articles/pam/catalog-cwd.xml
echo '<!ENTITY base "..">' >> /usr/obj/home/projects/freebsd-doc/en_US.ISO8859-1/articles/pam/autogen.ent
env XML_CATALOG_FILES="file:///usr/obj/home/projects/freebsd-doc/en_US.ISO8859-1/articles/pam/catalog-cwd.xml  file:///home/projects/freebsd-doc/en_US.ISO8859-1/share/xml/catalog.xml  file:///home/projects/freebsd-doc/share/xml/catalog.xml  file:///usr/local/share/xml/catalog" /usr/local/bin/xmllint --nonet --noent --valid --dropdtd --xinclude /home/projects/freebsd-doc/en_US.ISO8859-1/articles/pam/article.xml > article.parsed.xml.tmp
/bin/mv article.parsed.xml.tmp article.parsed.xml
/usr/bin/sed 's|@@URL_RELPREFIX@@|http://www.FreeBSD.org|g' < article.parsed.xml > article.parsed.print.xml
/usr/bin/sed -i '' -e 's|@@URL_RELPREFIX@@|../../../..|g' article.parsed.xml
/bin/rm -f /usr/obj/home/projects/freebsd-doc/en_US.ISO8859-1/articles/pam/docbook.css
/bin/cat /home/projects/freebsd-doc/share/misc/docbook.css > /usr/obj/home/projects/freebsd-doc/en_US.ISO8859-1/articles/pam/docbook.css
env XML_CATALOG_FILES="file:///usr/obj/home/projects/freebsd-doc/en_US.ISO8859-1/articles/pam/catalog-cwd.xml  file:///home/projects/freebsd-doc/en_US.ISO8859-1/share/xml/catalog.xml  file:///home/projects/freebsd-doc/share/xml/catalog.xml  file:///usr/local/share/xml/catalog" /usr/local/bin/xsltproc  --xinclude --nonet --maxvars 20000  http://www.FreeBSD.org/XML/share/xml/freebsd-xhtml.xsl article.parsed.xml > article.html
runtime error: file file:///home/projects/freebsd-doc/share/xml/freebsd-xhtml-common.xsl line 267 element variable
Variable 'latestrevision.number' has not been declared.
xmlXPathCompiledEval: evaluation failed
runtime error: file file:///home/projects/freebsd-doc/share/xml/freebsd-xhtml-common.xsl line 267 element variable
Failed to evaluate the expression of variable 'rev'.
*** Error code 10

Stop.
make[3]: stopped in /home/projects/freebsd-doc/en_US.ISO8859-1/articles/pam
*** Error code 1

Stop.
make[2]: stopped in /home/projects/freebsd-doc/en_US.ISO8859-1/articles
*** Error code 1

Stop.
make[1]: stopped in /home/projects/freebsd-doc/en_US.ISO8859-1
*** Error code 1

Stop.
make: stopped in /home/projects/freebsd-doc
Comment 1 Mathieu Arnold freebsd_committer freebsd_triage 2017-09-21 15:22:54 UTC
My watcher build script actually runs:

make obj && make objlink && make
Comment 2 Wolfram Schneider freebsd_committer freebsd_triage 2017-09-22 12:20:23 UTC
Here ist my test script, it fails on all machines I tried:

svn checkout -q https://svn.FreeBSD.org/doc/head doc
cd doc
rm -rf /usr/obj; (make clean; make obj && make objlink && make) >& log; echo $?
1
Comment 3 Wolfram Schneider freebsd_committer freebsd_triage 2017-09-26 09:33:43 UTC
I'm not sure if it worth to spent time on this. `make obj' is nice to have, not a must have. Other doc build bugs have a higher priority (as files not rebuild after a change)

The workaround to disable "obj" is easy

export NO_OBJ=YES
Comment 4 commit-hook freebsd_committer freebsd_triage 2017-10-06 10:44:24 UTC
A commit references this bug:

Author: wosch
Date: Fri Oct  6 10:44:00 UTC 2017
New revision: 51065
URL: https://svnweb.freebsd.org/changeset/doc/51065

Log:
  'make obj' doesn't really work for the docs, disable it by default

      PR: 222488

Changes:
  head/share/mk/doc.project.mk
  head/share/mk/web.site.mk