Experimental Physics and Industrial Control System
Hi,
I have run into a problem with areaDetector compilation when enabling EPICS4
using version 4.6.0 on Ubuntu16.04.3 LTS.
../ntndArrayConverter.cpp: In member function ‘void
NTNDArrayConverter::fromUndefinedAttribute(epics::pvData::PVStructurePtr)’:
../ntndArrayConverter.cpp:497:54: error: no matching function for call to
‘std::tr1::shared_ptr<epics::pvData::PVField>::reset() const’
dest->getSubField<PVUnion>("value")->get().reset();
^
In file included from /usr/include/c++/5/tr1/memory:50:0,
from
/home/wuestenf/EPICS/EPICS-3.15.5/EPICS-CPP-4.6.0/pvDataCPP/include/pv/sharedPtr.h:124,
from
/home/wuestenf/EPICS/EPICS-3.15.5/EPICS-CPP-4.6.0/pvDataCPP/include/pv/pvType.h:41,
from
/home/wuestenf/EPICS/EPICS-3.15.5/EPICS-CPP-4.6.0/pvDataCPP/include/pv/pvDisplay.h:14,
from
/home/wuestenf/EPICS/EPICS-3.15.5/EPICS-CPP-4.6.0/normativeTypesCPP/include/pv/ntndarray.h:17,
from ../ntndArrayConverter.h:2,
from ../ntndArrayConverter.cpp:4:
/usr/include/c++/5/tr1/shared_ptr.h:644:7: note: candidate: void
std::tr1::__shared_ptr<_Tp, _Lp>::reset() [with _Tp =
epics::pvData::PVField; __gnu_cxx::_Lock_policy _Lp =
(__gnu_cxx::_Lock_policy)2u] <near match>
reset() // never throws
^
/usr/include/c++/5/tr1/shared_ptr.h:644:7: note: passing ‘const PVFieldPtr*
{aka const std::tr1::shared_ptr<epics::pvData::PVField>*}’ as ‘this’
argument discards qualifiers
/usr/include/c++/5/tr1/shared_ptr.h:649:9: note: candidate: template<class
_Tp1> void std::tr1::__shared_ptr<_Tp, _Lp>::reset(_Tp1*) [with _Tp1 = _Tp1;
_Tp = epics::pvData::PVField; __gnu_cxx::_Lock_policy _Lp =
(__gnu_cxx::_Lock_policy)2u]
reset(_Tp1* __p) // _Tp1 must be complete.
^
/usr/include/c++/5/tr1/shared_ptr.h:649:9: note: template argument
deduction/substitution failed:
../ntndArrayConverter.cpp:497:54: note: candidate expects 1 argument, 0
provided
dest->getSubField<PVUnion>("value")->get().reset();
^
In file included from /usr/include/c++/5/tr1/memory:50:0,
from
/home/wuestenf/EPICS/EPICS-3.15.5/EPICS-CPP-4.6.0/pvDataCPP/include/pv/sharedPtr.h:124,
from
/home/wuestenf/EPICS/EPICS-3.15.5/EPICS-CPP-4.6.0/pvDataCPP/include/pv/pvType.h:41,
from
/home/wuestenf/EPICS/EPICS-3.15.5/EPICS-CPP-4.6.0/pvDataCPP/include/pv/pvDisplay.h:14,
from
/home/wuestenf/EPICS/EPICS-3.15.5/EPICS-CPP-4.6.0/normativeTypesCPP/include/pv/ntndarray.h:17,
from ../ntndArrayConverter.h:2,
from ../ntndArrayConverter.cpp:4:
/usr/include/c++/5/tr1/shared_ptr.h:658:9: note: candidate: template<class
_Tp1, class _Deleter> void std::tr1::__shared_ptr<_Tp, _Lp>::reset(_Tp1*,
_Deleter) [with _Tp1 = _Tp1; _Deleter = _Deleter; _Tp =
epics::pvData::PVField; __gnu_cxx::_Lock_policy _Lp =
(__gnu_cxx::_Lock_policy)2u]
reset(_Tp1* __p, _Deleter __d)
^
/usr/include/c++/5/tr1/shared_ptr.h:658:9: note: template argument
deduction/substitution failed:
../ntndArrayConverter.cpp:497:54: note: candidate expects 2 arguments, 0
provided
dest->getSubField<PVUnion>("value")->get().reset();
The used gcc version is 5.4.0. On Ubuntu 14.04.5 LTS The error comes at the
same line, but different problem:
../ntndArrayConverter.cpp: In member function ‘void
NTNDArrayConverter::fromUndefinedAttribute(epics::pvData::PVStructurePtr)’:
../ntndArrayConverter.cpp:497:54: error: passing ‘const PVFieldPtr {aka
const std::tr1::shared_ptr<epics::pvData::PVField>}’ as ‘this’ argument of
‘void std::tr1::__shared_ptr<_Tp, _Lp>::reset() [with _Tp =
epics::pvData::PVField; __gnu_cxx::_Lock_policy _Lp =
(__gnu_cxx::_Lock_policy)2u]’ discards qualifiers [-fpermissive]
dest->getSubField<PVUnion>("value")->get().reset();
here the used gcc version is 4.8. It look like an explicit typecast is
necessary here. But what would be the correct type?
Regards,
Jörn
- Replies:
- Re: Compile error with areaDetector Mark Rivers
- Navigate by Date:
- Prev:
Re: Building AreaDetector from source Lang, Keenan C.
- Next:
Re: Building AreaDetector from source Stephen Molloy
- Index:
1994
1995
1996
1997
1998
1999
2000
2001
2002
2003
2004
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
<2017>
2018
2019
2020
2021
2022
2023
2024
- Navigate by Thread:
- Prev:
Re: Building AreaDetector from source Stephen Molloy
- Next:
Re: Compile error with areaDetector Mark Rivers
- Index:
1994
1995
1996
1997
1998
1999
2000
2001
2002
2003
2004
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
<2017>
2018
2019
2020
2021
2022
2023
2024