[Vv] Problems installing CLITK via vv superbuild file
Bilal Tahir
b.tahir at sheffield.ac.uk
Wed Feb 27 00:33:28 CET 2013
Dear Simon,
Thanks for your email. Yes, although it would be nice to have the latest
version of the VV gui, I could just use the Oct 2012 version for now but I
do need to use CLITK.
I have edited the CMakeLists.txt file (attached) by deleting the QT section
and adding the following lines to VV section:
-DCLITK_BUILD_VV:BOOL=ON
-DCLITK_BUILD_REGISTRATION:BOOL=ON
-DCLITK_BUILD_SEGMENTATION:BOOL=ON
-DCLITK_BUILD_TOOLS:BOOL=ON
-DCLITK_EXPERIMENTAL:BOOL=ON
Can you confirm that this is all that is needed?
Also once it has compiled, do I add the paths in the .bashrc to refer to
'Build' folder or will another folder show up if it is succesful?
I'm not that familiar with Linux so I appreciate your assistance.
Best wishes,
Bilal
On 24 February 2013 11:09, Simon Rit <simon.rit at creatis.insa-lyon.fr> wrote:
> Dear Bilal,
> We are considering this for VV first but we will not support this for
> clitk tools. We are happy to provide clitk tools but users must try to
> solve their compilation issues.
> By the way, compilation of clitk tools, if this is what you are interested
> in, should not require qt if you disable VV compilation
> (CLITK_BUILD_VV:BOOL=OFF).
> Simon
>
> On Sat, Feb 23, 2013 at 12:13 AM, Bilal Tahir <b.tahir at sheffield.ac.uk>wrote:
>
>> Can I make a request that the latest version of VV including CLITK with
>> all options set to ON be made available as a precompiled .sh binary file?
>> Slicer3D http://download.slicer.org/ allows for a nightly download of
>> the binary version of the latest version.
>>
>> This is due to my case where I have experienced many errors in trying to
>> install the relevant programs until I finally get to install CLITK whereas
>> the Oct 2012 precomiled binary .sh file worked fine on linux for me.
>> However, CLITK was not included in that release.
>>
>> Best wishes,
>>
>> Bilal
>>
>> On 22 February 2013 22:58, Bilal Tahir <b.tahir at sheffield.ac.uk> wrote:
>>
>>> Dear All,
>>>
>>> I am trying to install CLITK by adding the relevant =ON options on the
>>> CMakeLists.txt file (attached edited version in this email) found in the
>>> following link
>>> https://git.creatis.insa-lyon.fr/pubgit/?p=clitk.git;a=blob;f=superbuild/CMakeLists.txt
>>>
>>> I then run the following two commands:
>>>
>>> cmake superbuild-file-directorymake
>>>
>>> However, after running 'make' it started installing the programs (ITK,
>>> QT and VTK) one after the other for several hours until it reached 60% of
>>> the last program 'VV' where it gave the following errors and stopped:
>>>
>>> collect2: ld returned 1 exit status
>>> make[5]: *** [bin/vv] Error 1
>>> make[4]: *** [vv/CMakeFiles/vv.dir/all] Error 2
>>> make[3]: *** [all] Error 2
>>> make[2]: *** [Stamp/VV/VV-build] Error 2
>>> make[1]: *** [CMakeFiles/VV.dir/all] Error 2
>>> make: *** [all] Error 2
>>>
>>> I've copied and posted some of the last few lines up till the point that
>>> the error came.
>>>
>>> The 'make' command created several folders in my home folder
>>> (/home/md1bat/) including 'Source' and 'Build'. It appears that ITK, QT and
>>> VTK (not VV) completed as you can see from the /home/md1bat/CMakeFiles/
>>> folder.
>>>
>>> [image: Inline images 1]
>>>
>>> Within the 'Build' folder, each of the four programs, ITK, VTK, QT and
>>> VV have at least a bin and/or lib folder. This is not the case in the
>>> 'Source' folder. Therefore, I have added the paths of the respective bin
>>> and lib folders from the 'Build' folder (not Source) to my .bashrc file
>>> (attached in this email). However, none of the programs (including the
>>> completed ITK, QT and VTK) seem to work even if I want to check which
>>> version I have installed using the command e.g itk --version. I have now
>>> deleted the precompiled 'VV' Oct 2012 version which used to work with the
>>> command vv. However, the command vv now gives the output 'command not
>>> found'.
>>>
>>> I'm not sure if I have done the export path correctly on my .bashrc as I
>>> have referenced it to the 'Build' folder and not the 'Source' folder as
>>> there was no bin or lib folders within that. Furthermore, I have no idea
>>> why the errors occurred.
>>>
>>> Please let me know if you have any suggestions.
>>>
>>> Best wishes,
>>>
>>> Bilal Tahir,
>>> James Morrison Researcher in Radiotherapy Imaging,
>>> University of Sheffield/Weston Park Cancer Hospital
>>>
>>
>>
>>
>> --
>> Bilal Tahir,
>> James Morrison Researcher in Radiotherapy Imaging
>>
>> _______________________________________________
>> vv mailing list
>> vv at creatis.insa-lyon.fr
>> http://www.creatis.insa-lyon.fr/mailman/listinfo/vv
>>
>>
>
> _______________________________________________
> vv mailing list
> vv at creatis.insa-lyon.fr
> http://www.creatis.insa-lyon.fr/mailman/listinfo/vv
>
>
--
Bilal Tahir,
James Morrison Researcher in Radiotherapy Imaging
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.creatis.insa-lyon.fr/pipermail/vv/attachments/20130226/22f530b4/attachment.html>
-------------- next part --------------
cmake_minimum_required(VERSION 2.8)
cmake_policy(VERSION 2.8)
# set a default build type if it is undefined, then make sure it goes in the cache
if(NOT CMAKE_BUILD_TYPE)
set(CMAKE_BUILD_TYPE Release)
endif()
set(CMAKE_BUILD_TYPE ${CMAKE_BUILD_TYPE} CACHE STRING "Build configuration type" FORCE)
set(build_type ${CMAKE_BUILD_TYPE})
#=========================================================
MACRO (DD in)
MESSAGE(${in}=${${in}})
ENDMACRO(DD)
#=========================================================
project(SuperBuild_VV)
if(MSVC)
set(CMAKE_C_FLAGS_DEBUG "/D_DEBUG /MTd /Zi /Ob0 /Od /RTC1" CACHE STRING "" FORCE)
set(CMAKE_C_FLAGS_MINSIZEREL "/MT /O1 /Ob1 /D NDEBUG" CACHE STRING "" FORCE)
set(CMAKE_C_FLAGS_RELEASE "/MT /O2 /Ob2 /D NDEBUG" CACHE STRING "" FORCE)
set(CMAKE_C_FLAGS_RELWITHDEBINFO "/MT /Zi /O2 /Ob1 /D NDEBUG" CACHE STRING "" FORCE)
set(CMAKE_CXX_FLAGS_DEBUG "/D_DEBUG /MTd /Zi /Ob0 /Od /RTC1" CACHE STRING "" FORCE)
set(CMAKE_CXX_FLAGS_MINSIZEREL "/MT /O1 /Ob1 /D NDEBUG" CACHE STRING "" FORCE)
set(CMAKE_CXX_FLAGS_RELEASE "/MT /O2 /Ob2 /D NDEBUG" CACHE STRING "" FORCE)
set(CMAKE_CXX_FLAGS_RELWITHDEBINFO "/MT /Zi /O2 /Ob1 /D NDEBUG" CACHE STRING "" FORCE)
endif(MSVC)
include(ExternalProject)
set(base "${CMAKE_BINARY_DIR}")
set_property(DIRECTORY PROPERTY EP_BASE ${base})
set(source_prefix ${base}/Source)
set(build_prefix ${base}/Build)
set(install_prefix ${base}/Install)
find_package(Git REQUIRED)
#=========================================================
# VTK
SET(VTK_CMAKE_CXX_STANDARD_LIBRARIES "${CMAKE_CXX_STANDARD_LIBRARIES}")
IF(MSVC)
SET(VTK_CMAKE_CXX_STANDARD_LIBRARIES "${VTK_CMAKE_CXX_STANDARD_LIBRARIES} Imm32.lib Winmm.lib Ws2_32.lib")
ENDIF(MSVC)
ExternalProject_Add(
VTK
DEPENDS QT
SOURCE_DIR ${source_prefix}/vtk
GIT_REPOSITORY git://vtk.org/VTK.git
GIT_TAG v5.10.0
INSTALL_COMMAND ""
CMAKE_ARGS
-DQT_QMAKE_EXECUTABLE:FILEPATH=${qmake_executable}
-DCMAKE_C_FLAGS_DEBUG:STRING=${CMAKE_C_FLAGS_DEBUG}
-DCMAKE_C_FLAGS_MINSIZEREL:STRING=${CMAKE_C_FLAGS_MINSIZEREL}
-DCMAKE_C_FLAGS_RELEASE:STRING=${CMAKE_C_FLAGS_RELEASE}
-DCMAKE_C_FLAGS_RELWITHDEBINFO:STRING=${CMAKE_C_FLAGS_RELWITHDEBINFO}
-DCMAKE_CXX_FLAGS_DEBUG:STRING=${CMAKE_CXX_FLAGS_DEBUG}
-DCMAKE_CXX_FLAGS_MINSIZEREL:STRING=${CMAKE_CXX_FLAGS_MINSIZEREL}
-DCMAKE_CXX_FLAGS_RELEASE:STRING=${CMAKE_CXX_FLAGS_RELEASE}
-DCMAKE_CXX_FLAGS_RELWITHDEBINFO:STRING=${CMAKE_CXX_FLAGS_RELWITHDEBINFO}
-DCMAKE_INSTALL_PREFIX:PATH=${install_prefix}/${proj}
-DCMAKE_BUILD_TYPE:STRING=${build_type}
-DBUILD_SHARED_LIBS:BOOL=OFF
-DBUILD_EXAMPLES:BOOL=OFF
-DBUILD_TESTING:BOOL=OFF
-DVTK_USE_QT:BOOL=ON
-DVTK_USE_QVTK_QTOPENGL:BOOL=ON
-DCMAKE_CXX_STANDARD_LIBRARIES:STRING=${VTK_CMAKE_CXX_STANDARD_LIBRARIES}
)
SET(VTK_DIR ${build_prefix}/VTK)
#=========================================================
#=========================================================
# ITK
ExternalProject_Add(
ITK
SOURCE_DIR ${source_prefix}/itk
GIT_REPOSITORY git://itk.org/ITK.git
GIT_TAG v4.2.0
INSTALL_COMMAND ""
CMAKE_ARGS
-DCMAKE_C_FLAGS_DEBUG:STRING=${CMAKE_C_FLAGS_DEBUG}
-DCMAKE_C_FLAGS_MINSIZEREL:STRING=${CMAKE_C_FLAGS_MINSIZEREL}
-DCMAKE_C_FLAGS_RELEASE:STRING=${CMAKE_C_FLAGS_RELEASE}
-DCMAKE_C_FLAGS_RELWITHDEBINFO:STRING=${CMAKE_C_FLAGS_RELWITHDEBINFO}
-DCMAKE_CXX_FLAGS_DEBUG:STRING=${CMAKE_CXX_FLAGS_DEBUG}
-DCMAKE_CXX_FLAGS_MINSIZEREL:STRING=${CMAKE_CXX_FLAGS_MINSIZEREL}
-DCMAKE_CXX_FLAGS_RELEASE:STRING=${CMAKE_CXX_FLAGS_RELEASE}
-DCMAKE_CXX_FLAGS_RELWITHDEBINFO:STRING=${CMAKE_CXX_FLAGS_RELWITHDEBINFO}
-DCMAKE_INSTALL_PREFIX:PATH=${install_prefix}/${proj}
-DCMAKE_BUILD_TYPE:STRING=${build_type}
-DBUILD_SHARED_LIBS:BOOL=OFF
-DBUILD_EXAMPLES:BOOL=OFF
-DBUILD_TESTING:BOOL=OFF
)
SET(ITK_DIR ${build_prefix}/ITK)
#=========================================================
#=========================================================
# VV
SET(VV_CMAKE_CXX_FLAGS ${CMAKE_CXX_FLAGS})
if(MSVC)
SET(VV_CMAKE_CXX_FLAGS "${VV_CMAKE_CXX_FLAGS} /bigobj")
endif(MSVC)
SET(VV_CMAKE_EXE_LINKER_FLAGS ${CMAKE_EXE_LINKER_FLAGS})
if(CMAKE_COMPILER_IS_GNUCXX)
SET(VV_CMAKE_EXE_LINKER_FLAGS "-static-libgcc -static-libstdc++")
endif(CMAKE_COMPILER_IS_GNUCXX)
SET(MAKE_COMMAND "make")
if(MSVC)
SET(MAKE_COMMAND "nmake")
endif(MSVC)
ExternalProject_Add(
VV
DEPENDS QT VTK ITK
SOURCE_DIR ${source_prefix}/vv
GIT_REPOSITORY git://git.creatis.insa-lyon.fr/clitk
INSTALL_COMMAND ${MAKE_COMMAND} package
CMAKE_ARGS
-DQT_QMAKE_EXECUTABLE:FILEPATH=${qmake_executable}
-DITK_DIR:PATH=${ITK_DIR}
-DVTK_DIR:PATH=${VTK_DIR}
-DCMAKE_C_FLAGS_DEBUG:STRING=${CMAKE_C_FLAGS_DEBUG}
-DCMAKE_C_FLAGS_MINSIZEREL:STRING=${CMAKE_C_FLAGS_MINSIZEREL}
-DCMAKE_C_FLAGS_RELEASE:STRING=${CMAKE_C_FLAGS_RELEASE}
-DCMAKE_C_FLAGS_RELWITHDEBINFO:STRING=${CMAKE_C_FLAGS_RELWITHDEBINFO}
-DCMAKE_CXX_FLAGS_DEBUG:STRING=${CMAKE_CXX_FLAGS_DEBUG}
-DCMAKE_CXX_FLAGS_MINSIZEREL:STRING=${CMAKE_CXX_FLAGS_MINSIZEREL}
-DCMAKE_CXX_FLAGS_RELEASE:STRING=${CMAKE_CXX_FLAGS_RELEASE}
-DCMAKE_CXX_FLAGS_RELWITHDEBINFO:STRING=${CMAKE_CXX_FLAGS_RELWITHDEBINFO}
-DCMAKE_CXX_FLAGS:STRING=${VV_CMAKE_CXX_FLAGS}
-DCMAKE_EXE_LINKER_FLAGS:STRING=${VV_CMAKE_EXE_LINKER_FLAGS}
-DCMAKE_INSTALL_PREFIX:PATH=${install_prefix}/${proj}
-DCMAKE_BUILD_TYPE:STRING=${build_type}
-DBUILD_SHARED_LIBS:BOOL=OFF
-DBUILD_TESTING:BOOL=OFF
-DBUILD_TESTING:BOOL=OFF
-DCLITK_BUILD_VV:BOOL=ON
-DCLITK_BUILD_REGISTRATION:BOOL=ON
-DCLITK_BUILD_SEGMENTATION:BOOL=ON
-DCLITK_BUILD_TOOLS:BOOL=ON
-DCLITK_EXPERIMENTAL:BOOL=ON
)
#=========================================================
More information about the vv
mailing list