Re: [exim-dev] Patch: Makefile-Base

Kezdőlap
Üzenet törlése
Válasz az üzenetre
Szerző: Phil Pennock
Dátum:  
Címzett: Frank Elsner, Exim Development
Tárgy: Re: [exim-dev] Patch: Makefile-Base
On 2010-08-03 at 13:00 -0400, Phil Pennock wrote:
> On 2010-08-02 at 12:29 +0200, Frank Elsner wrote:
> >  eximon.bin: $(EXIMON_EDITME) eximon $(OBJ_MONBIN) \
> >              ../exim_monitor/em_version.c
> >      @echo "$(CC) exim_monitor/em_version.c"
> > -    $(FE)$(CC) -o em_version.o -c \
> > +    $(FE)$(CC) $(CFLAGS) -o em_version.o -c \
> >        $(CFLAGS) $(XINCLUDE) -I. ../exim_monitor/em_version.c
> >      @echo "$(LNCC) -o eximon.bin"
> > -    $(FE)$(PURIFY) $(LNCC) -o eximon.bin em_version.o $(LFLAGS) $(XLFLAGS) \
> > +    $(FE)$(PURIFY) $(LNCC) $(CFLAGS) -o eximon.bin em_version.o $(LFLAGS) $(XLFLAGS) \
> >      $(OBJ_MONBIN) -lXaw -lXmu -lXt -lXext -lX11 $(PCRE_LIBS) \
> >        $(LIBS) $(LIBS_EXIMON) $(EXTRALIBS) $(EXTRALIBS_EXIMON) -lc
> >      @if [ x"$(STRIP_COMMAND)" != x"" ]; then \

>
> The second change here is again an attempt to use compiler flags as
> arguments to the linker, which may work well enough for some flags for
> gcc, but is not portable.
>
> The first change here is more interesting. It looks like we are missing
> a CFLAGS for compiling the version object file which will later be
> linked into the eximon binary. I can see that for some flags, such as
> -fPIC, this might be problematic. So that change should certainly go
> in.


Oops, no, CFLAGS is already there in the command-line, before the item
being compiled, so you've just put $(CFLAGS) into the command-line
twice.