This is the mail archive of the mailing list for the GCC project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Patch: automatic dependencies for gcc

>>>>> "Ralf" == Ralf Wildenhues <> writes:

Ralf> This reveals that depcomp relies on the fact that dependencies for
Ralf> subdir/object.o go in subdir/$(DEPDIR)/object.Po.  Your patch puts
Ralf> them in $(DEPDIR)/subdir/object.Po.

Thanks, I forgot about this.

I'll re-bootstrap on the compile farm with something like this.

Ralf> -COMPILE = $(COMPILE.base) -o $@ -MT $@ -MMD -MP -MF $(DEPDIR)/$*.Po
Ralf> +COMPILE = $(COMPILE.base) -o $@ -MT $@ -MMD -MP -MF $(dir $*)/$(DEPDIR)/$(notdir $*).Po

I think I will change this to use $(*D) and $(*F).

Ralf> --include $(patsubst %.o, $(DEPDIR)/%.Po, $(ALL_HOST_OBJS))
Ralf> +DEPFILES = $(foreach obj, $(ALL_HOST_OBJS), \
Ralf> +	     $(dir $(obj))$(DEPDIR)/$(patsubst %.o,%.Po,$(notdir $(obj))))

This makes it tempting to change depcomp instead  :)

Ralf>  AC_CONFIG_COMMANDS([gccdepdir],[
Ralf> -  ${CONFIG_SHELL-/bin/sh} $ac_aux_dir/mkinstalldirs $DEPDIR/build
Ralf> +  ${CONFIG_SHELL-/bin/sh} $ac_aux_dir/mkinstalldirs build/$DEPDIR
Ralf>    for lang in $subdirs
Ralf>    do
Ralf> -      ${CONFIG_SHELL-/bin/sh} $ac_aux_dir/mkinstalldirs $DEPDIR/$lang
Ralf> +      ${CONFIG_SHELL-/bin/sh} $ac_aux_dir/mkinstalldirs $lang/$DEPDIR
Ralf>    done], [subdirs="$subdirs" ac_aux_dir=$ac_aux_dir DEPDIR=$DEPDIR])
In Quagmire I create necessary directories in the Makefile.  I wonder
whether we should just do that here as well.  I'll take a look.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]