[ITK Community] Error in ITKWikiExamples compilation

Matt McCormick matt.mccormick at kitware.com
Mon Feb 17 17:14:31 EST 2014


Hi Alok,

Yes, it looks like a bug.  Feel free to correct it on the wiki.

Thanks,
Matt

On Mon, Feb 17, 2014 at 4:36 PM, Alok <alok.theanomaly at gmail.com> wrote:
> Thanks Matt
>
> I will try that as soon as I can. However I do see a problem in the code.
> Here are lines 19 ~ 26 from the source (TransforFileReader.cxx) : Whoever
> wrote the code probably made a typo while writing the #if #else
>
>
> #if (ITK_VERSION_MAJOR == 4 && ITK_VERSION_MINOR >= 5) || ITK_VERSION_MAJOR
>> 4
>  itk::TransformFileReaderTemplate<float>::Pointer reader =
> itk::TransformFileReaderTemplate<float>::New();
> #else
>   itk::TransformFileReader::Pointer writer =
> itk::TransformFileReader::New();
> #endif
>
>   reader->SetFileName(fileName);
>   reader->Update();
>
>
> Alok
>
>
> On Mon, Feb 17, 2014 at 4:28 PM, Matt McCormick <matt.mccormick at kitware.com>
> wrote:
>>
>> Hi Alok,
>>
>> Please try with ITK 4.5.1, and let us know how it goes.
>>
>> Thanks,
>> Matt
>>
>> On Mon, Feb 17, 2014 at 3:43 PM, Alok <alok.theanomaly at gmail.com> wrote:
>> > Hi Matt,
>> >
>> > Sorry I hit Send accidentally earlier.
>> > Here are the details - ITKWikiExamples-4.5. I am currently using
>> > ITK-4.3.1
>> >
>> > Compile error:
>> >
>> > In file included from
>> > /home/alok/Documents/ITKWikiExamples/IO/TestTransformFileReader.cxx:2:0:
>> >
>> > /home/alok/Downloads/InsightWikiExamples-4.5.0/IO/TransformFileReader.cxx:
>> > In function 'int TestTransformFileReader(int, char**)':
>> >
>> > /home/alok/Downloads/InsightWikiExamples-4.5.0/IO/TransformFileReader.cxx:25:3:
>> > error: 'reader' was not declared in this scope
>> > make[2]: ***
>> > [IO/CMakeFiles/IOCxxTests.dir/TestTransformFileReader.cxx.o]
>> > Error 1
>> > make[1]: *** [IO/CMakeFiles/IOCxxTests.dir/all] Error 2
>> >
>> >
>> > On checking the source (TransformFileReader.cxx), I found there is a #if
>> > #else directive that is checking for the Version no. of library which
>> > looks
>> > incorrect.
>> >
>> > Alok
>> >
>> >
>> > On Mon, Feb 17, 2014 at 3:39 PM, Matt McCormick
>> > <matt.mccormick at kitware.com>
>> > wrote:
>> >>
>> >> Hi Alok,
>> >>
>> >> Which version?
>> >>
>> >> It looks like the error was omitted from the previous message.
>> >>
>> >> Thanks,
>> >> Matt
>> >>
>> >> On Mon, Feb 17, 2014 at 3:36 PM, Alok <alok.theanomaly at gmail.com>
>> >> wrote:
>> >> > Hi all,
>> >> >
>> >> > While trying to compile  ITKWIkiExamples I am getting an error:
>> >> >
>> >> >
>> >> > --
>> >> > I live a simple life...  in 0s and 1s !
>> >> >
>> >> > _______________________________________________
>> >> > Community mailing list
>> >> > Community at itk.org
>> >> > http://public.kitware.com/cgi-bin/mailman/listinfo/community
>> >> >
>> >
>> >
>> >
>> >
>> > --
>> > I live a simple life...  in 0s and 1s !
>
>
>
>
> --
> I live a simple life...  in 0s and 1s !



More information about the Community mailing list