[vtkusers] Compiling VTK 6.1.0 fails on Red Hat Enterprise GNU/Linux Server release 6.3 (Santiago)

Omid omidlink at gmail.com
Fri Mar 7 20:45:07 EST 2014


The problem is that ccmake does not report any of the required
libraries as missing; so I assume they are installed. But if for some
reason ccmake is missing to report a missing library, how would I find
out which one it is? I can't tell from the error message below (which
is very generic). I don't have superuser privileges on this system to
install a whole bunch of libraries with just a command, so I want to
find out which library (if at all) is causing the problem and build
that from source.

Thanks,

Omid

Sent from my Emacs

On 03/06/2014 07:09 PM, Bill Lorensen wrote:
> I have built ITK, VTK, Slicer on Fedora 20 after this:
> yum groupinstall "C Development Tools"
> yum install git-core
> yum install svn
> yum install libX11-devel
> yum install libXt-devel
> yum install mesa-libGL-devel
> yum install mesa-libGLU-devel
> yum install cmake
> yum install tcl-devel
> yum install python-devel
> yum install qt-devel
> yum install qt-webkit-devel
> 
> 
> On Thu, Mar 6, 2014 at 6:24 PM, Omid <omidlink at gmail.com> wrote:
>> Hi David,
>>
>> Thanks for your almost immediate response! As you suggested, I changed
>> the title and posted the message again.
>>
>> Omid
>>
>> Sent from my Emacs
>>
>> On 03/06/2014 06:13 PM, David Gobbi wrote:
>>> Hi Omid,
>>>
>>> It's definitely not because your gcc is too old, VTK 6.1 builds just
>>> fine even with gcc 4.2.
>>>
>>> My best guess is that your system does not have all of the necessary
>>> -devel packages installed.  I haven't used a redhat-based system in a
>>> very long time, so I can't tell you exactly what devel packages you
>>> have to install.
>>>
>>> I suggest that you re-post your question with a subject like "I'm
>>> trying to install VTK on system X" where "X" is the exact name of
>>> the linux distro you are using.  That will attract attention of other
>>> people who use the same distro.
>>>
>>>   David
>>>
>>>
>>> On Thu, Mar 6, 2014 at 3:57 PM, Omid <omidlink at gmail.com> wrote:
>>>> Hello,
>>>>
>>>> I am trying to compile VTK 6.1.0. After configuring with
>>>>
>>>> ccmake .
>>>>
>>>> with the following configuration
>>>>
>>>> BUILD_DOCUMENTATION              OFF
>>>> BUILD_EXAMPLES                   OFF
>>>> BUILD_SHARED_LIBS                ON
>>>> BUILD_TESTING                    OFF
>>>> CMAKE_BUILD_TYPE                 Debug
>>>> CMAKE_INSTALL_PREFIX             $OPT
>>>> EXECINFO_LIB                     EXECINFO_LIB-NOTFOUND
>>>> VTK_EXTRA_COMPILER_WARNINGS      OFF
>>>> VTK_Group_Imaging                OFF
>>>> VTK_Group_MPI                    OFF
>>>> VTK_Group_Qt                     OFF
>>>> VTK_Group_Rendering              ON
>>>> VTK_Group_StandAlone             ON
>>>> VTK_Group_Tk                     OFF
>>>> VTK_Group_Views                  OFF
>>>> VTK_Group_Web                    OFF
>>>> VTK_SMP_IMPLEMENTATION_TYPE      Sequential
>>>> VTK_USE_LARGE_DATA               OFF
>>>> VTK_WRAP_JAVA                    OFF
>>>> VTK_WRAP_PYTHON                  OFF
>>>> VTK_WRAP_TCL                     OFF
>>>>
>>>> I get the following compile error upon invoking make:
>>>>
>>>> /usr/lib/gcc/x86_64-redhat-linux/4.4.6/../../../../include/c++/4.4.6/bits/stl_algobase.h:544:
>>>> error: no type named 'difference_type' in 'struct
>>>> std::iterator_traits<std::basic_string<char, std::char_traits<char>,
>>>> std::allocator<char> >*>'
>>>> /usr/lib/gcc/x86_64-redhat-linux/4.4.6/../../../../include/c++/4.4.6/bits/stl_algobase.h:544:
>>>> error: no type named 'difference_type' in 'struct
>>>> std::iterator_traits<std::basic_string<char, std::char_traits<char>,
>>>> std::allocator<char> >*>'
>>>> /usr/lib/gcc/x86_64-redhat-linux/4.4.6/../../../../include/c++/4.4.6/bits/stl_algobase.h:544:
>>>> error: no type named 'difference_type' in 'struct
>>>> std::iterator_traits<std::basic_string<char, std::char_traits<char>,
>>>> std::allocator<char> >*>'
>>>> /usr/lib/gcc/x86_64-redhat-linux/4.4.6/../../../../include/c++/4.4.6/bits/stl_algobase.h:544:
>>>> error: no type named 'difference_type' in 'struct
>>>> std::iterator_traits<std::basic_string<char, std::char_traits<char>,
>>>> std::allocator<char> >*>'
>>>> In file included from
>>>> /usr/lib/gcc/x86_64-redhat-linux/4.4.6/../../../../include/c++/4.4.6/vector:64,
>>>>                  from
>>>> /panfs/storage.local/genacc/home/ok10c/software/VTK-6.1.0/Utilities/KWSys/vtksys/stl/vector:36,
>>>>                  from
>>>> /panfs/storage.local/genacc/home/ok10c/software/VTK-6.1.0/Utilities/KWSys/vtksys/Directory.cxx:20:
>>>> /usr/lib/gcc/x86_64-redhat-linux/4.4.6/../../../../include/c++/4.4.6/bits/stl_uninitialized.h:
>>>> In static member function 'static _ForwardIterator
>>>> std::__uninitialized_copy<<anonymous>
>>>>> ::uninitialized_copy(_InputIterator, _InputIterator, _ForwardIterator)
>>>> [with _InputIterator = std::basic_string<char, std::char_traits<char>,
>>>> std::allocator<char> >*, _ForwardIterator = std::basic_string<char,
>>>> std::char_traits<char>, std::allocator<char> >*, bool <anonymous> = false]':
>>>> /usr/lib/gcc/x86_64-redhat-linux/4.4.6/../../../../include/c++/4.4.6/bits/stl_uninitialized.h:117:
>>>>   instantiated from '_ForwardIterator
>>>> std::uninitialized_copy(_InputIterator, _InputIterator,
>>>> _ForwardIterator) [with _InputIterator = std::basic_string<char,
>>>> std::char_traits<char>, std::allocator<char> >*, _ForwardIterator =
>>>> std::basic_string<char, std::char_traits<char>, std::allocator<char> >*]'
>>>> /usr/lib/gcc/x86_64-redhat-linux/4.4.6/../../../../include/c++/4.4.6/bits/stl_uninitialized.h:257:
>>>>   instantiated from '_ForwardIterator
>>>> std::__uninitialized_copy_a(_InputIterator, _InputIterator,
>>>> _ForwardIterator, std::allocator<_Tp>&) [with _InputIterator =
>>>> std::basic_string<char, std::char_traits<char>, std::allocator<char> >*,
>>>> _ForwardIterator = std::basic_string<char, std::char_traits<char>,
>>>> std::allocator<char> >*, _Tp = std::basic_string<char,
>>>> std::char_traits<char>, std::allocator<char> >]'
>>>> /usr/lib/gcc/x86_64-redhat-linux/4.4.6/../../../../include/c++/4.4.6/bits/stl_uninitialized.h:267:
>>>>   instantiated from '_ForwardIterator
>>>> std::__uninitialized_move_a(_InputIterator, _InputIterator,
>>>> _ForwardIterator, _Allocator&) [with _InputIterator =
>>>> std::basic_string<char, std::char_traits<char>, std::allocator<char> >*,
>>>> _ForwardIterator = std::basic_string<char, std::char_traits<char>,
>>>> std::allocator<char> >*, _Allocator =
>>>> std::allocator<std::basic_string<char, std::char_traits<char>,
>>>> std::allocator<char> > >]'
>>>> /usr/lib/gcc/x86_64-redhat-linux/4.4.6/../../../../include/c++/4.4.6/bits/vector.tcc:338:
>>>>   instantiated from 'void std::vector<_Tp,
>>>> _Alloc>::_M_insert_aux(__gnu_cxx::__normal_iterator<typename
>>>> std::_Vector_base<_Tp, _Alloc>::_Tp_alloc_type::pointer,
>>>> std::vector<_Tp, _Alloc> >, const _Tp&) [with _Tp =
>>>> std::basic_string<char, std::char_traits<char>, std::allocator<char> >,
>>>> _Alloc = std::allocator<std::basic_string<char, std::char_traits<char>,
>>>> std::allocator<char> > >]'
>>>> /usr/lib/gcc/x86_64-redhat-linux/4.4.6/../../../../include/c++/4.4.6/bits/stl_vector.h:741:
>>>>   instantiated from 'void std::vector<_Tp, _Alloc>::push_back(const
>>>> _Tp&) [with _Tp = std::basic_string<char, std::char_traits<char>,
>>>> std::allocator<char> >, _Alloc = std::allocator<std::basic_string<char,
>>>> std::char_traits<char>, std::allocator<char> > >]'
>>>> /panfs/storage.local/genacc/home/ok10c/software/VTK-6.1.0/Utilities/KWSys/vtksys/Directory.cxx:226:
>>>>   instantiated from here
>>>> /usr/lib/gcc/x86_64-redhat-linux/4.4.6/../../../../include/c++/4.4.6/bits/stl_uninitialized.h:74:
>>>> error: no matching function for call to 'operator new(long unsigned int,
>>>> void*)'
>>>> <built-in>:0: note: candidates are: void* operator new(long unsigned int)
>>>> make[2]: ***
>>>> [Utilities/KWSys/vtksys/CMakeFiles/vtksys.dir/Directory.cxx.o] Error 1
>>>> make[1]: *** [Utilities/KWSys/vtksys/CMakeFiles/vtksys.dir/all] Error 2
>>>> make: *** [all] Error 2
>>>>
>>>> I thought the reason could be that the gcc compiler is too old (4.4.6)
>>>> and may not support some of the newer language features (like new). I
>>>> installed the latest stable gcc (4.8.2) and tried instructing ccmake
>>>> to use the new gcc using
>>>>
>>>> env CC=$(which gcc) CXX=$(which gcc) ccmake .
>>>>
>>>> or
>>>>
>>>> CC=$(which gcc) CXX=$(which gcc) ccmake .
>>>>
>>>> where $(which gcc) returns the path to the new gcc. But the output and
>>>> the errors are still the same (referring to gcc 4.4.6). It looks like
>>>> the new gcc is not picked up by ccmake. Doing a find grep, I don't
>>>> see where the CC or CXX variables may have been set (they are not in
>>>> the Makefile). Any help towards solving this is greatly appreciated.
>>>>
>>>> --
>>>> Omid
>> _______________________________________________
>> Powered by www.kitware.com
>>
>> Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html
>>
>> Please keep messages on-topic and check the VTK FAQ at: http://www.vtk.org/Wiki/VTK_FAQ
>>
>> Follow this link to subscribe/unsubscribe:
>> http://www.vtk.org/mailman/listinfo/vtkusers
> 
> 
> 
	


More information about the vtkusers mailing list