Hi Andrew,
Yes, that?s correct, the old vxWorks gnu compiler doesn?t make private
members of class A accessible to nested class A :: B as the standard
requires. There is a simple fix to add "friend class B" to class A. I have
done this many times before but I neglected to take care of it in this
situation. There are many examples in base including some at the end of
class udpiiu's definition.
I committed a fix to R3.14.
Jeff
______________________________________________________
Jeffrey O. Hill Email [email protected]
LANL MS H820 Voice 505 665 1831
Los Alamos NM 87545 USA FAX 505 665 5107
Message content: TSPA
With sufficient thrust, pigs fly just fine. However, this is
not necessarily a good idea. It is hard to be sure where they
are going to land, and it could be dangerous sitting under them
as they fly overhead. -- RFC 1925
> -----Original Message-----
> From: Andrew Johnson [mailto:[email protected]]
> Sent: Thursday, September 08, 2011 11:22 AM
> To: Jeff Hill
> Subject: 3.14 branch broken for older vxWorks
>
> Hi Jeff,
>
> Janet pointed out that the 3.14 build has been broken for some time for
> older
> versions of vxWorks. The vxWorks 5.5.2 compilers give this error:
>
> /usr/local/vw/tornado22-68k/host/sun4-solaris2/bin/cc68k -c -
> DCPU=MC68040 -DvxWorks=vxWorks -include
> /usr/local/vw/tornado22-68k/target/h/vxWorks.h -O2 -Wall -m68040
> -
> fno-implicit-templates -fno-builtin -MMD -I. -I../O.Common -I. -I.. -
> I../../../include/os/vxWorks -I../../../include -
> I/usr/local/vw/tornado22-68k/target/h ../udpiiu.cpp
> ../udpiiu.cpp: In method `void
> udpiiu::M_repeaterTimerNotify::repeaterRegistrationMessage(unsigned int)':
> ../udpiiu.h:167: `class epicsMutex & udpiiu::cacMutex' is private
> ../udpiiu.cpp:407: within this context
> ../udpiiu.h:174: `SOCKET udpiiu::sock' is private
> ../udpiiu.cpp:408: within this context
> ../udpiiu.h:175: `ca_uint16_t udpiiu::repeaterPort' is private
> ../udpiiu.cpp:408: within this context
> ../udpiiu.cpp: In method `int
> udpiiu::M_repeaterTimerNotify::printFormated(epicsGuard<epicsMutex> &,
> const
> char *, ...)':
> ../udpiiu.h:165: `class cac & udpiiu::cacRef' is private
> ../udpiiu.cpp:1246: within this context
> ../udpiiu.cpp:1242: warning: `int status' might be used uninitialized in
> this
> function
>
> The vxWorks 5.4.2 compilers give this:
>
> /usr/local/vw/tornado202p1/host/sun4-solaris2/bin/ccppc -c -
> DCPU=PPC603 -DvxWorks=vxWorks -include
> /usr/local/vw/tornado202p1/target/h/vxWorks.h -O2 -Wall -mcpu=603
> -
> mstrict-align -fno-implicit-templates -fno-builtin -MMD -I. -
> I../O.Common -
> I. -I.. -I../../../include/os/vxWorks -I../../../include -
> I/usr/local/vw/tornado202p1/target/h ../udpiiu.cpp
> ../udpiiu.cpp: In method `repeaterRegistrationMessage':
> ../udpiiu.cpp:407: member `cacMutex' is a private member of class `udpiiu'
> ../udpiiu.cpp:408: member `sock' is a private member of class `udpiiu'
> ../udpiiu.cpp:408: member `repeaterPort' is a private member of class
> `udpiiu'
> ../udpiiu.cpp: In method `printFormated':
> ../udpiiu.cpp:1246: member `cacRef' is a private member of class `udpiiu'
> ../udpiiu.cpp:1242: warning: `status' might be used uninitialized in this
> function
>
> On vxWorks 6.8 though the same file compiles without error though.
>
> I'm guessing the problem dates back to this commit which was the last one
> that
> modified udpiiu.cpp:
>
> revno: 12261
> fixes bug(s): https://launchpad.net/bugs/816678
> committer: Jeff Hill <[email protected]>
> branch nick: 3.14
> timestamp: Tue 2011-07-26 16:23:34 -0600
> message:
> Changed repeaterTimerNotify interface implementation into a nested class
> of
> udpiiu so that we dont use multiple inheritance, and therefore hopefully
> avoid
> code generation problems with certain versions of g++ on MacOSX (I cant
> reproduce this problem on any ofthe machines here)
>
>
> - Andrew
> --
> Optimization is the process of taking something that works and
> replacing it with something that almost works, but costs less.
> -- Roger Needham
- Replies:
- Re: 3.14 branch broken for older vxWorks Andrew Johnson
- Navigate by Date:
- Prev:
RE: extern "C" { #include <...> } Jeff Hill
- Next:
RE: EPICS and SMP: target board ==> ivme7210 ==> OS ==> vxWorks Jeff Hill
- Index:
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: extern "C" { #include <...> } Andrew Johnson
- Next:
Re: 3.14 branch broken for older vxWorks Andrew Johnson
- Index:
2002
2003
2004
2005
2006
2007
2008
2009
2010
<2011>
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
|