ya.make 4.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173
  1. LIBRARY()
  2. PROVIDES(
  3. yql_pg_runtime
  4. )
  5. CXXFLAGS(-DMKQL_DISABLE_CODEGEN)
  6. YQL_LAST_ABI_VERSION()
  7. ADDINCL(
  8. contrib/libs/lz4
  9. yql/essentials/parser/pg_wrapper/postgresql/src/backend/bootstrap
  10. yql/essentials/parser/pg_wrapper/postgresql/src/backend/parser
  11. yql/essentials/parser/pg_wrapper/postgresql/src/backend/replication
  12. yql/essentials/parser/pg_wrapper/postgresql/src/backend/replication/logical
  13. yql/essentials/parser/pg_wrapper/postgresql/src/backend/utils/adt
  14. yql/essentials/parser/pg_wrapper/postgresql/src/backend/utils/misc
  15. yql/essentials/parser/pg_wrapper/postgresql/src/backend/utils/sort
  16. yql/essentials/parser/pg_wrapper/postgresql/src/common
  17. yql/essentials/parser/pg_wrapper/postgresql/src/include
  18. yql/essentials/parser/pg_wrapper/postgresql/src/port
  19. )
  20. IF (NOT BUILD_POSTGRES_ONLY)
  21. SRCS(
  22. arena_ctx.cpp
  23. arrow.cpp
  24. arrow_impl.cpp
  25. conversion.cpp
  26. parser.cpp
  27. thread_inits.c
  28. comp_factory.cpp
  29. type_cache.cpp
  30. pg_aggs.cpp
  31. read_table.cpp
  32. recovery.cpp
  33. superuser.cpp
  34. config.cpp
  35. cost_mocks.cpp
  36. syscache.cpp
  37. pg_utils_wrappers.cpp
  38. utils.cpp
  39. ctors.cpp
  40. )
  41. ENDIF()
  42. IF (ARCH_X86_64)
  43. CFLAGS(
  44. -DHAVE__GET_CPUID=1
  45. -DUSE_SSE42_CRC32C_WITH_RUNTIME_CHECK=1
  46. )
  47. SRCS(
  48. postgresql/src/port/pg_crc32c_sse42.c
  49. postgresql/src/port/pg_crc32c_sse42_choose.c
  50. )
  51. ENDIF()
  52. INCLUDE(pg_sources.inc)
  53. IF (NOT BUILD_POSTGRES_ONLY)
  54. INCLUDE(pg_kernel_sources.inc)
  55. ENDIF()
  56. IF (NOT OS_WINDOWS AND NOT SANITIZER_TYPE AND NOT BUILD_TYPE == "DEBUG")
  57. IF (NOT BUILD_POSTGRES_ONLY)
  58. USE_LLVM_BC14()
  59. INCLUDE(pg_bc.all.inc)
  60. ENDIF()
  61. ELSE()
  62. CFLAGS(-DUSE_SLOW_PG_KERNELS)
  63. ENDIF()
  64. IF (BUILD_TYPE == "DEBUG")
  65. CFLAGS(-DDISABLE_COMPLEX_MACRO)
  66. ENDIF()
  67. PEERDIR(
  68. library/cpp/resource
  69. library/cpp/yson
  70. yql/essentials/core
  71. yql/essentials/minikql/arrow
  72. yql/essentials/minikql/computation
  73. yql/essentials/parser/pg_catalog
  74. yql/essentials/parser/pg_wrapper/interface
  75. yql/essentials/providers/common/codec
  76. yql/essentials/public/issue
  77. yql/essentials/public/udf
  78. yql/essentials/utils
  79. yql/essentials/public/decimal
  80. yql/essentials/public/result_format
  81. yql/essentials/types/binary_json
  82. yql/essentials/types/dynumber
  83. yql/essentials/types/uuid
  84. contrib/libs/icu
  85. contrib/libs/libc_compat
  86. contrib/libs/libxml
  87. contrib/libs/lz4
  88. contrib/libs/openssl
  89. )
  90. INCLUDE(cflags.inc)
  91. IF (OS_LINUX)
  92. SRCS(
  93. postgresql/src/port/strlcat.c
  94. postgresql/src/port/strlcpy.c
  95. )
  96. ENDIF()
  97. IF (OS_LINUX OR OS_DARWIN)
  98. SRCS(
  99. postgresql/src/backend/port/posix_sema.c
  100. postgresql/src/backend/port/sysv_shmem.c
  101. )
  102. ELSEIF (OS_WINDOWS)
  103. ADDINCL(
  104. yql/essentials/parser/pg_wrapper/postgresql/src/include
  105. yql/essentials/parser/pg_wrapper/postgresql/src/include/port/win32
  106. yql/essentials/parser/pg_wrapper/postgresql/src/include/port/win32_msvc
  107. )
  108. SRCS(
  109. postgresql/src/backend/port/win32/crashdump.c
  110. postgresql/src/backend/port/win32/signal.c
  111. postgresql/src/backend/port/win32/socket.c
  112. postgresql/src/backend/port/win32/timer.c
  113. postgresql/src/backend/port/win32_sema.c
  114. postgresql/src/backend/port/win32_shmem.c
  115. postgresql/src/port/dirmod.c
  116. postgresql/src/port/getopt.c
  117. postgresql/src/port/inet_aton.c
  118. postgresql/src/port/kill.c
  119. postgresql/src/port/open.c
  120. postgresql/src/port/pwritev.c
  121. postgresql/src/port/system.c
  122. postgresql/src/port/win32common.c
  123. postgresql/src/port/win32dlopen.c
  124. postgresql/src/port/win32env.c
  125. postgresql/src/port/win32error.c
  126. postgresql/src/port/win32fseek.c
  127. postgresql/src/port/win32gai_strerror.c
  128. postgresql/src/port/win32gettimeofday.c
  129. postgresql/src/port/win32getrusage.c
  130. postgresql/src/port/win32ntdll.c
  131. postgresql/src/port/win32pread.c
  132. postgresql/src/port/win32pwrite.c
  133. postgresql/src/port/win32security.c
  134. postgresql/src/port/win32setlocale.c
  135. postgresql/src/port/win32stat.c
  136. )
  137. ENDIF()
  138. # Service files must be listed as dependencies to be included in export
  139. FILES(
  140. copy_src.py
  141. copy_src.sh
  142. generate_kernels.py
  143. source.patch
  144. vars.txt
  145. verify.sh
  146. )
  147. END()
  148. RECURSE(
  149. interface
  150. )
  151. RECURSE_FOR_TESTS(
  152. ut
  153. test
  154. )