Re: install-step fails for pandoc-prebuilt man-pages in infiniband-diags/man

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



> 
>> While investigating, I came up with the following explanation: The
>> hashes (generated by buildlib/pandoc-prebuilt.py) differ from machine to
>> machine, as the contents of the *.rst-files are hashed. Most of these
>> files are processed via cmake's configure_file from *.in.rst-files and
>> contain custom-per-build-data such as absolute paths. This means that
>> hashing *.rst-files will produce differing hashes based on the
>> build-directory-path (among other data points, possibly).
> 
> It is not the build directory path, it is the install directory path,

You are right, the culprit is @IBDIAG_CONFIG_PATH@, which is based on
CMAKE_INSTALL_PREFIX.

> and yes, the no-pandoc builds have to use the standard paths.

Is this documented somewhere?

>> by looking at the hashes produced by two of my machines, they were
>> different for all but 3 files (ibcacheedit.8.rst, ibstatus.8.rst and
>> check_lft_balance.8.rst). These files (and their includes, as their
>> content is also hashed!) are the only files that to not contain any
>> differing data when being transformed from *.in.rst to *.rst via
>> configure_file, which supports my hypothesis.
> This only happens if each machine is configuring to use different
> paths, or something has gone quite wrong. What are the actual diffs
> from the two .rst's ?

This is also correct, I was/am using different CMAKE_INSTALL_PREFIX
paths on my testing machines (mainly due to restrictions in the build
environment). Both paths differ from the one used to produce the
github-release.

>> With my limited time and expertise in the rdma-core project, I was only
>> able to come up with a solution that I don't find very practical. I will
>> append a diff of pandoc-prebuilt.py nonetheless, which replaces
>> hashing-calls for *.rst to *.in.rst if applicable.
> 
> This just makes broken output if pandoc is not present, it is not practical.

The diff just changes the filename from *.rst to *.in.rst before hashing
(get_id()). pandoc/rst2man are still called on the *.rst files (NOT the
*.in.rst files), but the filename is now based on the *.in.rst-file.

> The only good options is to shift the substition to after
> pandoc/rst2man run - but I'm not sure if that is doable..

To my understanding, this is basically what my diff does (although it
does not "shift" the substition, but rather just uses the unsubsituted
files to produce the names (hashes) for the prebuilt documentation). But
as I said previously, I also do not consider it a good fix for the problem.

Thorben



[Index of Archives]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Photo]     [Yosemite News]     [Yosemite Photos]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux