File: CMakeLists.txt

package info (click to toggle)
metis 5.1.0.dfsg-5
  • links: PTS, VCS
  • area: main
  • in suites: bullseye, buster, sid, stretch
  • size: 13,400 kB
  • ctags: 2,565
  • sloc: ansic: 29,849; makefile: 133; sh: 123
file content (35 lines) | stat: -rw-r--r-- 1,249 bytes parent folder | download | duplicates (2)
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
cmake_minimum_required(VERSION 2.8)
project(METIS)

set(GKLIB_PATH "${CMAKE_SOURCE_DIR}/GKlib" CACHE PATH "path to GKlib")
set(SHARED FALSE CACHE BOOL "build a shared library")
INCLUDE(GNUInstallDirs)

if(MSVC)
  set(METIS_INSTALL FALSE)
else()
  set(METIS_INSTALL TRUE)
endif()

# Configure libmetis library.
set(METIS_LIBRARY_TYPE SHARED)

set(METIS_MAJOR_VERSION 5)
set(METIS_MINOR_VERSION 1)
set(METIS_PATCH_VERSION 0)

include(${GKLIB_PATH}/GKlibSystem.cmake)
# Add include directories.
include_directories(${GKLIB_PATH})
include_directories(include)
# Recursively look for CMakeLists.txt in subdirs.
add_subdirectory("include")
add_subdirectory("libmetis")
add_subdirectory("programs")

ENABLE_TESTING()
ADD_TEST(gpmetis "${CMAKE_BINARY_DIR}/programs/gpmetis" "${CMAKE_SOURCE_DIR}/graphs/4elt.graph" "20")
ADD_TEST(graphchk "${CMAKE_BINARY_DIR}/programs/graphchk" "${CMAKE_SOURCE_DIR}/graphs/4elt.graph")
ADD_TEST(m2gmetis "${CMAKE_BINARY_DIR}/programs/m2gmetis" "${CMAKE_SOURCE_DIR}/graphs/metis.mesh" "${CMAKE_SOURCE_DIR}/graphs/4elt.graph")
ADD_TEST(mpmetis "${CMAKE_BINARY_DIR}/programs/mpmetis" "${CMAKE_SOURCE_DIR}/graphs/metis.mesh" "10")
ADD_TEST(ndmetis "${CMAKE_BINARY_DIR}/programs/ndmetis" "${CMAKE_SOURCE_DIR}/graphs/4elt.graph")