[ITK-dev] Problems with Change in itkStaticConstMacro

Matt McCormick matt.mccormick at kitware.com
Thu Jan 21 14:41:42 EST 2016


Hi,

PEP 513 proposes using GCC 4.8.2 in a CentOS 5 Docker image.  This was
discussed here:

  http://kitware.com/blog/home/post/986

Our planned compiler support does not explicitly mention GCC 4.1, but
it says GCC 4.2 should be phased out this year:

  http://www.itk.org/Wiki/ITK_Release_4/Modern_C%2B%2B

Matt

On Thu, Jan 21, 2016 at 2:27 PM, Bradly Lowekamp <blowekamp at mail.nih.gov> wrote:
> Just to re-iterate the importance of maintain full support for GCC 4.1 with
> the ability is instantiate ITK templates, here is the new Python PEP 513[1],
> which suggests using CentOS with gcc 4.1
>
> Also note my working around for disabling SimpleITK’s explicit template
> instantiation, did not work [2] yet.
>
> Brad
>
>
> [1] https://www.python.org/dev/peps/pep-0513/
> [2] https://open.cdash.org/index.php?project=SimpleITK
>
> On Jan 20, 2016, at 10:00 AM, Bradly Lowekamp <blowekamp at mail.nih.gov>
> wrote:
>
> Hello Luc,
>
> Thanks for looking into this.
>
> This bug is related to the older GCC 4.1 compiler that is found standard
> with Redhat 5 and Fedora 5 and used for distributions such as Anaconda’s
> Python. I apologize for the incorrect version before.
>
> Here is some ITK code to reproduce the error:
> http://review.source.kitware.com/#/c/20674/
>
> Thank you for exploring a minimal test case. Your code does compile and run
> OK with GCC 4.1.
>
> As a work around for SimpleITK I have disabled the SimpleITK Explicit
> library for now [1], this is not an optimal solution, and we should try to
> get explicit instantiation working again with GCC 4.1
>
> Brad
>
>
> https://github.com/SimpleITK/SimpleITK/compare/next#diff-af3b638bc2a3e6c650974192a53c7291
>
>
> On Jan 20, 2016, at 4:39 AM, Luc Hermitte <luc.hermitte at c-s.fr> wrote:
>
> Le 20/01/2016 09:57, Luc Hermitte a écrit :
>
> Hello,
>
> Le 19/01/2016 21:19, Bradley Lowekamp a écrit :
>
> Hello,
>
> My release builds for SimpleITK are having significant problems with the
> change done here [1] to the itkStaticConstMacro.
>
> My builds on Redhat 5, with gcc 5.1, are filling my disk with errors
> along the following:
> [...]
>
> [...]
>
>
> I’ll look into alternatives...
>
>
> Can you isolate the error on a simple test case that reproduce the issue?
>
>
> I've tried the file attached on https://ideone.com/SGlJ1i but it seems
> valid with GCC 5.1.
>
> However, in C++11, constexpr is required. And my g++ 4.8.2, and clang++
> as well, tell me:
>
> || g++ -std=c++03 -Werror -Wall -pedantic    extern-templ.cpp   -o
> extern-templ
> extern-templ.cpp|19 col 24| error: ISO C++ 1998 forbids the use of
> 'extern' on explicit instantiations [-Werror=pedantic]
> ||  extern template struct Bar<Foo<int>, Foo<double> >;
>
>
> What differs in SimpleITK source code?
>
>
> --Luc
> <extern-templ.cpp>
>
>
> _______________________________________________
> Powered by www.kitware.com
>
> Visit other Kitware open-source projects at
> http://www.kitware.com/opensource/opensource.html
>
> Kitware offers ITK Training Courses, for more information visit:
> http://kitware.com/products/protraining.php
>
> Please keep messages on-topic and check the ITK FAQ at:
> http://www.itk.org/Wiki/ITK_FAQ
>
> Follow this link to subscribe/unsubscribe:
> http://public.kitware.com/mailman/listinfo/insight-developers
>
>
>
> _______________________________________________
> Powered by www.kitware.com
>
> Visit other Kitware open-source projects at
> http://www.kitware.com/opensource/opensource.html
>
> Kitware offers ITK Training Courses, for more information visit:
> http://kitware.com/products/protraining.php
>
> Please keep messages on-topic and check the ITK FAQ at:
> http://www.itk.org/Wiki/ITK_FAQ
>
> Follow this link to subscribe/unsubscribe:
> http://public.kitware.com/mailman/listinfo/insight-developers
>


More information about the Insight-developers mailing list