On Visual studio I can force use of 32-bit time_t by declaring _USE_32BIT_TIME_T. Is there a similar equivalent for gcc? or is it always 32-bit or is it always 64-bit?
On Visual studio I can force use of 32-bit time_t by declaring _USE_32BIT_TIME_T .
Share
The
time_ttype is not defined by gcc but rather by system library. On Linux, this is glibc, and it definestime_tintime.hheader:which is in turn defined in
bits/types.h:(
__STD_TYPEdefinition is not interesting),__TIME_T_TYPEis defined inbits/typesizes.h:which is in turn defined in
bits/types.h:which is 32 bits on 32 bits system, 64 bits on 64 bits system. All these definitions are unconditional, so, no
_USE_32BIT_TIME_Tequivalent on glibc.