axiom-developer
[Top][All Lists]
Advanced

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

[Axiom-developer] RE: generalized makefile rules


From: Weiss, Juergen
Subject: [Axiom-developer] RE: generalized makefile rules
Date: Thu, 14 Aug 2003 22:03:20 +0200

Hi Tim,

David's suggestions should do what you want. In my makefile
I used "static pattern rules", that is the rules are
applied only to the files mentioned before the first :.
If you omit the first part, you get normal rules which
may get applied to matching targets. This may be even
more elegant. If you have serveral rules, which match 
the same target, make tries to find out, which prerequisites
exists or which can be generated by other rules. That is for
specific targets, you can have a general rule and a target specific
rule. The specific target specific. With static pattern rules
you get at least a warning. Details in the info file for
gnu make. I'm not really an expert in gnu make. I just
experimented a bit and read parts of the documentation.
 
Regards

Juergen

Juergen Weiss     | Universitaet Mainz, Zentrum fuer Datenverarbeitung,
address@hidden| 55099 Mainz, Tel: +49(6131)39-26361, FAX:
+49(6131)39-26407


> -----Original Message-----
> From: root [mailto:address@hidden 
> Sent: Thursday, August 14, 2003 8:38 PM
> To: Weiss, Juergen
> Cc: address@hidden; address@hidden
> Subject: generalized makefile rules
> 
> 
> Juergen,
> 
> You're clearly much better at makefile syntax than I am. I want to 
> generalize the following pattern so that FOO matches each file:
> 
> ${OUT}/FOO.o: ${MID}/FOO.NRLIB
>       echo making ${OUT}/FOO.o from ${MID}/FOO.NRLIB
>       cp ${MID}/FOO.NRLIB/code.o ${OUT}/FOO.o
> 
> ${MID}/FOO.NRLIB: ${MID}/FOO.spad
>       echo making ${MID}/FOO.NRLIB from ${MID}/FOO.spad
>       (cd ${MID} ; echo ')co FOO.spad' | ${INTERPSYS}
> 
> I remember that there is a generalized replacement variable that
> matches the name of the expanding file but I don't know what it is.
> 
> Tim
> address@hidden
> address@hidden
> 




reply via email to

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