[Insight-users] building problem on a registration project
Dawood Al Masslawi
masslawi at gmail.com
Sat Jun 11 12:11:18 EDT 2011
Hi Yann,
What are the main components of your registration code (the headers)?
Try changing the last line of your Cmake list with the following,
TARGET_LINK_LIBRARIES (Registrationtest2 ITKIO ITKNumerics)
HTH,
Dawood
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>><<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>><<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
Hi all,
I'm new to ITK. I was interested in its registration capacities. I download and succeed to build the sources (windows 32 bit, last cmake, visual studio 2008), and run the helloWorld example.
I write my own project, that is mostly derived from the registration examples.
But I have a full set of building errors, that seems to be related to the same problem (linkage to the libraries).
I expect this to be related to a bad cmake configuration, but I try hours to solve the problem unsuccessfully.
Here is my c make file :
# This is the root ITK CMakeLists file.
CMAKE_MINIMUM_REQUIRED(VERSION 2.4)
IF(COMMAND CMAKE_POLICY)
CMAKE_POLICY(SET CMP0003 NEW)
ENDIF(COMMAND CMAKE_POLICY)
# This project is designed to be built outside the Insight source tree.
PROJECT(Registrationtest2)
# Find ITK.
FIND_PACKAGE(ITK REQUIRED)
INCLUDE(${ITK_USE_FILE})
INCLUDE_DIRECTORIES( ${ITK_INCLUDE_DIR} )
link_directories(${ITK_lib_dir})
ADD_EXECUTABLE(Registrationtest2 Registrationtest2.cxx )
TARGET_LINK_LIBRARIES(Registrationtest2 ${ITK_LIBRARIES})
and a few lines of building errors that are related to sources i haven't change :
1>Registrationtest2.cxx
1>..\Registrationtest2.cxx(68) : error C2039: 'itkGradientDescentOptimizer' : n'est pas membre de 'itk'
1>..\Registrationtest2.cxx(68) : error C2146: erreur de syntaxe : absence de ';' avant l'identificateur 'OptimizerType'
1>..\Registrationtest2.cxx(68) : error C4430: spécificateur de type manquant - int est pris en compte par défaut. Remarque : C++ ne prend pas en charge int par défaut
1>..\Registrationtest2.cxx(68) : error C4430: spécificateur de type manquant - int est pris en compte par défaut. Remarque : C++ ne prend pas en charge int par défaut
1>..\Registrationtest2.cxx(69) : error C4430: spécificateur de type manquant - int est pris en compte par défaut. Remarque : C++ ne prend pas en charge int par défaut
1>..\Registrationtest2.cxx(69) : error C2143: erreur de syntaxe : absence de ';' avant '*'
1>..\Registrationtest2.cxx(69) : error C4430: spécificateur de type manquant - int est pris en compte par défaut. Remarque : C++ ne prend pas en charge int par défaut
1>..\Registrationtest2.cxx(78) : error C2065: 'OptimizerPointer' : identificateur non déclaré
(in French, sorry)
I hope someone could help me, I'm despairing... thanks a lot !
Yann
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.itk.org/pipermail/insight-users/attachments/20110611/f7741d6a/attachment.htm>
More information about the Insight-users
mailing list