1
+ #---------------------------------------------------------------------------#
2
+ # Copyright (c) 2018-2020 Mikhail Komarov <[email protected] >
3
+ #
4
+ # Distributed under the Boost Software License, Version 1.0
5
+ # See accompanying file LICENSE_1_0.txt or copy at
6
+ # http://www.boost.org/LICENSE_1_0.txt
7
+ #---------------------------------------------------------------------------#
8
+
1
9
cmake_minimum_required (VERSION 2.8.12)
2
10
3
11
cmake_policy (SET CMP0028 NEW)
@@ -28,31 +36,14 @@ macro(cm_find_package NAME)
28
36
endforeach ()
29
37
endmacro ()
30
38
31
- cm_project(transpiler WORKSPACE_NAME ${CMAKE_WORKSPACE_NAME} LANGUAGES C CXX)
39
+ cm_project(transpiler WORKSPACE_NAME ${CMAKE_WORKSPACE_NAME} LANGUAGES ASM C CXX)
32
40
33
41
cm_find_package(CM)
34
42
include (CMDeploy)
35
- include (FindPkgConfig)
36
43
37
- option (BUILD_WITH_CCACHE "Build with ccache usage" TRUE )
38
44
option (BUILD_TESTS "Build unit tests" FALSE )
39
- option (BUILD_EXAMPLES "Build examples" FALSE )
40
-
41
- if (UNIX AND BUILD_WITH_CCACHE)
42
- find_program (CCACHE_FOUND ccache)
43
- if (CCACHE_FOUND)
44
- set_property (GLOBAL PROPERTY RULE_LAUNCH_COMPILE ccache)
45
- set_property (GLOBAL PROPERTY RULE_LAUNCH_LINK ccache)
46
- endif (CCACHE_FOUND)
47
- endif ()
48
-
49
- if (UNIX AND BUILD_WITH_PROCPS)
50
- find_package (Procps)
51
- endif ()
52
45
53
- list (APPEND ${CURRENT_PROJECT_NAME} _PUBLIC_HEADERS
54
- include /nil/crypto3/zk/blueprint/transpiler/profiling_plonk_circuit.hpp
55
- include /nil/crypto3/zk/blueprint/transpiler/table_profiling.hpp)
46
+ list (APPEND ${CURRENT_PROJECT_NAME} _PUBLIC_HEADERS)
56
47
57
48
list (APPEND ${CURRENT_PROJECT_NAME} _UNGROUPED_SOURCES)
58
49
@@ -67,31 +58,24 @@ add_library(${CMAKE_WORKSPACE_NAME}_${CURRENT_PROJECT_NAME} INTERFACE)
67
58
set_target_properties (${CMAKE_WORKSPACE_NAME} _${CURRENT_PROJECT_NAME} PROPERTIES
68
59
EXPORT_NAME ${CURRENT_PROJECT_NAME} )
69
60
61
+
70
62
target_include_directories (${CMAKE_WORKSPACE_NAME} _${CURRENT_PROJECT_NAME} INTERFACE
71
63
"$<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR} /include>"
72
64
"$<BUILD_INTERFACE:${CMAKE_BINARY_DIR} /include>"
73
65
74
66
${Boost_INCLUDE_DIRS} )
75
67
76
68
target_link_libraries (${CMAKE_WORKSPACE_NAME} _${CURRENT_PROJECT_NAME} INTERFACE
77
- crypto3::algebra
78
- crypto3::block
79
- crypto3::blueprint
80
- crypto3::codec
81
- crypto3::math
82
- crypto3::multiprecision
83
- crypto3::pkpad
84
- crypto3::pubkey
85
- crypto3::random
86
- crypto3::zk
87
-
88
- marshalling::core
89
- marshalling::crypto3_algebra
90
- marshalling::crypto3_multiprecision
91
- marshalling::crypto3_zk
69
+ ${CMAKE_WORKSPACE_NAME} ::algebra
70
+ ${CMAKE_WORKSPACE_NAME} ::multiprecision
71
+ ${CMAKE_WORKSPACE_NAME} ::zk
92
72
93
73
${Boost_LIBRARIES} )
94
74
95
75
cm_deploy(TARGETS ${CMAKE_WORKSPACE_NAME} _${CURRENT_PROJECT_NAME}
96
76
INCLUDE include
97
- NAMESPACE ${CMAKE_WORKSPACE_NAME} ::)
77
+ NAMESPACE ${CMAKE_WORKSPACE_NAME} ::)
78
+
79
+ if (BUILD_TESTS)
80
+ add_subdirectory (test )
81
+ endif ()
0 commit comments