[clang] Avoid linking libdl unless needed
[llvm-project.git] / libc / src / math / CMakeLists.txt
blob41a20b31996f638102c4e2c3576fcf655c906b14
1 add_object_library(
2   math_utils
3   SRCS
4     math_utils.cpp
5   HDRS
6     math_utils.h
7   DEPENDS
8     libc.include.errno
9     libc.include.math
10     libc.src.errno.__errno_location
13 add_object_library(
14   sincosf_utils
15   HDRS
16     sincosf_utils.h
17   SRCS
18     sincosf_data.cpp
19   DEPENDS
20     .math_utils
23 add_entrypoint_object(
24   round
25   REDIRECTED
26   SRCS
27     round.cpp
28   HDRS
29     round.h
32 add_redirector_object(
33   round_redirector
34   SRC
35     round_redirector.cpp
38 add_entrypoint_object(
39   cosf
40   SRCS
41     cosf.cpp
42   HDRS
43     cosf.h
44   DEPENDS
45     .sincosf_utils
46     libc.include.math
47     libc.src.errno.__errno_location
50 add_entrypoint_object(
51   sinf
52   SRCS
53     sinf.cpp
54   HDRS
55     sinf.h
56   DEPENDS
57     .sincosf_utils
58     libc.include.math
59     libc.src.errno.__errno_location
62 add_entrypoint_object(
63   sincosf
64   SRCS
65     sincosf.cpp
66   HDRS
67     sincosf.h
68   DEPENDS
69     .sincosf_utils
70     libc.include.math
71     libc.src.errno.__errno_location
74 add_entrypoint_object(
75   fabs
76   SRCS
77     fabs.cpp
78   HDRS
79     fabs.h
80   DEPENDS
81     libc.utils.FPUtil.fputil
84 add_entrypoint_object(
85   fabsf
86   SRCS
87     fabsf.cpp
88   HDRS
89     fabsf.h
90   DEPENDS
91     libc.utils.FPUtil.fputil
94 add_object_library(
95   exp_utils
96   HDRS
97     exp_utils.h
98   SRCS
99     exp_utils.cpp
100   DEPENDS
101     .math_utils
104 add_entrypoint_object(
105   expf
106   SRCS
107     expf.cpp
108   HDRS
109     expf.h
110   DEPENDS
111     .exp_utils
112     .math_utils
113     libc.include.math
116 add_entrypoint_object(
117   exp2f
118   SRCS
119     exp2f.cpp
120   HDRS
121     exp2f.h
122   DEPENDS
123     .exp_utils
124     .math_utils
125     libc.include.math