[OSM-dev] osm2pgsql - make problems

Jon Burgess jburgess777 at googlemail.com
Thu Jun 21 12:42:56 BST 2007


You would get errors like these if you were not linking against
libgeos. Unfortunately the information about the link line is cut off.
Could you send the output from a few lines above the one you copied
before?

A fix may be to add "-lgeos" to LDFLAGS, or maybe -L<dir> where dir is
the location of libgeos.

You do have libgeos itself installed too? (not just the -dev package?)

On 21/06/07, Nick Black <nickblack1 at gmail.com> wrote:
> Hello,
>
> I'm trying to compile osm2pgsql.  I get this error when running make :
>
>  8sanitizer.o reprojection.o   -o osm2pgsql
> build_geometry.o: In function `is_simple':
> build_geometry.cpp:(.text+0x276): undefined reference to
> `geos::geom::GeometryFactory::GeometryFactory()'
> build_geometry.cpp:(.text+0x281): undefined reference to
> `geos::geom::GeometryFactory::getPrecisionModel() const'
> build_geometry.cpp:(.text+0x2ac): undefined reference to
> `geos::io::WKTReader::read(std::basic_string<char,
> std::char_traits<char>, std::allocator<char> > const&)'
> build_geometry.cpp:(.text+0x2d7): undefined reference to
> `geos::geom::GeometryFactory::~GeometryFactory()'
> build_geometry.cpp:(.text+0x326): undefined reference to
> `geos::geom::GeometryFactory::~GeometryFactory()'
> build_geometry.o: In function `build_geometry':
> build_geometry.cpp:(.text+0x4a3): undefined reference to
> `geos::geom::GeometryFactory::GeometryFactory()'
> build_geometry.cpp:(.text+0x5e2): undefined reference to
> `geos::geom::GeometryFactory::createLineString(geos::geom::CoordinateSequence*)
> const'
> build_geometry.cpp:(.text+0x660): undefined reference to
> `geos::geom::GeometryFactory::createMultiLineString(std::vector<geos::geom::Geometry*,
> std::allocator<geos::g
> ::Geometry*> >*) const'
> build_geometry.cpp:(.text+0x69b): undefined reference to
> `geos::operation::linemerge::LineMerger::LineMerger()'
> build_geometry.cpp:(.text+0x6b3): undefined reference to
> `geos::operation::linemerge::LineMerger::add(geos::geom::Geometry
> const*)'
> build_geometry.cpp:(.text+0x6c1): undefined reference to
> `geos::operation::linemerge::LineMerger::getMergedLineStrings()'
> build_geometry.cpp:(.text+0x6ce): undefined reference to
> `geos::io::WKTWriter::WKTWriter()'
> build_geometry.cpp:(.text+0x702): undefined reference to
> `geos::io::WKTWriter::write(geos::geom::Geometry const*)'
> build_geometry.cpp:(.text+0x7fa): undefined reference to
> `geos::geom::GeometryFactory::createLinearRing(geos::geom::CoordinateSequence*)
> const'
> build_geometry.cpp:(.text+0x811): undefined reference to
> `geos::geom::GeometryFactory::createPolygon(geos::geom::LinearRing*,
> std::vector<geos::geom::Geometry*, std::
> ocator<geos::geom::Geometry*> >*) const'
> build_geometry.cpp:(.text+0x82d): undefined reference to
> `geos::io::WKTWriter::write(geos::geom::Geometry const*)'
> build_geometry.cpp:(.text+0x873): undefined reference to
> `geos::geom::Point::getX() const'
> build_geometry.cpp:(.text+0x87e): undefined reference to
> `geos::geom::Point::getY() const'
> build_geometry.cpp:(.text+0x951): undefined reference to
> `geos::io::WKTWriter::~WKTWriter()'
> build_geometry.cpp:(.text+0x979): undefined reference to
> `geos::operation::linemerge::LineMerger::~LineMerger()'
> build_geometry.cpp:(.text+0x9cc): undefined reference to
> `geos::geom::GeometryFactory::~GeometryFactory()'
> build_geometry.cpp:(.text+0xa80): undefined reference to
> `geos::io::WKTWriter::~WKTWriter()'
> build_geometry.cpp:(.text+0xaa8): undefined reference to
> `geos::operation::linemerge::LineMerger::~LineMerger()'
> build_geometry.cpp:(.text+0xc3a): undefined reference to
> `geos::geom::GeometryFactory::~GeometryFactory()'
>
>
> I have libgeos-dev installed from the Ubuntu Feisty repos - at /usr/lib/,
> but I have postgis built with an older version:
>
>  postgis_full_version
> ----------------------------------------------------------------------------------
>  POSTGIS="1.2.1" GEOS="2.2.3-CAPI-1.1.1" PROJ="Rel. 4.4.9, 29 Oct 2004"
> USE_STATS
>
> So far as I know, I have the dependencies as listed in the readme.txt.  Any
> idea what the problem is?
>
> Thanks for the help,
>
>
>
>
> --
> Nick Black
>  --------------------------------
> http://www.blacksworld.net
> _______________________________________________
> dev mailing list
> dev at openstreetmap.org
> http://lists.openstreetmap.org/cgi-bin/mailman/listinfo/dev
>
>


-- 
    Jon




More information about the dev mailing list