aboutsummaryrefslogtreecommitdiff
path: root/tools/rasm/lzsa-master/src/libdivsufsort/lib/CMakeLists.txt
blob: abc90e61da59a8850e95735cfd38859a8a42cb86 (plain)
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
include_directories("${CMAKE_CURRENT_SOURCE_DIR}/../include"
                    "${CMAKE_CURRENT_BINARY_DIR}/../include")

set(divsufsort_SRCS divsufsort.c sssort.c trsort.c utils.c)

## libdivsufsort ##
add_library(divsufsort ${divsufsort_SRCS})
install(TARGETS divsufsort
  RUNTIME DESTINATION ${CMAKE_INSTALL_RUNTIMEDIR}
  LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}
  ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR})
set_target_properties(divsufsort PROPERTIES
  VERSION   "${LIBRARY_VERSION}"
  SOVERSION "${LIBRARY_SOVERSION}"
  DEFINE_SYMBOL DIVSUFSORT_BUILD_DLL
  RUNTIME_OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/../examples")

## libdivsufsort64 ##
if(BUILD_DIVSUFSORT64)
  add_library(divsufsort64 ${divsufsort_SRCS})
  install(TARGETS divsufsort64
    RUNTIME DESTINATION ${CMAKE_INSTALL_RUNTIMEDIR}
    LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}
    ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR})
  set_target_properties(divsufsort64 PROPERTIES
    VERSION   "${LIBRARY_VERSION}"
    SOVERSION "${LIBRARY_SOVERSION}"
    DEFINE_SYMBOL DIVSUFSORT_BUILD_DLL
    COMPILE_FLAGS "-DBUILD_DIVSUFSORT64"
    RUNTIME_OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/../examples")
endif(BUILD_DIVSUFSORT64)