File: CMakeLists.txt

package info (click to toggle)
spades 3.13.1+dfsg-2
  • links: PTS, VCS
  • area: main
  • in suites: bullseye, sid
  • size: 22,172 kB
  • sloc: cpp: 136,213; ansic: 48,218; python: 16,809; perl: 4,252; sh: 2,115; java: 890; makefile: 507; pascal: 348; xml: 303
file content (38 lines) | stat: -rw-r--r-- 1,088 bytes parent folder | download | duplicates (5)
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
project(llvm-support)

include_directories(${CMAKE_CURRENT_SOURCE_DIR})
include_directories(${EXT_DIR}/include)

include(CheckIncludeFiles)
include(CheckIncludeFileCXX)
include(CheckSymbolExists)

check_include_files(execinfo.h  HAVE_EXECINFO_H)
check_include_files(signal.h    HAVE_SIGNAL_H)
check_include_files(sys/stat.h  HAVE_SYS_STAT_H)
check_include_files(cxxabi.h    HAVE_CXXABI_H)
check_include_files(dlfcn.h     HAVE_DLFCN_H)
check_include_files(mach/mach.h HAVE_MACH_MACH_H)
check_include_files(link.h      HAVE_LINK_H)

check_symbol_exists(backtrace "execinfo.h" HAVE_BACKTRACE)

find_library(DL_LIB NAMES "dl")

add_definitions(-D__STDC_CONSTANT_MACROS)
add_definitions(-D__STDC_LIMIT_MACROS)

# FIXME: Signal handler return type, currently hardcoded to 'void'
set(RETSIGTYPE void)

configure_file(${EXT_DIR}/include/llvm/Config.h.in
               ${SPADES_BUILT_INCLUDE_DIR}/llvm/Config.h)

file(GLOB sources "[a-zA-Z]*.cpp" "[a-zA-Z]*.c")
list(SORT sources)

add_library(llvm-support STATIC
  ${sources})
if (DL_LIB)
  target_link_libraries(llvm-support ${DL_LIB})
endif()