can you please comment on 62246 or add documentation for it? Commit message does not tell much, it is not (yet?) used anywhere and I don’t understand the relation to %reldir% [1].
can you please comment on 62246 or add documentation for it? Commit message
does not tell much,
$(RELDIR) is simply the current directory relative to the root of the
GRASS source tree.
it is not (yet?) used anywhere
I have no plans to use in the Makefiles. I added it mainly so that the
user can use e.g.
make 'OBJDIR=$(GRASS_HOME)/OBJ.$(ARCH)/$(RELDIR)' ...
to place all[1] intermediate files in a single directory (which
doesn't have to be within the GRASS source tree) rather than scattered
throughout the source directory. This may be desirable for multiple
builds for a single $(ARCH) or for performing builds from a read-only
source tree.
[1] Currently, the files generated by lex/yacc are placed in the
source directory rather than in $(OBJDIR).
and I don't understand the relation to %reldir% [1].
On Tue, Oct 21, 2014 at 4:08 AM, Glynn Clements
<glynn@gclements.plus.com> wrote:
Vaclav Petras wrote:
can you please comment on 62246 or add documentation for it? Commit message
does not tell much,
$(RELDIR) is simply the current directory relative to the root of the
GRASS source tree.
it is not (yet?) used anywhere
I have no plans to use in the Makefiles. I added it mainly so that the
user can use e.g.
make 'OBJDIR=$(GRASS_HOME)/OBJ.$(ARCH)/$(RELDIR)' ...
to place all[1] intermediate files in a single directory (which
doesn't have to be within the GRASS source tree) rather than scattered
throughout the source directory. This may be desirable for multiple
builds for a single $(ARCH) or for performing builds from a read-only
source tree.
[1] Currently, the files generated by lex/yacc are placed in the
source directory rather than in $(OBJDIR).
Would that also address (to some extent) this request?
> I have no plans to use in the Makefiles. I added it mainly so that the
> user can use e.g.
>
> make 'OBJDIR=$(GRASS_HOME)/OBJ.$(ARCH)/$(RELDIR)' ...
>
> to place all[1] intermediate files in a single directory (which
> doesn't have to be within the GRASS source tree) rather than scattered
> throughout the source directory. This may be desirable for multiple
> builds for a single $(ARCH) or for performing builds from a read-only
> source tree.
>
> [1] Currently, the files generated by lex/yacc are placed in the
> source directory rather than in $(OBJDIR).
Would that also address (to some extent) this request?
FWIW, that approach was usually possible before (occasionally I've had
to clean up issues that prevent it); this change just lets you remove
the unnecessary $(GRASS_HOME) prefix from the subdirectories.
OTOH, it's probably still not sufficient for most of the cases where
you need an out-of-place build. The files generated by configure go
into the source tree, so you can't perform multiple concurrent builds
for different architectures because there's only one config.h,
Platform.make, etc.
Other files which go into the source tree include the files generated
by lex/yacc, the *_to_translate.c files generated for scripts, and the
pyc files generated when importing Python modules.
To get a complete list, build with the above OBJDIR= setting then use
"svn status --no-ignore" afterwards.
The normal way to implement out-of-tree builds is to run configure and
make with the build directory as the current directory and add the
source directory to VPATH. But this would require some work on the
Makefiles to get it to work.