[GRASS-dev] Re: I.points not compiling on Mac

Glynn Clements glynn at gclements.plus.com
Wed Jan 24 13:46:37 EST 2007


Michael Barton wrote:

> > > Related to the xcode project, you opined that the reason that
> > > i.points would
> > > not compile correctly is because of a libcurses issue. Any
> > > suggestion as to
> > > how to fix this? If I understood an earlier post of yours, xcode
> > > will not go
> > > ahead and package GRASS unless everything compiles without error.
> > 
> > Probably a bug that needs reporting - there was the fuss a while back
> > about reducing unnecessary use of vask and curses, and I think curses
> > got removed from i.points by mistake.  Though why others (non-OSX
> > users) haven't had this problem is a mystery.
> > 
> > In the i.points makefile add $(CURSES) to LIBES.
> 
> It happens that i.points won't compile  on my Mac. In discussing this with
> William Kyngesbury, he suggests it could be a bug missed in a recent cleanup
> of vask and curses.

AFAICT, the issue is that i.points was relying upon curses being
linked due to $(IMAGERYLIB). Now that this library no longer uses
curses, the i.points Makefile will need to specify curses explicitly.

Except ... the IMAGERYLIB definition in Grass.make[.in] still includes
$(VASKLIB), although its no longer required. However, the definition
of VASKLIB *doesn't* include $(CURSES), although that *is* required.

> He also suggests modifying the i.points makefile (see below). Since I know
> just enough about make files to really get into trouble, I don't want to
> make this change. Can one of you take a quick look and see if this is
> something that needs to be done generally or if it is something that is Mac
> specific?

It may be that, because the imagery library no longer actually uses
the vask library, the linker ignores it, and thus curses doesn't
actually gets linked in.

In any case, a module which uses curses directly *should* be
referencing it from its Makefile, rather than relying upon it getting
linked by coincidence.

I intend to:

1. add $(CURSES) to i.points/Makefile,
2. remove $(VASKLIB) from the definition of IMAGERYLIB in
Grass.make.in, and
3. add $(CURSES) to the definition of VASKLIB in Grass.make.in

As there may be other modules relying upon $(IMAGERYLIB) pulling in
vask and/or curses, I'll check that everything compiles before
committing this.

-- 
Glynn Clements <glynn at gclements.plus.com>




More information about the grass-dev mailing list