SunPro-CXX-DetermineCompiler.cmake 629 B

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