[Insight-developers] trying to fix mac warnings

Bradley Lowekamp blowekamp at mail.nih.gov
Wed Feb 23 22:28:22 EST 2011


Hello Mark,

Thanks for looking into addressing these warnings.

On the CDash webpage, next to the build name are 2-4 icons. The first icon, the note or document like icon, is a link to the cmake scripts used to generate the build. For example the continuous build mini1.nlm has the following ling:

http://www.cdash.org/CDash/viewNotes.php?buildid=875561

Of particular interest are the following variables:
CMAKE_CXX_FLAGS:STRING=-Wall -Wextra -Wunused -Wpointer-arith -Winvalid-pch -Wcast-align -Woverloaded-virtual -Wshadow -Wwrite-strings -Wstrict-null-sentinel
CMAKE_C_FLAGS:STRING=-Wall -Wextra -Wunused -Wpointer-arith -Winvalid-pch -Wcast-align -Wno-deprecated-declarations -Wno-uninitialized

Of particularly:

-Woverloaded-virtual (C++ and Objective-C++ only)
Warn when a function declaration hides virtual functions from a base class. For example, in:
          struct A {
            virtual void f();
          };
          
          struct B: public A {
            void f(int);
          };
     
the A class version of f is hidden in B, and code like:

          B* b;
          b->f();
     
will fail to compile. 


This warning has proven to be useful in tracking down methods which are not correctly overloaded with the same arguments, and generally had indicated a subtle programming error.


Brad


On Feb 23, 2011, at 1:04 PM, Mark Roden wrote:

> Hi all,
> 
> I'm looking in to the gdcm warnings shown here:
> 
> http://www.cdash.org/CDash/viewBuildError.php?type=1&buildid=874230
> 
> Problem is, I can't replicate the warnings when building with either
> unix makefiles or in xcode.
> 
> The warnings I'm seeing are more along these lines:
> 
> /usr/bin/ranlib: file:
> ../../bin/libitkvnl_inst.a(vnl_c_vector+longlong-.cxx.o) has no
> symbols
> /usr/bin/ranlib: file:
> ../../bin/libitkvnl_inst.a(vnl_c_vector+ulonglong-.cxx.o) has no
> symbols
> /usr/bin/ranlib: file:
> ../../bin/libitkvnl_inst.a(vnl_matrix+longlong-.cxx.o) has no symbols
> /usr/bin/ranlib: file:
> ../../bin/libitkvnl_inst.a(vnl_matrix+ulonglong-.cxx.o) has no symbols
> /usr/bin/ranlib: file:
> ../../bin/libitkvnl_inst.a(vnl_vector+longlong-.cxx.o) has no symbols
> /usr/bin/ranlib: file:
> ../../bin/libitkvnl_inst.a(vnl_vector+ulonglong-.cxx.o) has no symbols
> 
> which don't show up on that list of compiler warnings.
> 
> Can someone with more mac development experience point me to a way to
> replicate the warnings?
> 
> Thanks,
> Mark
> _______________________________________________
> 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.html
> 
> 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://www.itk.org/mailman/listinfo/insight-developers

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.itk.org/mailman/private/insight-developers/attachments/20110223/886ba633/attachment.htm>


More information about the Insight-developers mailing list