slp_platformselect.h 3.0 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758
  1. /*
  2. * Platform Selection for Stackless Python
  3. */
  4. #if defined(MS_WIN32) && !defined(MS_WIN64) && defined(_M_IX86) && defined(_MSC_VER)
  5. #include "platform/switch_x86_msvc.h" /* MS Visual Studio on X86 */
  6. #elif defined(MS_WIN64) && defined(_M_X64) && defined(_MSC_VER) || defined(__MINGW64__)
  7. #include "platform/switch_x64_msvc.h" /* MS Visual Studio on X64 */
  8. #elif defined(__GNUC__) && defined(__amd64__) && defined(__ILP32__)
  9. #include "platform/switch_x32_unix.h" /* gcc on amd64 with x32 ABI */
  10. #elif defined(__GNUC__) && defined(__amd64__)
  11. #include "platform/switch_amd64_unix.h" /* gcc on amd64 */
  12. #elif defined(__GNUC__) && defined(__i386__)
  13. #include "platform/switch_x86_unix.h" /* gcc on X86 */
  14. #elif defined(__GNUC__) && defined(__powerpc64__) && (defined(__linux__) || defined(__FreeBSD__))
  15. #include "platform/switch_ppc64_linux.h" /* gcc on PowerPC 64-bit */
  16. #elif defined(__GNUC__) && defined(__PPC__) && (defined(__linux__) || defined(__FreeBSD__))
  17. #include "platform/switch_ppc_linux.h" /* gcc on PowerPC */
  18. #elif defined(__GNUC__) && defined(__ppc__) && defined(__APPLE__)
  19. #include "platform/switch_ppc_macosx.h" /* Apple MacOS X on PowerPC */
  20. #elif defined(__GNUC__) && defined(__powerpc64__) && defined(_AIX)
  21. #include "platform/switch_ppc64_aix.h" /* gcc on AIX/PowerPC 64-bit */
  22. #elif defined(__GNUC__) && defined(_ARCH_PPC) && defined(_AIX)
  23. #include "platform/switch_ppc_aix.h" /* gcc on AIX/PowerPC */
  24. #elif defined(__GNUC__) && defined(sparc)
  25. #include "platform/switch_sparc_sun_gcc.h" /* SunOS sparc with gcc */
  26. #elif defined(__SUNPRO_C) && defined(sparc) && defined(sun)
  27. #include "platform/switch_sparc_sun_gcc.h" /* SunStudio on amd64 */
  28. #elif defined(__SUNPRO_C) && defined(__amd64__) && defined(sun)
  29. #include "platform/switch_amd64_unix.h" /* SunStudio on amd64 */
  30. #elif defined(__SUNPRO_C) && defined(__i386__) && defined(sun)
  31. #include "platform/switch_x86_unix.h" /* SunStudio on x86 */
  32. #elif defined(__GNUC__) && defined(__s390__) && defined(__linux__)
  33. #include "platform/switch_s390_unix.h" /* Linux/S390 */
  34. #elif defined(__GNUC__) && defined(__s390x__) && defined(__linux__)
  35. #include "platform/switch_s390_unix.h" /* Linux/S390 zSeries (64-bit) */
  36. #elif defined(__GNUC__) && defined(__arm__)
  37. #ifdef __APPLE__
  38. #include <TargetConditionals.h>
  39. #endif
  40. #if TARGET_OS_IPHONE
  41. #include "platform/switch_arm32_ios.h" /* iPhone OS on arm32 */
  42. #else
  43. #include "platform/switch_arm32_gcc.h" /* gcc using arm32 */
  44. #endif
  45. #elif defined(__GNUC__) && defined(__mips__) && defined(__linux__)
  46. #include "platform/switch_mips_unix.h" /* Linux/MIPS */
  47. #elif defined(__GNUC__) && defined(__aarch64__)
  48. #include "platform/switch_aarch64_gcc.h" /* Aarch64 ABI */
  49. #elif defined(__GNUC__) && defined(__mc68000__)
  50. #include "platform/switch_m68k_gcc.h" /* gcc on m68k */
  51. #elif defined(__GNUC__) && defined(__csky__)
  52. #include "platform/switch_csky_gcc.h" /* gcc on csky */
  53. #elif defined(__GNUC__) && defined(__riscv)
  54. #include "platform/switch_riscv_unix.h" /* gcc on RISC-V */
  55. #elif defined(__GNUC__) && defined(__alpha__)
  56. #include "platform/switch_alpha_unix.h" /* gcc on DEC Alpha */
  57. #endif