On Thu, Nov 6, 2014 at 8:59 AM, Glynn Clements <[email protected]> wrote: > > Radim Blazek wrote: > >> > +++ include/Make/Compile.make (working copy) >> >> > +ALL_CFLAGS = $(LFS_CFLAGS) $(EXTRA_CFLAGS) $(NLS_CFLAGS) $(DEFS) >> > $(EXTRA_INC) $(INC) -DRELDIR=\"$(RELDIR)\" >> >> > +#define G_malloc(n) G__malloc(RELDIR "/" __FILE__, __LINE__, (n)) >> > +#define G_calloc(m, n) G__calloc(RELDIR "/" __FILE__, __LINE__, (m), (n)) >> > +#define G_realloc(p, n) G__realloc(RELDIR "/" __FILE__, __LINE__, (p), >> > (n)) >> >> With RELDIR defined in Grass.make it is impossible to compile anything >> with GRASS libs without GRASS build system. Could you please add the >> RELDIR definition to some header file? > > $(RELDIR) is just $(CURDIR) minus $(GRASS_HOME): > > RELDIR := $(subst $(GRASS_HOME)/,,$(CURDIR)) > > Like $(CURDIR), it's different for each subdirectory, so it's not > something which can be put into a header file. > > However, it's also not used for anything other than error messages, so > compiling with e.g. -DRELDIR= or -DRELDIR=\"$(CURDIR)\" is safe. > > I've added a fallback in r62632.
Thanks Radim > -- > Glynn Clements <[email protected]> _______________________________________________ grass-dev mailing list [email protected] http://lists.osgeo.org/mailman/listinfo/grass-dev
