ya.make 2.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127
  1. PY2_LIBRARY()
  2. VERSION(5.8.0)
  3. LICENSE(BSD-3-Clause)
  4. NO_COMPILER_WARNINGS()
  5. NO_LINT()
  6. NO_CHECK_IMPORTS(
  7. psutil._psaix
  8. psutil._psbsd
  9. psutil._pslinux
  10. psutil._psosx
  11. psutil._pssunos
  12. psutil._psutil_bsd
  13. psutil._psutil_common
  14. psutil._psutil_osx
  15. psutil._psutil_sunos
  16. psutil._psutil_windows
  17. psutil._pswindows
  18. )
  19. NO_UTIL()
  20. CFLAGS(
  21. -DPSUTIL_VERSION=580
  22. )
  23. SRCS(
  24. psutil/_psutil_common.c
  25. )
  26. IF (OS_LINUX)
  27. CFLAGS(
  28. -DPSUTIL_POSIX=1
  29. -DPSUTIL_LINUX=1
  30. )
  31. SRCS(
  32. psutil/_psutil_linux.c
  33. psutil/_psutil_posix.c
  34. )
  35. PY_REGISTER(
  36. psutil._psutil_linux
  37. psutil._psutil_posix
  38. )
  39. ENDIF()
  40. IF (OS_DARWIN)
  41. CFLAGS(
  42. -DPSUTIL_POSIX=1
  43. -DPSUTIL_OSX=1
  44. )
  45. LDFLAGS(
  46. -framework CoreFoundation
  47. -framework IOKit
  48. )
  49. SRCS(
  50. psutil/_psutil_osx.c
  51. psutil/_psutil_posix.c
  52. psutil/arch/osx/process_info.c
  53. )
  54. PY_REGISTER(
  55. psutil._psutil_osx
  56. psutil._psutil_posix
  57. )
  58. ENDIF()
  59. IF (OS_WINDOWS)
  60. CFLAGS(
  61. -DPSUTIL_WINDOWS=1
  62. -DPSUTIL_SIZEOF_PID_T=4
  63. )
  64. LDFLAGS(
  65. Shell32.lib
  66. PowrProf.lib
  67. Wtsapi32.lib
  68. Pdh.lib
  69. )
  70. SRCS(
  71. psutil/_psutil_windows.c
  72. psutil/arch/windows/cpu.c
  73. psutil/arch/windows/disk.c
  74. psutil/arch/windows/net.c
  75. psutil/arch/windows/process_handles.c
  76. psutil/arch/windows/process_info.c
  77. psutil/arch/windows/process_utils.c
  78. psutil/arch/windows/security.c
  79. psutil/arch/windows/services.c
  80. psutil/arch/windows/socks.c
  81. psutil/arch/windows/wmi.c
  82. )
  83. PY_REGISTER(
  84. psutil._psutil_windows
  85. )
  86. ENDIF()
  87. PY_SRCS(
  88. TOP_LEVEL
  89. psutil/__init__.py
  90. psutil/_common.py
  91. psutil/_compat.py
  92. psutil/_psaix.py
  93. psutil/_psbsd.py
  94. psutil/_pslinux.py
  95. psutil/_psosx.py
  96. psutil/_psposix.py
  97. psutil/_pssunos.py
  98. psutil/_pswindows.py
  99. )
  100. RESOURCE_FILES(
  101. PREFIX contrib/python/psutil/py2/
  102. .dist-info/METADATA
  103. .dist-info/top_level.txt
  104. )
  105. END()