we inserted ‘base’ FreeRTOS in our projects and everything work fine.
Now I need to add the Ethernet support and I added the TCP package.
For a compile test I onlt added the FreeRTOS_IP.c file: it generates a lot of errors.
I dig them until I guess to have found the root problem: in list.h file some functions are defined with the constant PRIVILEGED_FUNCTION.
This one generates the error:
FreeRTOS\include/list.h:386:6: error: old-style parameter declarations in prototyped function definition
and all the other errors.
I found the definition of this constant in mpu_wrappers.h: this is included by portable.h file that is included by FreeRTOS.h file.
My guess the problem is due to the late inclusion of FreeRTOS.h in the FreeRTOS_IP.c file: the previous inclusions of the .h files do not see the constant definitions and produce the error.
If I move the FreeRTOS.h before the FreeRTOS_.h files I get the error:
include/tcp/FreeRTOS_ARP.h:77:2: error: unknown type name 'MACAddress_t' MACAddress_t xMACAddress; /* The MAC address of an ARP cache entry. */
but this type is defined in the FreeRTOS_IP.h that’s included after the FreeRTOS_APR.h.
I’m lost in the inclusion order of the h files …