[Community] [Insight-developers] Problems building ITK against llvm libc++ (in C++11 mode)

Bradley Lowekamp blowekamp at mail.nih.gov
Thu Oct 17 14:00:50 EDT 2013


Sean,

<comments below>

On Oct 17, 2013, at 1:47 PM, Sean McBride <sean at rogue-research.com> wrote:

> Hi all,
> 
> I've just tried building ITK master against llvm's libc++ (in C++11 mode):
> <http://libcxx.llvm.org>
> 
> I've hit 2 errors:
> 
> 1) ITK/Modules/Core/Common/src/itkProcessObject.cxx:1166:10: error: no viable conversion from 'std::__1::basic_istream<char>' to 'bool'
>  return (std::istringstream(idxStr) >> idx);
>         ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
> 
> 2) ITK/Modules/Core/Common/include/itkImageAlgorithm.h:24:12: fatal error: 'tr1/type_traits' file not found
> #  include <tr1/type_traits>
>           ^
> 
> I see that there is an #if ITK_HAS_STLTR1_TR1_TYPE_TRAITS protection, but I guess the logic needs tweaking.  It should probably prefer <type_traits> and fall back to <tr1/type_traits> only secondarily.

I believe both of the paths have been used. VS 2008 uses the one and every other compiler uses the other.

The header is  for checked here:
https://github.com/Kitware/ITK/blob/master/Modules/Core/Common/CMakeLists.txt#L51

defined here:
https://github.com/Kitware/ITK/blob/master/Modules/Core/Common/src/itkConfigure.h.in#L70

and used here:
https://github.com/Kitware/ITK/blob/master/Modules/Core/Common/include/itkImageAlgorithm.h#L23

Did you compile with a clean CMake cache?

What is defined in the Configure header?

What is the result and output of the try compile?

Brad

> 
> (I'm working on setting up a dashboard with this config.)
> 
> Cheers,
> 
> -- 
> ____________________________________________________________
> Sean McBride, B. Eng                 sean at rogue-research.com
> Rogue Research                        www.rogue-research.com 
> Mac Software Developer              Montréal, Québec, Canada
> 
> 
> _______________________________________________
> Powered by www.kitware.com
> 
> Visit other Kitware open-source projects at
> http://www.kitware.com/opensource/opensource.html
> 
> Kitware offers ITK Training Courses, for more information visit:
> http://kitware.com/products/protraining.php
> 
> Please keep messages on-topic and check the ITK FAQ at:
> http://www.itk.org/Wiki/ITK_FAQ
> 
> Follow this link to subscribe/unsubscribe:
> http://www.itk.org/mailman/listinfo/insight-developers

_______________________________________________
Powered by www.kitware.com

Visit other Kitware open-source projects at
http://www.kitware.com/opensource/opensource.html

Kitware offers ITK Training Courses, for more information visit:
http://kitware.com/products/protraining.php

Please keep messages on-topic and check the ITK FAQ at:
http://www.itk.org/Wiki/ITK_FAQ

Follow this link to subscribe/unsubscribe:
http://www.itk.org/mailman/listinfo/insight-developers



More information about the Community mailing list