aboutsummaryrefslogtreecommitdiffstats
path: root/contrib/libs/cxxsupp/openmp/ya.make
blob: 5ab68e3978b7464fd2c395bda8c0cc13921e0ce7 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
# Generated by devtools/yamaker from nixpkgs 22.11.

LIBRARY()

LICENSE(
    Apache-2.0 AND
    Apache-2.0 WITH LLVM-exception AND
    Intel-LLVM-SGA AND
    MIT AND
    NCSA
)

LICENSE_TEXTS(.yandex_meta/licenses.list.txt)

VERSION(15.0.7)

ORIGINAL_SOURCE(https://github.com/llvm/llvm-project/archive/llvmorg-15.0.7.tar.gz)

ADDINCL(
    GLOBAL contrib/libs/cxxsupp/openmp
)

NO_COMPILER_WARNINGS()

NO_UTIL()

NO_LTO()

CFLAGS(
    -fno-exceptions
    -DKMP_USE_MONITOR=1
)

IF (SANITIZER_TYPE == thread)
    NO_SANITIZE()
    CFLAGS(
        -fPIC
    )
ENDIF()

IF (SANITIZER_TYPE == memory)
    NO_SANITIZE()
    CFLAGS(
        -fPIC
    )
ENDIF()

# The KMP_DEBUG define enables OpenMP debugging support, including tracing (controlled by environment variables)
# and debug asserts. The upstream version unconditionally enables KMP_DEBUG for Debug/RelWithDebInfo builds.
# Instead, we make this opt-in via a `ymake` variable to avoid accidentally releasing a relwithdebinfo binary
# with KMP_DEBUG enabled. Note that the `ymake` variable is called OPENMP_DEBUG for clarity, since no one
# really knows what KMP is.

IF (OPENMP_DEBUG)
    CFLAGS(
        -DKMP_DEBUG=1
    )
ENDIF()

SRCS(
    kmp_affinity.cpp
    kmp_alloc.cpp
    kmp_atomic.cpp
    kmp_barrier.cpp
    kmp_cancel.cpp
    kmp_csupport.cpp
    kmp_debug.cpp
    kmp_dispatch.cpp
    kmp_environment.cpp
    kmp_error.cpp
    kmp_ftn_cdecl.cpp
    kmp_ftn_extra.cpp
    kmp_global.cpp
    kmp_gsupport.cpp
    kmp_i18n.cpp
    kmp_io.cpp
    kmp_itt.cpp
    kmp_lock.cpp
    kmp_runtime.cpp
    kmp_sched.cpp
    kmp_settings.cpp
    kmp_str.cpp
    kmp_taskdeps.cpp
    kmp_tasking.cpp
    kmp_threadprivate.cpp
    kmp_utility.cpp
    kmp_version.cpp
    kmp_wait_release.cpp
    ompt-general.cpp
    z_Linux_asm.S
    z_Linux_util.cpp
)

END()