[pdal] [gdal-dev] Building PDAL using pramsey-config.sh

Stefan Keller sfkeller at gmail.com
Mon Nov 4 14:01:03 PST 2013


Hi Even

2013/11/4 Even Rouault <even.rouault at mines-paris.org> wrote:
> If doable, the best thing would be for PDAL to avoid including in the same
> .cpp file both geotiff/cpl_serv.h and gdal/cpl_port.h. Or cheating by
#define
> CPL_SERV_H_INCLUDED before including libgeotiff headers.

Merci beaucoups, Even.
I'll try to forward this hint to PDAL devs.

Yours, Stefan


2013/11/4 Even Rouault <even.rouault at mines-paris.org>

> Le lundi 04 novembre 2013 20:30:08, Stefan Keller a écrit :
> > Hi PDAL and GDAL list
> >
> > I'm referring to the error reported above when (still) trying to compile
> > PDAL with pointcloud support.
> >
> > What I'm really wondering is why GDAL developpers are calling function
> > gtCPLRealloc
> > the same as in GeoTIFF lib but with different declaration?
> >
> > See
> > /usr/include/gdal/cpl_port.h:533:89: => ‘void* gtCPLRealloc(void*,
> size_t)’
> > and
> > /usr/include/geotiff/cpl_serv.h:144:20 => ‘void* gtCPLRealloc(void*,
> int)’
> >
> > -S.
>
> Not sure if the issue comes from GDAL. Looks a bit more like a bad
> interaction
> between libgeotiff "simplified" CPL library (
> http://trac.osgeo.org/geotiff/browser/trunk/libgeotiff/cpl_serv.h ) when
> mixed
> with GDAL headers. Perhaps libgeotiff should be updated to use size_t
> instead
> of int ?
>
> If doable, the best thing would be for PDAL to avoid including in the same
> .cpp file both geotiff/cpl_serv.h and gdal/cpl_port.h. Or cheating by
> #define
> CPL_SERV_H_INCLUDED before including libgeotiff headers.
>
> This reminds me of a similar discussion :
> http://trac.osgeo.org/gdal/ticket/4374
>
> Even
>
> >
> >
> >
> > 2013/10/29 Heng Zhi Feng (zheng at hsr.ch) <zheng at hsr.ch>
> >
> > >  Hello,
> > >
> > > We are having issues building PDAL on Ubuntu 13.10, following the guide
> > > on *[1].*
> > >
> > >
> > >
> > > Initially, PDAL successfully compiles with using the “cmake –G “Unix
> > > Makefiles” ../” command. However, when trying to import a sample .LAS
> > > file into PostgreSQL 9.1 using the PDAL Pipeline application. The
> > > following error occurred “Caught PDAL exception: Unable to create
> writer
> > > for type ‘drivers.pgpointcloud.writer’.”.
> > >
> > >
> > >
> > > Our next approach was to use the script “pramsey-config.sh” from github
> > > and was thrown the following errors:
> > >
> > >
> > >
> > > 1.       In file included from /usr/include/gdal/cpl_conv.h:34:0,
> > >
> > >                  from
> > >
> > > /home/zheng/Downloads/PDAL/src/drivers/las/GeotiffSupport.hpp:42,
> > >
> > >                  from
> > >
> > > /home/zheng/Downloads/PDAL/src/drivers/las/GeotiffSupport.cpp:35:
> > >
> > > /usr/include/gdal/cpl_port.h:533:89: error: declaration of C function
> > > ‘void* gtCPLRealloc(void*, size_t)’ conflicts with
> > >
> > > #define CPL_WARN_UNUSED_RESULT
> > > __attribute__((warn_unused_result))
> > >
> > >
> > > ^
> > >
> > > /usr/include/gdal/cpl_conv.h:65:44: note: in expansion of macro
> > > ‘_WARN_UNUSED_RESULT’
> > >
> > > void CPL_DLL *CPLRealloc( void *, size_t ) CPL_WARN_UNUSED_RESULT;
> > >
> > >
> > >
> > > 2.       In file included from
> > > /usr/include/geotiff/geo_simpletags.h:34:0,
> > >
> > >                  from
> > >
> > > /home/zheng/Downloads/PDAL/src/drivers/las/GeotiffSupport.hpp:41,
> > >
> > >                  from
> > >
> > > /home/zheng/Downloads/PDAL/src/drivers/las/GeotiffSupport.cpp:35:
> > >
> > > /usr/include/geotiff/cpl_serv.h:144:20: error: previous declaration
> > > ‘void* gtCPLRealloc(void*, int)’ here
> > >
> > > #define CPLRealloc gtCPLRealloc
> > >
> > >
> > >
> > > ** We had adapted the path for the dependencies to our system in the
> > > script.
> > >
> > >
> > >
> > > Would greatly appreciate if someone could advise on how to proceed.
> > >
> > >
> > >
> > > Thank you.
> > >
> > > Regards,
> > >
> > > Zhi Feng
> > >
> > >
> > >
> > > *[1]* http://www.pointcloud.org/compilation/unix.html
> > >
> > > _______________________________________________
> > > pdal mailing list
> > > pdal at lists.osgeo.org
> > > http://lists.osgeo.org/mailman/listinfo/pdal
>
> --
> Geospatial professional services
> http://even.rouault.free.fr/services.html
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/pdal/attachments/20131104/f026a929/attachment.html>


More information about the pdal mailing list