This is the mail archive of the ecos-discuss@sources.redhat.com mailing list for the eCos project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Will gcc3.3 will work with eCos?.


>>>>> " " == =?iso-8859-1?q?radhakrishnan=20R?=  <iso-8859-1> writes:

     > Hi All,
     >    I like thank you for answering my questions.
   
     >    Do you meant to say, if i use __attribute__
     >   ((init_priority (42))) with the required priority
     > number, i will get the same behaviour as
     > -finit-priority?.

Not quite. The syntax for giving a C++ static object a constructor
priority has always been __attribute__ ((init_priority (<num>))),
since that functionality was added back in 1997 or so. However early
on this syntax was only accepted if you also specified -finit-priority
on the command line. If you tried to use an init_priority attribute
without -finit-priority then the compiler would give an error or
something like that - I don't remember the exact details.

It did not take long before the init_priority attribute was considered
mainstream rather than experimental. Hence the compiler was changed so
that it would always accept the attribute, irrespective of whether or
not -finit-priority was specified on the command line. So
-finit-priority no longer served any purpose. It was kept around for a
while for compatibility reasons, but removed recently as part of a
more general clean-up of compiler command-line options.

Bart

-- 
Bart Veer                       eCos Configuration Architect
http://www.ecoscentric.com/     The eCos and RedBoot experts

-- 
Before posting, please read the FAQ: http://sources.redhat.com/fom/ecos
and search the list archive: http://sources.redhat.com/ml/ecos-discuss


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]