Add a #if ( configUSE_TIMERS ) conditional compilation constant in to allow the software timers source file to be included in a build that is not configured to use timers without resulting in linker errors.

This commit is contained in:
Richard Barry 2011-03-31 14:09:21 +00:00
parent 876caa2967
commit 8bd2d2f682

View File

@ -63,6 +63,12 @@ task.h is included from an application file. */
#undef MPU_WRAPPERS_INCLUDED_FROM_API_FILE
/* This entire source file will be skipped if the application is not configured
to include software timer functionality. This #if is closed at the very bottom
of this file. If you want to include software timer functionality then ensure
configUSE_TIMERS is set to 1 in FreeRTOSConfig.h. */
#if ( configUSE_TIMERS == 1 )
/* Misc definitions. */
#define tmrNO_DELAY ( portTickType ) 0U
@ -621,3 +627,7 @@ xTIMER *pxTimer = ( xTIMER * ) xTimer;
}
/*-----------------------------------------------------------*/
/* This entire source file will be skipped if the application is not configured
to include software timer functionality. If you want to include software timer
functionality then ensure configUSE_TIMERS is set to 1 in FreeRTOSConfig.h. */
#endif /* configUSE_TIMERS == 1 */