SunPro-C-DetermineCompiler.cmake 620 B

123456789101112131415
  1. set(_compiler_id_pp_test "defined(__SUNPRO_C)")
  2. set(_compiler_id_version_compute "
  3. # if __SUNPRO_C >= 0x5100
  4. /* __SUNPRO_C = 0xVRRP */
  5. # define @PREFIX@COMPILER_VERSION_MAJOR @MACRO_HEX@(__SUNPRO_C>>12)
  6. # define @PREFIX@COMPILER_VERSION_MINOR @MACRO_HEX@(__SUNPRO_C>>4 & 0xFF)
  7. # define @PREFIX@COMPILER_VERSION_PATCH @MACRO_HEX@(__SUNPRO_C & 0xF)
  8. # else
  9. /* __SUNPRO_CC = 0xVRP */
  10. # define @PREFIX@COMPILER_VERSION_MAJOR @MACRO_HEX@(__SUNPRO_C>>8)
  11. # define @PREFIX@COMPILER_VERSION_MINOR @MACRO_HEX@(__SUNPRO_C>>4 & 0xF)
  12. # define @PREFIX@COMPILER_VERSION_PATCH @MACRO_HEX@(__SUNPRO_C & 0xF)
  13. # endif")