On 2022-08-04, Travis Pressler via Discussion list for automake
<automake@gnu.org> wrote:
> I'm learning how to make an autotools project and have created a test
> project to work with. I ran make with a directory `nested` and then deleted
> it and deleted the reference to it in my `Makefile.am`.
>
> Now I'm running ./configure && make and I get the following:
>
> *** No rule to make target 'nested/main.c', needed by 'main.o'. Stop.
>
> How can I run `make` so that it doesn't reference this old nested
> directory?

Sounds like just some stale dependencies left over from a prior version.

Running "make distclean" should delete all the automatically generated
dependency information and allow the package to be rebuilt normally.

Enabling the Automake subdir-objects feature probably would avoid the
specific scenario that led to your stale dependency problem.

Hope that helps,
  Nick

Reply via email to