<html><head><style type="text/css"><!-- DIV {margin:0px;} --></style></head><body><div style="font-family:times new roman, new york, times, serif;font-size:12pt"><DIV>Hi, Luis: </DIV>
<DIV> </DIV>
<DIV>I changed the CMakeList.txt file as you suggested, but I can not build the IBSR classifcation.</DIV>
<DIV> </DIV>
<DIV>Here is what changed on the cmakelist</DIV>
<DIV> </DIV>
<DIV>cmake_minimum_required(VERSION 2.4)<BR>PROJECT( IBSRClassification )</DIV>
<DIV>SET( BUILD_OUTSIDE_INSIGHT_APPLICATIONS 1 )</DIV>
<DIV>IF( BUILD_OUTSIDE_INSIGHT_APPLICATIONS )</DIV>
<DIV> FIND_PACKAGE(ITK)<BR> IF(ITK_FOUND)<BR> INCLUDE(${ITK_USE_FILE})<BR> ELSE(ITK_FOUND)<BR> MESSAGE(FATAL_ERROR<BR> "Cannot build InsightApplications without ITK. Please set ITK_DIR.")<BR> ENDIF(ITK_FOUND)</DIV>
<DIV>ENDIF( BUILD_OUTSIDE_INSIGHT_APPLICATIONS )</DIV>
<DIV> </DIV>
<DIV>I copy IBSRClassifaction in to a folder IBSR, I have my build foler in IBSR.</DIV>
<DIV>Then I went in to build folder, type ccmake ../IBSRClassification.</DIV>
<DIV> </DIV>
<DIV>Can you please tell me how to make it works?</DIV>
<DIV>I may have similar problem when I write my own template function as individual filels. Finally I put the function implemenation in the header. I think I can learn a lot to make the progam flexibel once I can sovel this problem.</DIV>
<DIV> </DIV>
<DIV>Best regards</DIV>
<DIV> </DIV>
<DIV>Baoyun</DIV>
<DIV> </DIV>
<DIV> </DIV>
<DIV>Below is the error message:</DIV>
<DIV> </DIV>
<DIV>/home/gtao/code/vector_segmentation/IBSR/IBSRClassification/Code/ClassifierValidationInputParser.txx:192: error: expected initializer before \ufffd\ufffd\ufffd<\ufffd\ufffd\ufffd token<BR>/home/gtao/code/vector_segmentation/IBSR/IBSRClassification/Code/ClassifierValidationInputParser.txx:193: error: \ufffd\ufffd\ufffdReaderType\ufffd\ufffd\ufffd has not been declared<BR>/home/gtao/code/vector_segmentation/IBSR/IBSRClassification/Code/ClassifierValidationInputParser.txx:193: error: expected initializer before \ufffd\ufffd\ufffdreader\ufffd\ufffd\ufffd<BR>/home/gtao/code/vector_segmentation/IBSR/IBSRClassification/Code/ClassifierValidationInputParser.txx:197: error: \ufffd\ufffd\ufffdReaderType\ufffd\ufffd\ufffd has not been declared<BR>/home/gtao/code/vector_segmentation/IBSR/IBSRClassification/Code/ClassifierValidationInputParser.txx:197: error: expected initializer before
\ufffd\ufffd\ufffdspacing\ufffd\ufffd\ufffd<BR>/home/gtao/code/vector_segmentation/IBSR/IBSRClassification/Code/ClassifierValidationInputParser.txx:198: error: \ufffd\ufffd\ufffdReaderType\ufffd\ufffd\ufffd has not been declared<BR>/home/gtao/code/vector_segmentation/IBSR/IBSRClassification/Code/ClassifierValidationInputParser.txx:198: error: expected initializer before \ufffd\ufffd\ufffdsize\ufffd\ufffd\ufffd<BR>/home/gtao/code/vector_segmentation/IBSR/IBSRClassification/Code/ClassifierValidationInputParser.txx:201: error: \ufffd\ufffd\ufffdspacing\ufffd\ufffd\ufffd was not declared in this scope<BR>/home/gtao/code/vector_segmentation/IBSR/IBSRClassification/Code/ClassifierValidationInputParser.txx:202: error: \ufffd\ufffd\ufffdsize\ufffd\ufffd\ufffd was not declared in this scope<BR>/home/gtao/code/vector_segmentation/IBSR/IBSRClassification/Code/ClassifierValidationInputParser.txx:204: error: \ufffd\ufffd\ufffdreader\ufffd\ufffd\ufffd was not
declared in this scope<BR>/home/gtao/code/vector_segmentation/IBSR/IBSRClassification/Code/ClassifierValidationOutput.txx: In member function \ufffd\ufffd\ufffdvoid itk::ClassifierValidationOutput<TImage>::Execute()\ufffd\ufffd\ufffd:<BR><BR></DIV>
<DIV style="FONT-SIZE: 12pt; FONT-FAMILY: times new roman, new york, times, serif"><BR>
<DIV style="FONT-SIZE: 13px; FONT-FAMILY: arial, helvetica, sans-serif"><FONT face=Tahoma size=2>
<HR SIZE=1>
<B><SPAN style="FONT-WEIGHT: bold">From:</SPAN></B> Luis Ibanez <luis.ibanez@kitware.com><BR><B><SPAN style="FONT-WEIGHT: bold">To:</SPAN></B> Baoyun Li <baoyun_li123@yahoo.com>; Insight Users <insight-users@itk.org><BR><B><SPAN style="FONT-WEIGHT: bold">Sent:</SPAN></B> Wednesday, March 4, 2009 12:28:45 PM<BR><B><SPAN style="FONT-WEIGHT: bold">Subject:</SPAN></B> Re: can not build--IBSRClassification application<BR></FONT><BR><BR>Hi Baoyun,<BR><BR><BR>Please look inside of the CMakeLists.txt file in the directory;<BR><BR> InsightApplications/IBSRValidation/IBSRClassification<BR><BR><BR>You will find:<BR><BR><BR>PROJECT( IBSRClassification )<BR><BR>IF( BUILD_OUTSIDE_INSIGHT_APPLICATIONS )<BR><BR> FIND_PACKAGE(ITK)<BR> IF(ITK_FOUND)<BR> INCLUDE(${ITK_USE_FILE})<BR> ELSE(ITK_FOUND)<BR> MESSAGE(FATAL_ERROR<BR> "Cannot build InsightApplications
without ITK. Please set ITK_DIR.")<BR> ENDIF(ITK_FOUND)<BR><BR>ENDIF( BUILD_OUTSIDE_INSIGHT_APPLICATIONS )<BR><BR><BR><BR>If you add a line:<BR><BR> SET( BUILD_OUTSIDE_INSIGHT_APPLICATIONS 1 )<BR><BR>Just below the PROJECT() command, then you should be able to<BR>configure and build this application outside of the larger set<BR>of InsightApplications.<BR><BR><BR><BR><BR>If you need further help with your CMakeLists.txt file,<BR>then please post it to the ITK users list.<BR><BR><BR><BR> Regards,<BR><BR><BR> Luis<BR><BR></DIV></DIV></div><br>
</body></html>