[Bug 1922] multiple definition of `_Scheduler_CBS_Server_list'

bugzilla-daemon at rtems.org bugzilla-daemon at rtems.org
Tue Sep 27 11:45:49 UTC 2011


https://www.rtems.org/bugzilla/show_bug.cgi?id=1922

--- Comment #6 from Joel Sherrill <joel.sherrill at oarcorp.com> 2011-09-27 06:45:46 CDT ---
The test portion is OK.  The score part has an issue.  The schedulers need to
all be self-contained.  Each is optional and pluggable.  Their data should be
instantiated in the initialization method for the specific scheduler.  If you
use SCORE_EXTERN, then it this file's data is supposed to get instantiated in
the same place as other score data and that means you would have to include
this .h file somewhere common like an OS level init file (bad) and have its
data in most executables.  There are only a couple of options:

+ Continue to extern the data for the scheduler in the .h file and declare it
in a scheduler specific file.

+ Use a scheduler specific XXX_EXTERN to get it to be extern in the .h file and
instantiated in the .c with the scheduler CBS and EDF init.

In this case, as much as I don't like duplicating the declaration information,
it seems rather heavy handed to add SCHEDULER_CBS_EXTERN and
SCHEDULER_EDF_EXTERN and do the trick needed for one variable.

-- 
Configure bugmail: https://www.rtems.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are watching all bug changes.



More information about the bugs mailing list