bug-make
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: Implicit rule with multiple targets "forgets" to build a target


From: Michael Bos
Subject: RE: Implicit rule with multiple targets "forgets" to build a target
Date: Mon, 17 Jun 2013 23:32:02 +0000

Hello,

 

Please ignore this question, I found the answer in the documentation:

 

“Pattern rules may have more than one target. Unlike normal rules, this does not act as many different rules with the same prerequisites and recipe. If a pattern rule has multiple targets, make knows that the rule's recipe is responsible for making all of the targets. The recipe is executed only once to make all the targets. When searching for a pattern rule to match a target, the target patterns of a rule other than the one that matches the target in need of a rule are incidental: make worries only about giving a recipe and prerequisites to the file presently in question. However, when this file's recipe is run, the other targets are marked as having been updated themselves.”

 

Sorry.

Greetings

Michael Bos

 

From: Michael Bos
Sent: Dienstag, 18. Juni 2013 01:24
To: 'address@hidden'
Subject: Implicit rule with multiple targets "forgets" to build a target

 

Hello,

 

When running “make –f Makefile.bad” (attached) I get the following output:

 

Generate 'E.1'

Creating 'A1B/C' from 'E.1' with stem '1'

Generate 'E.2'

Creating 'A2B/C' from 'E.2' with stem '

 

As you can see the targets A1B/D and A2B/D are not generated (I do not have any files with such names in my directory).

 

When splitting the multi-target rule into two implicit rules the missing targets are generated (“make –f Makefile.ok”, attached):

 

Generate 'E.1'

Creating 'A1B/C' from 'E.1' with stem '1'

Creating 'A1B/D' from 'E.1' with stem '1'

Generate 'E.2'

Creating 'A2B/C' from 'E.2' with stem '2'

Creating 'A2B/D' from 'E.2' with stem '2'

 

According to the documentation there should be no difference:

“4.10 Multiple Targets in a Rule: A rule with multiple targets is equivalent to writing many rules, each with one target, and all identical aside from that.”

 

What’s wrong with my argumentation?

 

I am using GNU Make 3.81 under RedHat5.

 

Thanks in advance.

Greetings

Michael

 

___________________________________________________________________

 

Michael Bos

Principal Physical Verification Engineer (CAD)

 

Direct Dial: +49 (0)7021 805-255 | Fax: +49 (0)7021 805-100

address@hidden |  www.diasemi.com

 

Dialog Semiconductor GmbH, Neue Strasse 95, D-73230 Kirchheim/Teck-Nabern, Germany

___________________________________________________________________

 

 


Dialog Semiconductor GmbH
Neue Str. 95
D-73230 Kirchheim
Managing Directors: Dr. Jalal Bagherli, Jean-Michel Richard
Chairman of the Supervisory Board: Gregorio Reyes
Commercial register: Amtsgericht Stuttgart: HRB 231181
UST-ID-Nr. DE 811121668

Legal Disclaimer: This e-mail communication (and any attachment/s) is confidential and contains proprietary information, some or all of which may be legally privileged. It is intended solely for the use of the individual or entity to which it is addressed. Access to this email by anyone else is unauthorized. If you are not the intended recipient, any disclosure, copying, distribution or any action taken or omitted to be taken in reliance on it, is prohibited and may be unlawful.


Please consider the environment before printing this e-mail

 


reply via email to

[Prev in Thread] Current Thread [Next in Thread]