[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [lmi] Upgrading to gcc-4.9.2

From: Greg Chicares
Subject: Re: [lmi] Upgrading to gcc-4.9.2
Date: Thu, 17 Dec 2015 15:39:25 +0000
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Icedove/31.3.0

On 2015-12-17 02:28, Greg Chicares wrote:
> In file included from /opt/lmi/local/include/wx/pdfdocument.h:25:0,
>                  from /opt/lmi/local/include/wx/pdfdc.h:21,
>                  from /lmi/src/lmi/group_quote_pdf_gen_wx.cpp:56:
> /opt/lmi/local/include/wx/pdfarraytypes.h:27:86: error: invoking macro 
> WX_DEFINE_SORTED_USER_EXPORTED_TYPEARRAY argument 4: empty macro arguments 
> are undefined in ISO C90 and ISO C++98
>         ^

This seems to go away with '-std=c++11'.

A complete rebuild with '-std=c++11' yields:

$echo $coefficiency
$time make $coefficiency install check_physical_closure >../log 2>&1
make $coefficiency install check_physical_closure > ../log 2>&1
1343.88s user 959.94s system 196% cpu 19:30.56 total

$sed -f diagnostics.sed ../log |grep 'error:' | sed -e's/^[^[]*\([[].*$\)/\1/' 
|sort |uniq -c |sort -nr

   1950 [-Werror=unused-local-typedefs]
    517 [-Werror=conversion]
    274 [-Werror=parentheses]
     24 [-Werror=unused-variable]
     23 [-Werror=float-conversion]
      8 [-Werror=deprecated-declarations]
      1 [-Werror=attributes]

I guess we'll reluctantly have to turn some of those warnings off
because they occur in 'boost' headers...unless we can replace those
headers with compiler-provided equivalents, or upgrade to a later
version of boost that compiles without warnings. Specifically:


/opt/lmi/third_party/include/boost/static_assert.hpp:105:21: error: \
typedef ‘boost_static_assert_typedef_108’ locally defined but not \
used [-Werror=unused-local-typedefs]
          BOOST_JOIN(boost_static_assert_typedef_, __LINE__)


/opt/lmi/third_party/include/boost/mpl/aux_/integral_wrapper.hpp:73:96: error: \
the result of the conversion is unspecified because ‘-1’ is outside the range 
of \
type ‘boost::numeric::int_float_mixture_enum’ [-Werror=conversion]


/opt/lmi/third_party/include/boost/bind/placeholders.hpp:56:15: error: \
‘{anonymous}::_3’ defined but not used [-Werror=unused-variable]

 boost::arg<3> _3;


/opt/lmi/third_party/src/libxml/node.cxx:284:33: error: \
‘auto_ptr’ is deprecated (declared at 
     std::auto_ptr<node_impl> ap(pimpl_ = new node_impl);

Perhaps Vaclav has changed xmlwrapp.


/lmi/src/lmi/tools/pete-2.1.1/PETE/OperatorTags.h:337:18: error: \
conversion to ‘BinaryReturn<double, long double, OpMultiply>::Type_t {aka 
double}’ \
from ‘long double’ may alter its value [-Werror=float-conversion]
     return (a * b);

Maybe I can take care of that, along with various occurrences in lmi.


/lmi/src/lmi/main_common.cpp:48:25: error: ‘unsigned int _get_output_format()’ \
redeclared without dllimport attribute: previous dllimport ignored 
 extern "C" unsigned int _get_output_format(void) {return 1;}

I'll look into that.


/lmi/src/lmi/value_cast.hpp:206:13: error: suggest parentheses around ‘&&’ 
within ‘||’ \

This warning might be just noise. Here's the code:

        one_numeric_one_string =
                boost::is_arithmetic<From>::value && is_string<To  >::value
            ||  boost::is_arithmetic<To  >::value && is_string<From>::value

It seems to warn against
  a && b || c && d
but allow
  a * b + c * d
and I think both are reasonable and should be accepted without any warning.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]