[Qgis-developer] Mac build error

Tom Elwertowski telwertowski at comcast.net
Tue Jun 13 14:10:00 EDT 2006


Tim Sutton wrote:
> Hi Tom
> 
> My turn to tap your brain now :-) Im trying to build on my macbook.
> 
> g++ -DHAVE_CONFIG_H -I. -I. -I../.. -I -I/sw/include 
> -I/usr/local/include -g -O2 -DQT3_SUPPORT 
> -I/usr/local/Qt4.1.3/mkspecs/default 
> -I/usr/local/Qt4.1.3/lib/Qt3Support.framework/Headers 
> -I/usr/local/Qt4.1.3/lib/QtCore.framework/Headers 
> -I/usr/local/Qt4.1.3/lib/QtGui.framework/Headers 
> -I/usr/local/Qt4.1.3/lib/QtNetwork.framework/Headers 
> -I/usr/local/Qt4.1.3/lib/QtOpenGL.framework/Headers 
> -I/usr/local/Qt4.1.3/lib/QtSql.framework/Headers 
> -I/usr/local/Qt4.1.3/lib/QtSvg.framework/Headers 
> -I/usr/local/Qt4.1.3/lib/QtXml.framework/Headers 
> -I/usr/local/Qt4.1.3/include/QtDesigner 
> -I/usr/local/Qt4.1.3/include/QtTest -I/usr/local/Qt4.1.3/include 
> -D_REENTRANT -DQT_THREAD_SUPPORT -DNO_DEBUG 
> -I../../widgets/projectionselector/ -I../gui/ -I../legend/ -I../ui/ 
> -I../core/ -g -O2 -MT libqgis_raster_la-qgsrasterlayer.lo -MD -MP -MF 
> .deps/libqgis_raster_la-qgsrasterlayer.Tpo -c qgsrasterlayer.cpp  
> -fno-common -DPIC -o .libs/libqgis_raster_la-qgsrasterlayer.o
> In file included from ../core/qgsfeature.h:28,
>                  from ../gui/qgsclipboard.h:25,
>                  from ../gui/qgisapp.h:50,
>                  from qgsrasterlayer.cpp:107:
> ../core/qgsgeometry.h:22:18: error: geos.h: No such file or directory
> 
> Its wierd because core built ok which includes that file, and 
> /sw/include (where geos.h) is in the g++ line above. I installed geos 
> from fink using apt-get.
> 
> Any ideas?

I'm puzzled by this as well. I would expect the -I/sw/include to be 
sufficient.

A difference between core/Makefile.am and projectionselector/Makefile.am 
is that libqgis_core_la_CXXFLAGS contains $(GEOS_CFLAGS) and 
libqgsprojectionselector_la_CXXFLAGS doesn't. An extra -I/sw/include 
from $(GEOS_CFLAGS) should be redundant but perhaps it's needed.

Another idea is to add -v which should echo the actual include path 
assembled from all the options. This may provide some insight to the 
failed search.

Although I first used fink, and later darwin-ports, when I wasn't very 
familiar with *nix, I did have to struggle with obscure path issues. 
After becoming more familiar with the *nix directory structure and build 
tools, I eventually found it simpler to directly install all additions 
or Apple-overrides into /usr/local.

Tom



More information about the Qgis-developer mailing list