[GRASS-dev] [GRASS GIS] #2065: grass70 not detecting latest source build of libLAS (1.7.0)

GRASS GIS trac at osgeo.org
Thu Aug 29 03:08:09 PDT 2013


#2065: grass70 not detecting latest source build of libLAS (1.7.0)
-----------------------+----------------------------------------------------
 Reporter:  rashadkm   |       Owner:  grass-dev@…              
     Type:  defect     |      Status:  new                      
 Priority:  normal     |   Milestone:  7.0.0                    
Component:  Compiling  |     Version:  svn-trunk                
 Keywords:  liblas     |    Platform:  Linux                    
      Cpu:  All        |  
-----------------------+----------------------------------------------------
 when compiling grass70 from source using the config below with libLAS
 enabled. I am getting an error

 ''./configure --with-freetype-includes=/usr/include/freetype2 --with-
 postgres-includes=/usr/pgsql-9.2/include/ --with-postgres --with-readline
 --with-nls --with-blas --with-lapack --with-wxwidgets --with-sqlite
 --with-geos --with-mysql-includes=/usr/include/mysql --with-mysql --with-
 netcdf --with-liblas=/home/rashad/local/bin/liblas-config --with-
 freetype''


 '''Config output:'''


 {{{
 checking host system type... x86_64-unknown-linux-gnu
 checking for gcc... gcc
 checking whether the C compiler (gcc -Wall -g ) works... yes
 checking whether the C compiler (gcc -Wall -g ) is a cross-compiler... no
 checking whether we are using GNU C... yes
 checking whether gcc accepts -g... yes
 checking for Cygwin environment... no
 checking for mingw32 environment... no
 checking for executable suffix... no
 checking for full floating-point support... yes
 checking for pwd... /usr/bin/pwd
 checking for source directory... /home/rashad/repos/grass/grass70
 checking for build directory... /home/rashad/repos/grass/grass70
 checking for svnversion... /usr/bin/svnversion
 checking for MacOSX App... no
 checking for MacOSX architectures... no
 checking for MacOSX SDK... no
 checking how to build libraries... shared
 checking for additional include dirs...
 checking for additional library dirs...
 checking for a BSD compatible install... /usr/bin/install -c
 checking for flex... flex
 checking for yywrap in -lfl... no
 checking for bison... bison -y
 checking for ranlib... ranlib
 checking for ar... ar
 checking for env... env
 checking for perl... /usr/bin/perl
 checking how to run the C preprocessor... gcc -E
 checking for ANSI C header files... yes
 checking for limits.h... yes
 checking for termio.h... yes
 checking for termios.h... yes
 checking for unistd.h... yes
 checking for values.h... yes
 checking for f2c.h... no
 checking for g2c.h... no
 checking for sys/ioctl.h... yes
 checking for sys/mtio.h... yes
 checking for sys/resource.h... yes
 checking for sys/time.h... yes
 checking for sys/timeb.h... yes
 checking for sys/types.h... yes
 checking for sys/utsname.h... yes
 checking for libintl.h... yes
 checking for iconv.h... yes
 checking for langinfo.h... yes
 checking whether time.h and sys/time.h may both be included... yes
 checking for off_t... yes
 checking for uid_t in sys/types.h... yes
 checking return type of signal handlers... void
 checking for Cygwin environment... no
 checking for ftime... yes
 checking for gethostname... yes
 checking for gettimeofday... yes
 checking for lseek... yes
 checking for nice... yes
 checking for time... yes
 checking for uname... yes
 checking for seteuid... yes
 checking for setpriority... yes
 checking for setreuid... yes
 checking for setruid... no
 checking for drand48... yes
 checking for putenv... yes
 checking for setenv... yes
 checking for nanosleep... yes
 checking whether setpgrp takes no argument... yes
 checking for long long int... yes
 checking for W11... no
 checking for X... libraries , headers
 checking for dnet_ntoa in -ldnet... no
 checking for dnet_ntoa in -ldnet_stub... no
 checking for gethostbyname... yes
 checking for connect... yes
 checking for remove... yes
 checking for shmat... yes
 checking for IceConnectionNumber in -lICE... yes
 checking for library containing cuserid... none required
 checking for asprintf... yes
 checking for atan... no
 checking for atan in -lm... yes
 checking for dlsym... no
 checking for dlsym in -ldl... yes
 checking for iconv... yes
 checking for socket... yes
 checking for location of zlib includes...
 checking for zlib.h... yes
 checking for location of zlib library...
 checking for deflate in -lz... yes
 checking for location of External PROJ.4 includes...
 checking for proj_api.h... yes
 checking External PROJ.4 version... 480
 checking for location of External PROJ.4 library...
 checking for pj_get_def in -lproj... yes
 checking for location of External PROJ.4 data files...
 configure: warning: *** External PROJ.4 directory not specified; default
 will be used
 checking for /usr/local/share/proj/epsg... no
 configure: warning: *** Unable to locate PROJ data files.
 checking for nad2bin... /usr/bin/nad2bin
 checking whether to use regex... yes
 checking for location of regex includes...
 checking for regex.h... yes
 checking for location of regex library...
 checking for regcomp... yes
 checking whether to use Readline... yes
 checking for location of Readline includes...
 checking for readline/readline.h... yes
 checking for readline/history.h... yes
 checking for location of Readline library...
 checking for readline in -lreadline... yes
 checking for add_history in -lhistory... yes
 checking whether to use GDAL... yes
 checking for gdal-config... /usr/bin/gdal-config
 checking whether to use libLAS... yes
 checking for liblas-config... /home/rashad/local/bin/liblas-config
 configure: error: *** Unable to locate libLAS library.
 }}}


 I had downloaded libLAS from [1] and installed in ~/local and liblas-
 config exists here ~/local/bin/liblas-config. but grass configure always
 fails. Below is the output from config.log



 {{{
 configure:6088: checking for gdal-config
 configure:6150: gcc -o conftest -Wall -g  -I/usr/include/gdal   -Wl
 ,--export-dynamic conftest.c  -L/usr/lib64 -lgdal 1>&5
 configure: In function 'main':
 configure:6146:9: warning: ignoring return value of 'GDALOpen', declared
 with attribute warn_unused_result [-Wunused-result]
 configure:6198: checking whether to use libLAS
 configure:6215: checking for liblas-config
 configure:6270: gcc -o conftest -Wall -g  -pedantic -ansi -Wall -Wpointer-
 arith -Wcast-align -Wcast-qual -Wfloat-equal -Wredundant-decls -Wno-long-
 long -std=c++98   -Wl,--export-dynamic conftest.c
 -L/home/rashad/local/lib -llas -llas_c -L/usr/lib64 /usr/lib64
 /libboost_program_options-mt.so /usr/lib64/libboost_thread-mt.so 1>&5
 cc1: warning: command line option '-std=c++98' is valid for C++/ObjC++ but
 not for C [enabled by default]
 configure:6264:32: fatal error: liblas/capi/liblas.h: No such file or
 directory
 compilation terminated.
 configure: failed program was:
 #line 6263 "configure"
 #include "confdefs.h"
 #include <liblas/capi/liblas.h>
 int main() {
 LASReader_Create("foo");
 ; return 0; }
 configure:6285: gcc -o conftest -Wall -g  -pedantic -ansi -Wall -Wpointer-
 arith -Wcast-align -Wcast-qual -Wfloat-equal -Wredundant-decls -Wno-long-
 long -std=c++98   -Wl,--export-dynamic conftest.c
 -L/home/rashad/local/lib -llas -llas_c -L/usr/lib64 /usr/lib64
 /libboost_program_options-mt.so /usr/lib64/libboost_thread-mt.so 1>&5
 cc1: warning: command line option '-std=c++98' is valid for C++/ObjC++ but
 not for C [enabled by default]
 configure:6279:32: fatal error: liblas/capi/liblas.h: No such file or
 directory
 compilation terminated.
 configure: failed program was:
 #line 6278 "configure"
 #include "confdefs.h"
 #include <liblas/capi/liblas.h>
 int main() {
 LASReader_Create("foo");
 ; return 0; }

 }}}

 liblas-config --includes gives this
 ~/local/include

 Adding the '''LIBLAS_INC''' to '''CFLAGS''' solved this

 please find attached patch. I modified the configure script. But I think
 there is a better way to do this

 [1] http://download.osgeo.org/liblas/libLAS-1.7.0.tar.gz

-- 
Ticket URL: <http://trac.osgeo.org/grass/ticket/2065>
GRASS GIS <http://grass.osgeo.org>



More information about the grass-dev mailing list