CMakeCompilerABI.h 1.2 KB

123456789101112131415161718192021222324252627282930313233343536
  1. /*--------------------------------------------------------------------------*/
  2. /* Size of a pointer-to-data in bytes. */
  3. #define SIZEOF_DPTR (sizeof(void*))
  4. const char info_sizeof_dptr[] = {
  5. 'I', 'N', 'F', 'O', ':', 's', 'i', 'z', 'e', 'o', 'f', '_', 'd', 'p', 't', 'r', '[',
  6. ('0' + ((SIZEOF_DPTR / 10)%10)),
  7. ('0' + (SIZEOF_DPTR % 10)),
  8. ']','\0'};
  9. /*--------------------------------------------------------------------------*/
  10. /* Application Binary Interface. */
  11. #if defined(__sgi) && defined(_ABIO32)
  12. # define ABI_ID "ELF O32"
  13. #elif defined(__sgi) && defined(_ABIN32)
  14. # define ABI_ID "ELF N32"
  15. #elif defined(__sgi) && defined(_ABI64)
  16. # define ABI_ID "ELF 64"
  17. /* Check for (some) ARM ABIs.
  18. * See e.g. http://wiki.debian.org/ArmEabiPort for some information on this. */
  19. #elif defined(__GNU__) && defined(__ELF__) && defined(__ARM_EABI__)
  20. # define ABI_ID "ELF ARMEABI"
  21. #elif defined(__GNU__) && defined(__ELF__) && defined(__ARMEB__)
  22. # define ABI_ID "ELF ARM"
  23. #elif defined(__GNU__) && defined(__ELF__) && defined(__ARMEL__)
  24. # define ABI_ID "ELF ARM"
  25. #elif defined(__ELF__)
  26. # define ABI_ID "ELF"
  27. #endif
  28. #if defined(ABI_ID)
  29. static char const info_abi[] = "INFO:abi[" ABI_ID "]";
  30. #endif