Run DCE after a LoopFlatten test to reduce spurious output [nfc]
[llvm-project.git] / libc / src / time / CMakeLists.txt
blob210f3b23432b49fd561320343cdb59e2d4eac567
1 if(EXISTS ${CMAKE_CURRENT_SOURCE_DIR}/${LIBC_TARGET_OS})
2   add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/${LIBC_TARGET_OS})
3 endif()
5 add_object_library(
6   time_utils
7   SRCS
8     time_utils.cpp
9   HDRS
10     time_utils.h
11   DEPENDS
12     libc.include.time
13     libc.src.errno.errno
16 add_entrypoint_object(
17   asctime
18   SRCS
19     asctime.cpp
20   HDRS
21     asctime.h
22   DEPENDS
23     .time_utils
24     libc.include.time
27 add_entrypoint_object(
28   asctime_r
29   SRCS
30     asctime_r.cpp
31   HDRS
32     asctime_r.h
33   DEPENDS
34     .time_utils
35     libc.include.time
38 add_entrypoint_object(
39   difftime
40   SRCS
41     difftime.cpp
42   HDRS
43     difftime.h
44   DEPENDS
45     libc.include.time
48 add_entrypoint_object(
49   gmtime
50   SRCS
51     gmtime.cpp
52   HDRS
53     gmtime.h
54   DEPENDS
55     .time_utils
56     libc.include.time
59 add_entrypoint_object(
60   gmtime_r
61   SRCS
62     gmtime_r.cpp
63   HDRS
64     gmtime_r.h
65   DEPENDS
66     .time_utils
67     libc.include.time
70 add_entrypoint_object(
71   mktime
72   SRCS
73     mktime.cpp
74   HDRS
75     mktime.h
76   DEPENDS
77     .time_utils
78     libc.include.time
79     libc.src.errno.errno
82 add_entrypoint_object(
83   time
84   ALIAS
85   DEPENDS
86     .${LIBC_TARGET_OS}.time
89 add_entrypoint_object(
90   clock
91   ALIAS
92   DEPENDS
93     .${LIBC_TARGET_OS}.clock
96 add_entrypoint_object(
97   nanosleep
98   ALIAS
99   DEPENDS
100     .${LIBC_TARGET_OS}.nanosleep
103 add_entrypoint_object(
104   clock_gettime
105   ALIAS
106   DEPENDS
107     .${LIBC_TARGET_OS}.clock_gettime
110 add_entrypoint_object(
111   gettimeofday
112   ALIAS
113   DEPENDS
114     .${LIBC_TARGET_OS}.gettimeofday