-
Notifications
You must be signed in to change notification settings - Fork 95
Description
Hello,
We are porting our product to RHEL8. Our old configuration is this:
$ cat /etc/redhat-release
Red Hat Enterprise Linux Server release 7.9 (Maipo)
$ gcc --version
gcc (GCC) 4.8.5 20150623 (Red Hat 4.8.5-44)
and our NEW environent:
$ cat /etc/redhat-release
Red Hat Enterprise Linux release 8.6 (Ootpa)
$ gcc --version
gcc (GCC) 8.5.0 20210514 (Red Hat 8.5.0-10)
In this new environment I am getting conflicts between boost and roguewave (SourcePro).
Roguewave: SourceProEd2021.1-Linux64 (el8)
Boost: boost_1_80_0
The EXACT same setup builds fine on rhel7 but not on rhel8 so i believe the new compiler is discovering this ambiguity whereas the old gcc compiler was able to resolve it.
I boiled it down to having two headers in the source file: here is the full source file:
$cat aes_CamsTest.cc
// START INCLUDES
#include "boost/date_time/posix_time/posix_time.hpp"
#include "rw/tools/bustring.h"
And here is the compile command:
/bin/g++ -DBUILD_64 -D_RWCONFIG_12s -O3 -Wformat -Wformat-security -fPIC -MD -fstack-protector -isystem/homes/reedca/cots/boost_1_80_0 -isystem/apps64/pds/cots/rogue/SourceProEd2021.1-Linux64.el8/includes -isystem/apps64/pds/cots/rogue/SourceProEd12021.1-Linux64.el8/includes/rw/config -m64 -std=c++14 -c /tms/pdsgit/reedca/pds-server-4/system/develop/aes/source/aes_CamsTest.cc -o /tms/pdsgit/reedca/pds-server-4/system/develop/aes/obj/Linux/aes_CamsTest.o
The new error is here and is repeated several times for the various different boost date_time types:
In file included from /homes/reedca/cots/boost_1_80_0/boost/date_time/gregorian/greg_duration_types.hpp:15,
from /homes/reedca/cots/boost_1_80_0/boost/date_time/gregorian/gregorian_types.hpp:22,
from /homes/reedca/cots/boost_1_80_0/boost/date_time/posix_time/posix_time_config.hpp:18,
from /homes/reedca/cots/boost_1_80_0/boost/date_time/posix_time/posix_time_system.hpp:13,
from /homes/reedca/cots/boost_1_80_0/boost/date_time/posix_time/ptime.hpp:12,
from /homes/reedca/cots/boost_1_80_0/boost/date_time/posix_time/posix_time.hpp:15,
from /tms/pdsgit/reedca/pds-server-4/system/develop/aes/source/aes_CamsTest.cc:2:
/homes/reedca/cots/boost_1_80_0/boost/date_time/adjust_functors.hpp: In instantiation of 'boost::date_time::month_functor<date_type>::duration_type boost::date_time::month_functor<date_type>::get_offset(const date_type&) const [with date_type = boost::gregorian::date; boost::date_time::month_functor<date_type>::duration_type = boost::gregorian::date_duration]':
/homes/reedca/cots/boost_1_80_0/boost/date_time/date_duration_types.hpp:67:16: required from 'constexpr boost::date_time::months_duration<base_config>::duration_type boost::date_time::months_duration<base_config>::get_offset(const date_type&) const [with base_config = boost::gregorian::greg_durations_config; boost::date_time::months_duration<base_config>::duration_type = boost::gregorian::date_duration; boost::date_time::months_duration<base_config>::date_type = boost::gregorian::date]'
/homes/reedca/cots/boost_1_80_0/boost/date_time/posix_time/date_duration_operators.hpp:33:37: required from here
/homes/reedca/cots/boost_1_80_0/boost/date_time/adjust_functors.hpp:71:110: error: ambiguous overload for 'operator+' (operand types are 'boost::gregorian::greg_year' and 'int')
const typename ymd_type::year_type year(static_cast(ymd.year + wi.add(f_)));
~~~~~~~~~^~~~~~~~~~~~
/homes/reedca/cots/boost_1_80_0/boost/date_time/adjust_functors.hpp:71:110: note: candidate: 'operator+(int, int)'
In file included from /tms/pdsgit/reedca/pds-server-4/system/develop/aes/source/aes_CamsTest.cc:3:
/apps64/pds/cots/rogue/SourceProEd2021.1-Linux64.el8/includes/rw/tools/bustring.h:4214:1: note: candidate: 'RWBasicUString operator+(RWUChar16, const RWBasicUString&)'
operator+(RWUChar16 lhs, const RWBasicUString& rhs)
^~~~~~~~
/apps64/pds/cots/rogue/SourceProEd2021.1-Linux64.el8/includes/rw/tools/bustring.h:4228:1: note: candidate: 'RWBasicUString operator+(RWUChar32, const RWBasicUString&)'
operator+(RWUChar32 lhs, const RWBasicUString& rhs)
^~~~~~~~
Please advise:
Thanks.
Cameron Reed
Staff Software Engineer
Wabtec Corporation
321-591-5131