On 17.09.2010 10:33, Philip Guenther wrote:
On Thu, Sep 16, 2010 at 6:21 PM, 董理<[email protected]> wrote:
I want to write a rule with multiple targets as following:
${TARGET}: $(addsuffix .F90, $@) ${OBJECT}
...
You almost certainly do not want a multiple target rule, because that
would make *each* ${TARGET} depend on *all* the matching .F90 source
files: changing *any* source file would require recompiling *all* the
target files!
Instead, I think you want just a static pattern rule, such as
${TARGET}: %: %.F90 ${OBJECT}
...
Another possibility use .SECONDEXPANSION, but this case unusual
(look to duplicated $$ sign!):
.SECONDEXPANSION:
${TARGET}: $$(addsuffix .F90,$$@) ${OBJECT}
--
С уважением, Александр Гавенко.
_______________________________________________
Help-make mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/help-make