Hi,

I am having some troubles with a Makefile:

```
phony-targets = force

.SECONDEXPANSION:
.PHONY: $$(phony-targets)

test: force
    @echo test
```

The makefile works fine when using make 4.3 and "test" is printed as it
should. When using make 4.4.1, I get the error "No rule to make target
'force', needed by 'test'. Stop." This looks to be related to the
change in 4.4 where secondary expansion was narrowed to only the
targets that are considered. I would guess that .PHONY is not
considered during the build, and so doesn't get the secondary expansion
treatment. force is then never mentioned and isn't considered a target.
The makefile does what it is intended to do using make 4.4.1 when I
remove .SECONDEXPANSION (and change $$ -> $), or when I explicitly
mention force as .PHONY. Is this working as intended on make 4.4.1, or
is this a regression in functionality?

Regards
Eskil

Reply via email to