[GRASS5] Gmakefile question
Glynn Clements
glynn.clements at virgin.net
Wed Jan 15 21:07:56 EST 2003
Laura I. Toma wrote:
> I am trying to write a Gmakefile that creates two executables, A and B.
> A and B are identical, except that they should be compiled with different
> flags.
>
> CFLAGS += ...
>
> all: A B
>
> #OBJ should be compiled with -DELEV_FLOAT
> A: $(OBJ)
> $(CC) $(LDFLAGS) -o $@ $(OBJ) $(LIBS)
>
> #OBJ should be compiled with -DELEV_SHORT
> B: $(OBJ)
> $(CC) $(LDFLAGS) -o $@ $(OBJ) $(LIBS)
>
> the .o files in OBJ are compiled using CFLAGS. Anybody knows how to change
> the CFLAGS inside a rule? or how to get around this?
This is something which the GRASS5 build system doesn't support. The
only solution is to use separate directories with separate Gmakefiles.
--
Glynn Clements <glynn.clements at virgin.net>
More information about the grass-dev
mailing list