
I see errors like this when using 'make html' in the topdir of the ghc repo: ---- /vol/hosts/cueball/workspace/github/ghc/docs/users_guide/flags.rst:15: SEVERE: Problems with "include" directive path: InputError: [Errno 2] No such file or directory: 'docs/users_guide/flags-verbosity.gen.rst'. ---- What am I doing wrong or not doing? -harendra

Harendra Kumar
I see errors like this when using 'make html' in the topdir of the ghc repo:
Hmm, it looks like there is a missing dependency in the build system. The users guide depends upon a number of ReST source files generated by utils/mkUserGuidePart. I'd guess that you haven't built these. I'll look in to why this is but in the meantime the workaround is just to `make all` before attempting to `make html`. Sorry for the inconvenience! Cheers, - Ben

Well, I tried 'make' and 'make all' (I suppose they are both same) but that
did not make any difference.
-harendra
On 23 August 2016 at 21:37, Ben Gamari
Harendra Kumar
writes: I see errors like this when using 'make html' in the topdir of the ghc repo:
Hmm, it looks like there is a missing dependency in the build system. The users guide depends upon a number of ReST source files generated by utils/mkUserGuidePart. I'd guess that you haven't built these. I'll look in to why this is but in the meantime the workaround is just to `make all` before attempting to `make html`. Sorry for the inconvenience!
Cheers,
- Ben

I got to the bottom of the problem after some debugging. The short summary
is - I was using "devel2" flavor which disables doc targets. The problem
was it only disables them partially not fully. So even though I was able to
invoke the targets I got these errors and the guide is mostly built except
for the flags refs.
The long story:
devel2.mk sets: BUILD_SPHINX_HTML = NO
But we 'include rules/sphinx.mk' in ghc.mk unconditionally. Now, since
BUILD_SPHINX_HTML is not set we filter out mkUserGuidePart from build
targets:
BUILD_DIRS := $(filter-out utils/mkUserGuidePart,$(BUILD_DIRS))
This results in an inconsistent state of the doc targets being available
but not the mkUserGuidePart rules. So even though I was able build the docs
partially I was getting these errors.
-harendra
On 23 August 2016 at 22:31, Harendra Kumar
Well, I tried 'make' and 'make all' (I suppose they are both same) but
that did not make any difference.
-harendra
On 23 August 2016 at 21:37, Ben Gamari
wrote: Harendra Kumar
writes: I see errors like this when using 'make html' in the topdir of the ghc
repo:
Hmm, it looks like there is a missing dependency in the build system. The users guide depends upon a number of ReST source files generated by utils/mkUserGuidePart. I'd guess that you haven't built these. I'll look in to why this is but in the meantime the workaround is just to `make all` before attempting to `make html`. Sorry for the inconvenience!
Cheers,
- Ben

Harendra Kumar
I got to the bottom of the problem after some debugging. The short summary is - I was using "devel2" flavor which disables doc targets. The problem was it only disables them partially not fully. So even though I was able to invoke the targets I got these errors and the guide is mostly built except for the flags refs.
Good sleuthing! I suppose the Sphinx html targets should simply fail with an error when BUILD_SPHINX_HTML is not set. The right place to fix this is likely rules/sphinx.mk if you are interested in fixing this. Cheers, - Ben

I already fixed it - https://phabricator.haskell.org/D2470 .
On 24 August 2016 at 00:39, Ben Gamari
Harendra Kumar
writes: I got to the bottom of the problem after some debugging. The short summary is - I was using "devel2" flavor which disables doc targets. The problem was it only disables them partially not fully. So even though I was able to invoke the targets I got these errors and the guide is mostly built except for the flags refs.
Good sleuthing!
I suppose the Sphinx html targets should simply fail with an error when BUILD_SPHINX_HTML is not set. The right place to fix this is likely rules/sphinx.mk if you are interested in fixing this.
Cheers,
- Ben
participants (2)
-
Ben Gamari
-
Harendra Kumar