Tests that create files fail 'make distcheck' (e.g., the tests for HYRAX-561)

Description

There are two problems I've found:

  1. test_config.h is being built using configure.ac and that puts it in the _build subtree, but because it's built by configure, it's already in the true source tree. When distcheck builds the bes-<ver> source tree, it gets put there as well (because the copy in the 'bes' source tree got added to the source tarball and then extracted to the bes-<ver> source tree). The compiler finds the copy in the bes-<ver> source tree and not the copy in the _build tree. So... the paths in the file that use @top_builddir@ are not compiled into the code.

  2. The source dirs are not writeable, so on a host with automake 1.14.1++ we need to be writing to the build dirs (so we really do need those paths). The tests work on 1.14.0-- because the _test_config.h file used is the one that names the true ('bes' tree, not the 'bes-<ver>' tree) and as a result the temp files, etc. are written in the completely wrong place.

What we need to do:

  1. Figure out how to not include those generated headers in the tarball (idea: mark then as generated sources - there is an option for this).

  2. Build the needed temp dirs in the _build code (now we include those in the (pure) source tree by adding them to git. (idea: use simple code to build them. But how to run those targets and how to clean them up?)

A simple generator target for a directory:

This issue replaces , which we should close, but continuing to work on the hyrax-561 branch to resolve this issue.

Once working correctly we need to stamp and repeat the fix. There are two other places at least where we need this:

  1. fileout_json

  2. w10n_handler

Search for test_config.h.in files that use @top_buiddir@

Environment

None

Activity

Show:
James Gallagher
January 23, 2018, 4:08 PM

The way to make test_config.h:

James Gallagher
January 23, 2018, 6:00 PM

Now I have just one failure - catT segfaults.

Once this is fixed, I'll need to reintegrate the correct configure.ac and modules/Makefile.am and then scan for all instances of test_config.h and make them 'Makefle' generated and not 'configure generated.'

James Gallagher
January 23, 2018, 6:47 PM

Works.

Now the reintegration...

James Gallagher
January 24, 2018, 4:45 AM

Reintegration complete. The only issue after removing all places in configure.ac that built test_config.h and added test_config.h targets to the corresponding Makefile.am files was n dmrpp_handler here $abs_top_srcdir was used - the new target had to be modified to add substitution for that variable.

James Gallagher
January 24, 2018, 6:46 AM

Last bit: write this up. There's a section on the media wiki about it.

Assignee

James Gallagher

Reporter

James Gallagher

Labels

None

Time tracking

0m

Time remaining

0m

Epic Link

Components

Sprint

None

Priority

Highest
Configure