blob: d03409fc45b79b963e63ae98c748e77ea72ac5b8 (
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
|
add_custom_target(profile)
set(PROFILE_SOURCES
GCDAProfiling.c
InstrProfiling.c
InstrProfilingBuffer.c
InstrProfilingFile.c
InstrProfilingPlatformDarwin.c
InstrProfilingPlatformOther.c
InstrProfilingRuntime.cc
InstrProfilingUtil.c)
if(APPLE)
add_compiler_rt_osx_static_runtime(clang_rt.profile_osx
ARCHS ${PROFILE_SUPPORTED_ARCH}
SOURCES ${PROFILE_SOURCES})
add_dependencies(profile clang_rt.profile_osx)
else()
foreach(arch ${PROFILE_SUPPORTED_ARCH})
add_compiler_rt_runtime(clang_rt.profile-${arch} ${arch} STATIC
CFLAGS -fPIC
SOURCES ${PROFILE_SOURCES})
add_dependencies(profile clang_rt.profile-${arch})
endforeach()
endif()
add_dependencies(compiler-rt profile)
|