wiki:Developer/Coding/Deprecating
Notice: We have migrated to GitLab launching 2024-05-01 see here: https://gitlab.rtems.org/

Version 3 (modified by Chris Johns, on 03/15/15 at 21:42:39) (diff)

Update TOC.

Deprecating Public Application Programming Interfaces

This page documents the procedures for deprecating a public-facing interface in RTEMS.

Use the deprecate attribute

Add the RTEMS_COMPILER_DEPRECATED_ATTRIBUTE, which for gcc wraps the deprecated attribute, to functions, structures, and global symbols exported by the deprecated interface. Update the doxygen for each of these with the @deprecated command, for example,

/**
 * @brief RTEMS Feature
 *
 * @deprecated Feature is deprecated and will be removed.
 */

Add a warning for configured features in confdefs.h

For features that are enabled or configured through confdefs.h, the feature should be disabled by default and a compile-time warning message should be printed, something along the lines of

 #warning "CONFIGURE_FEATURE_XXX\n\t\t\t**** Deprecated and will be removed. ****"

Update documentation

Find references to the deprecated feature in the user manuals (doc) and wiki, and make a note that the features are deprecated and may be removed.

Add a release note

Add the feature to a list of deprecated interfaces in the release notes.