Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Makefile: fix occasional race where we fail to compile tools/tests. #2962

Conversation

rustyrussell
Copy link
Contributor

This simplifies the dependencies:

  1. Objs depend on headers, not other objs.
  2. Programs depend on objs.
  3. A .o file will generally implicitly depend on the .c file it's built from.
  4. If a file has a build line, it's often better to list all deps there.
  5. I spotted some missing 'make clean' files.

The particular problem in this case seems to be that make would use
tools/test/gen_test.c before it was ready. It's probably confused by
the use of recursive make via update-mocks, so explicitly split that
into two stages.

Signed-off-by: Rusty Russell rusty@rustcorp.com.au

This simplifies the dependencies:
1. Objs depend on headers, not other objs.
2. Programs depend on objs.
3. A .o file will generally implicitly depend on the .c file it's built from.
4. If a file has a build line, it's often better to list all deps there.
5. I spotted some missing 'make clean' files.

The particular problem in this case seems to be that make would use
tools/test/gen_test.c before it was ready.  It's probably confused by
the use of recursive make via update-mocks, so explicitly split that
into two stages.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
@rustyrussell rustyrussell added this to the 0.7.2 milestone Aug 16, 2019
@cdecker
Copy link
Member

cdecker commented Aug 16, 2019

ACK bd2c860

@rustyrussell rustyrussell merged commit dbb15b0 into ElementsProject:master Aug 17, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants