[Liblas-devel] build problem OS X

Stuart Edwards sedwards2 at cinci.rr.com
Sun Feb 20 11:48:55 EST 2011


On Feb 17, 2011, at 12:18 PM, Stuart Edwards wrote:

> 
> On Feb 17, 2011, at 11:56 AM, Howard Butler wrote:
> 
>> 
>> On Feb 13, 2011, at 10:06 AM, Stuart Edwards wrote:
>> 
>>> Hi ~
>>> 
>>> I'm trying to install libLAS-1.6.0 on OS X 10.6 and have run into a problem during build.  First though, congratulations on the amazing install documentation without which I (a non-programmer) would never have got even to this point.  Everything has gone according to the instructions so far - I've installed boost, cmake and laszip-1.0.1 (actually not mentioned in the documentation).  The configure process has completed successfully for the base and optional libraries, but at build I get seven errors that causes build to fail - I'm trying to build lasinfo, as directed.
>>> 
>>> The errors all occur in point.cpp.  
>>> 
>>> 1.   Four are missing ";" before "}"  ( at lines 498, 514, 530, and 571) These are all in conjunction with "#endif" statements and adding a seemingly redundant ";" before the "}" makes these errors go away, but may be causing other damage that I'm not aware of. 
>>> 
>>> 2.  Two more are similar to each other -  at lines 563, 791, 
>>> 
>>> e.g
>>> 
>>> #ifdef LIBLAS_ENDIAN_AWARE
>>>   boost::uint16_t output = liblas::detail::bitsToInt<boost::int32_t>(output, m_data, pos);
>>>   return output
>>> #else
>>>   boost::uint8_t* data = const_cast<boost::uint8_t*>(&m_data[0] + pos);
>>>   boost::uint16_t* output = reinterpret_cast<boost::uint16_t*>(data);
>>>   return *output;
>>> #endif
>>> ;  //(note -- my ";" see 1.above)
>>> }
>>> and the error is:
>>> 
>>> point.cpp:563: error: no matching function for call to 'bitsToInt(uint16_t&, const std::vector<unsigned char, std::allocator<unsigned char> >&, size_t&)'
>>> 
>>> 
>>> 3.  The last is:              Command /Developer/usr/bin/g++-4.2 failed with exit code 1
>>> 
>>> This one is puzzling since I did set CC=/usr/bin/llvm-gcc,   and $CC yields 
>>> 
>>> i686-apple-darwin10-llvm-gcc-4.2: no input files
>>> 
>>> Having made it this far I'd like to get this running, so if anyone has any advice it would be much appreciated.
>> 
>> Stewart,
>> 
>> Do you happen to know which version of XCode you are running?  I'm running the latest XCode (3.2.5, I think), and I can compile libLAS using both LLVM and regular g++ without a problem.  I could do so before Michael made the fixes as well.  
>> 
>> Howard
>> 
>> PS, while we're doing our best to support LLVM, the version that comes with XCode is a bit old, and no libLAS developer is a daily LLVM user at this time.  We want to make sure that platform works, as it is a rapidly improving up-and-comer, but it might still lag a little bit due to cultural uptake from the project.
> 
> It's 3.2.3 - I'll update it and see what happens.
> thx
> 
> Stu_______________________________________________


OK -- that did the trick.  With Xcode 3.2.5 no errors (but 150 warnings .....)

I did have to start from scratch; when I tried to compile my existing project I got the old errors

One other thing for those compiling on OS X using the instructions at:

http://liblas.org/compilation.html#using-xcode-on-os-x

The arguments to be passed on at launch for the test of lasinfo had to be changed

First I get an error message: 

Program loaded.
run
[Switching to process 31225]
Running…
error: unknown option -c

I unchecked the "-c"  in the set up box, and the error went away

then:

Debugger stopped.
Cannot open /Users/stu/liblas/test/data/TO_core_last_zoom.las for read.  Exiting...

This is because the file is actually       /test/data/TO_core_last_clip.las   in my download

So change this too in the set up box and it should run just fine.............

Thanks for the help

Stu
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.osgeo.org/pipermail/liblas-devel/attachments/20110220/8258c9f0/attachment-0001.html


More information about the Liblas-devel mailing list