Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
A
Actor Framework
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Metrics
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
cpp-libs
Actor Framework
Commits
70be5cd5
Commit
70be5cd5
authored
Apr 10, 2015
by
Dominik Charousset
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'rvlm-master' into develop
Close #267
parents
81301514
672f1c81
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
29 additions
and
21 deletions
+29
-21
CMakeLists.txt
CMakeLists.txt
+29
-21
No files found.
CMakeLists.txt
View file @
70be5cd5
...
@@ -51,7 +51,7 @@ set(CAF_VERSION
...
@@ -51,7 +51,7 @@ set(CAF_VERSION
################################################################################
################################################################################
# prohibit in-source builds
# prohibit in-source builds
if
(
"
${
CMAKE_
SOURCE_DIR
}
"
STREQUAL
"
${
CMAKE
_BINARY_DIR
}
"
)
if
(
"
${
CMAKE_
CURRENT_SOURCE_DIR
}
"
STREQUAL
"
${
CMAKE_CURRENT
_BINARY_DIR
}
"
)
message
(
FATAL_ERROR
"In-source builds are not allowed. Please use "
message
(
FATAL_ERROR
"In-source builds are not allowed. Please use "
"./configure to choose a build directory and "
"./configure to choose a build directory and "
"initialize the build configuration."
)
"initialize the build configuration."
)
...
@@ -60,14 +60,14 @@ endif()
...
@@ -60,14 +60,14 @@ endif()
set
(
CMAKE_MODULE_PATH
"
${
CMAKE_CURRENT_SOURCE_DIR
}
/cmake"
)
set
(
CMAKE_MODULE_PATH
"
${
CMAKE_CURRENT_SOURCE_DIR
}
/cmake"
)
# set binary output path if not defined by user
# set binary output path if not defined by user
if
(
"
${
EXECUTABLE_OUTPUT_PATH
}
"
STREQUAL
""
)
if
(
"
${
EXECUTABLE_OUTPUT_PATH
}
"
STREQUAL
""
)
set
(
EXECUTABLE_OUTPUT_PATH
"
${
CMAKE_BINARY_DIR
}
/bin"
)
set
(
EXECUTABLE_OUTPUT_PATH
"
${
CMAKE_
CURRENT_
BINARY_DIR
}
/bin"
)
endif
()
endif
()
# set library output path if not defined by user, but always set
# set library output path if not defined by user, but always set
# library output path to binary output path for Xcode projects
# library output path to binary output path for Xcode projects
if
(
"
${
CMAKE_GENERATOR
}
"
STREQUAL
"Xcode"
)
if
(
"
${
CMAKE_GENERATOR
}
"
STREQUAL
"Xcode"
)
set
(
LIBRARY_OUTPUT_PATH
"
${
EXECUTABLE_OUTPUT_PATH
}
"
)
set
(
LIBRARY_OUTPUT_PATH
"
${
EXECUTABLE_OUTPUT_PATH
}
"
)
elseif
(
"
${
LIBRARY_OUTPUT_PATH
}
"
STREQUAL
""
)
elseif
(
"
${
LIBRARY_OUTPUT_PATH
}
"
STREQUAL
""
)
set
(
LIBRARY_OUTPUT_PATH
"
${
CMAKE_BINARY_DIR
}
/lib"
)
set
(
LIBRARY_OUTPUT_PATH
"
${
CMAKE_
CURRENT_
BINARY_DIR
}
/lib"
)
endif
()
endif
()
...
@@ -79,7 +79,7 @@ endif()
...
@@ -79,7 +79,7 @@ endif()
if
(
NOT WIN32 AND NOT NO_COMPILER_CHECK
)
if
(
NOT WIN32 AND NOT NO_COMPILER_CHECK
)
try_run
(
ProgramResult
try_run
(
ProgramResult
CompilationSucceeded
CompilationSucceeded
"
${
CMAKE_BINARY_DIR
}
"
"
${
CMAKE_
CURRENT_
BINARY_DIR
}
"
"
${
CMAKE_CURRENT_SOURCE_DIR
}
/cmake/get_compiler_version.cpp"
"
${
CMAKE_CURRENT_SOURCE_DIR
}
/cmake/get_compiler_version.cpp"
RUN_OUTPUT_VARIABLE CompilerVersion
)
RUN_OUTPUT_VARIABLE CompilerVersion
)
if
(
NOT CompilationSucceeded OR NOT ProgramResult EQUAL 0
)
if
(
NOT CompilationSucceeded OR NOT ProgramResult EQUAL 0
)
...
@@ -147,7 +147,7 @@ if(NOT NO_AUTO_LIBCPP AND "${CMAKE_CXX_COMPILER_ID}" MATCHES "Clang")
...
@@ -147,7 +147,7 @@ if(NOT NO_AUTO_LIBCPP AND "${CMAKE_CXX_COMPILER_ID}" MATCHES "Clang")
set
(
CMAKE_CXX_FLAGS
"-std=c++11 -stdlib=libc++"
)
set
(
CMAKE_CXX_FLAGS
"-std=c++11 -stdlib=libc++"
)
try_run
(
ProgramResult
try_run
(
ProgramResult
CompilationSucceeded
CompilationSucceeded
"
${
CMAKE_BINARY_DIR
}
"
"
${
CMAKE_
CURRENT_
BINARY_DIR
}
"
"
${
CMAKE_CURRENT_SOURCE_DIR
}
/cmake/get_compiler_version.cpp"
"
${
CMAKE_CURRENT_SOURCE_DIR
}
/cmake/get_compiler_version.cpp"
RUN_OUTPUT_VARIABLE CompilerVersion
)
RUN_OUTPUT_VARIABLE CompilerVersion
)
if
(
NOT CompilationSucceeded OR NOT ProgramResult EQUAL 0
)
if
(
NOT CompilationSucceeded OR NOT ProgramResult EQUAL 0
)
...
@@ -167,7 +167,7 @@ if(ENABLE_ADDRESS_SANITIZER)
...
@@ -167,7 +167,7 @@ if(ENABLE_ADDRESS_SANITIZER)
set
(
CMAKE_CXX_FLAGS
"-fsanitize=address -fno-omit-frame-pointer"
)
set
(
CMAKE_CXX_FLAGS
"-fsanitize=address -fno-omit-frame-pointer"
)
try_run
(
ProgramResult
try_run
(
ProgramResult
CompilationSucceeded
CompilationSucceeded
"
${
CMAKE_BINARY_DIR
}
"
"
${
CMAKE_
CURRENT_
BINARY_DIR
}
"
"
${
CMAKE_CURRENT_SOURCE_DIR
}
/cmake/get_compiler_version.cpp"
)
"
${
CMAKE_CURRENT_SOURCE_DIR
}
/cmake/get_compiler_version.cpp"
)
if
(
NOT CompilationSucceeded
)
if
(
NOT CompilationSucceeded
)
message
(
WARNING
"Address Sanitizer is not available on selected compiler"
)
message
(
WARNING
"Address Sanitizer is not available on selected compiler"
)
...
@@ -256,7 +256,7 @@ install(DIRECTORY libcaf_core/cppa/
...
@@ -256,7 +256,7 @@ install(DIRECTORY libcaf_core/cppa/
install
(
DIRECTORY libcaf_io/caf/ DESTINATION include/caf
install
(
DIRECTORY libcaf_io/caf/ DESTINATION include/caf
FILES_MATCHING PATTERN
"*.hpp"
)
FILES_MATCHING PATTERN
"*.hpp"
)
# install includes from opencl
# install includes from opencl
if
(
EXISTS
"
${
CMAKE_SOURCE_DIR
}
/libcaf_opencl/CMakeLists.txt"
)
if
(
EXISTS
"
${
CMAKE_
CURRENT_
SOURCE_DIR
}
/libcaf_opencl/CMakeLists.txt"
)
install
(
DIRECTORY libcaf_opencl/caf/ DESTINATION include/caf
install
(
DIRECTORY libcaf_opencl/caf/ DESTINATION include/caf
FILES_MATCHING PATTERN
"*.hpp"
)
FILES_MATCHING PATTERN
"*.hpp"
)
endif
()
endif
()
...
@@ -277,12 +277,12 @@ add_custom_target(uninstall
...
@@ -277,12 +277,12 @@ add_custom_target(uninstall
# path to caf core & io headers
# path to caf core & io headers
set
(
LIBCAF_INCLUDE_DIRS
set
(
LIBCAF_INCLUDE_DIRS
"
${
CMAKE_SOURCE_DIR
}
/libcaf_core"
"
${
CMAKE_
CURRENT_
SOURCE_DIR
}
/libcaf_core"
"
${
CMAKE_SOURCE_DIR
}
/libcaf_io"
)
"
${
CMAKE_
CURRENT_
SOURCE_DIR
}
/libcaf_io"
)
# path to caf opencl headers
# path to caf opencl headers
if
(
EXISTS
"
${
CMAKE_SOURCE_DIR
}
/libcaf_opencl/CMakeLists.txt"
)
if
(
EXISTS
"
${
CMAKE_
CURRENT_
SOURCE_DIR
}
/libcaf_opencl/CMakeLists.txt"
)
set
(
LIBCAF_INCLUDE_DIRS
set
(
LIBCAF_INCLUDE_DIRS
"
${
CMAKE_SOURCE_DIR
}
/libcaf_opencl/"
"
${
LIBCAF_INCLUDE_DIRS
}
"
)
"
${
CMAKE_
CURRENT_
SOURCE_DIR
}
/libcaf_opencl/"
"
${
LIBCAF_INCLUDE_DIRS
}
"
)
endif
()
endif
()
# all projects need the headers of the core components
# all projects need the headers of the core components
include_directories
(
"
${
LIBCAF_INCLUDE_DIRS
}
"
)
include_directories
(
"
${
LIBCAF_INCLUDE_DIRS
}
"
)
...
@@ -310,7 +310,8 @@ else()
...
@@ -310,7 +310,8 @@ else()
set
(
LIBCAF_IO_LIBRARY libcaf_io_static
)
set
(
LIBCAF_IO_LIBRARY libcaf_io_static
)
endif
()
endif
()
# set opencl lib for sub directories if not told otherwise
# set opencl lib for sub directories if not told otherwise
if
(
NOT CAF_NO_OPENCL AND EXISTS
"
${
CMAKE_SOURCE_DIR
}
/libcaf_opencl/CMakeLists.txt"
)
if
(
NOT CAF_NO_OPENCL
AND EXISTS
"
${
CMAKE_CURRENT_SOURCE_DIR
}
/libcaf_opencl/CMakeLists.txt"
)
message
(
STATUS
"Enter subdirectory libcaf_opencl"
)
message
(
STATUS
"Enter subdirectory libcaf_opencl"
)
find_package
(
OPENCL REQUIRED
)
find_package
(
OPENCL REQUIRED
)
add_subdirectory
(
libcaf_opencl
)
add_subdirectory
(
libcaf_opencl
)
...
@@ -332,7 +333,8 @@ if(NOT CAF_NO_UNIT_TESTS)
...
@@ -332,7 +333,8 @@ if(NOT CAF_NO_UNIT_TESTS)
message
(
STATUS
"Enter subdirectory unit_testing"
)
message
(
STATUS
"Enter subdirectory unit_testing"
)
add_subdirectory
(
unit_testing
)
add_subdirectory
(
unit_testing
)
add_dependencies
(
all_unit_tests libcaf_core libcaf_io
)
add_dependencies
(
all_unit_tests libcaf_core libcaf_io
)
if
(
NOT CAF_NO_OPENCL AND EXISTS
"
${
CMAKE_SOURCE_DIR
}
/libcaf_opencl/CMakeLists.txt"
)
if
(
NOT CAF_NO_OPENCL
AND EXISTS
"
${
CMAKE_CURRENT_SOURCE_DIR
}
/libcaf_opencl/CMakeLists.txt"
)
add_subdirectory
(
libcaf_opencl/unit_testing
)
add_subdirectory
(
libcaf_opencl/unit_testing
)
endif
()
endif
()
endif
()
endif
()
...
@@ -341,13 +343,15 @@ if(NOT CAF_NO_EXAMPLES)
...
@@ -341,13 +343,15 @@ if(NOT CAF_NO_EXAMPLES)
message
(
STATUS
"Enter subdirectory examples"
)
message
(
STATUS
"Enter subdirectory examples"
)
add_subdirectory
(
examples
)
add_subdirectory
(
examples
)
add_dependencies
(
all_examples libcaf_core libcaf_io
)
add_dependencies
(
all_examples libcaf_core libcaf_io
)
if
(
NOT CAF_NO_OPENCL AND EXISTS
"
${
CMAKE_SOURCE_DIR
}
/libcaf_opencl/CMakeLists.txt"
)
if
(
NOT CAF_NO_OPENCL
AND EXISTS
"
${
CMAKE_CURRENT_SOURCE_DIR
}
/libcaf_opencl/CMakeLists.txt"
)
add_subdirectory
(
libcaf_opencl/examples
)
add_subdirectory
(
libcaf_opencl/examples
)
add_dependencies
(
opencl_examples libcaf_opencl
)
add_dependencies
(
opencl_examples libcaf_opencl
)
endif
()
endif
()
endif
()
endif
()
# build RIAC if not being told otherwise
# build RIAC if not being told otherwise
if
(
NOT CAF_NO_RIAC AND EXISTS
"
${
CMAKE_SOURCE_DIR
}
/libcaf_riac/CMakeLists.txt"
)
if
(
NOT CAF_NO_RIAC
AND EXISTS
"
${
CMAKE_CURRENT_SOURCE_DIR
}
/libcaf_riac/CMakeLists.txt"
)
message
(
STATUS
"Enter subdirectory probe"
)
message
(
STATUS
"Enter subdirectory probe"
)
add_subdirectory
(
libcaf_riac
)
add_subdirectory
(
libcaf_riac
)
add_dependencies
(
libcaf_riac libcaf_core libcaf_io
)
add_dependencies
(
libcaf_riac libcaf_core libcaf_io
)
...
@@ -357,14 +361,16 @@ if(NOT CAF_NO_RIAC AND EXISTS "${CMAKE_SOURCE_DIR}/libcaf_riac/CMakeLists.txt")
...
@@ -357,14 +361,16 @@ if(NOT CAF_NO_RIAC AND EXISTS "${CMAKE_SOURCE_DIR}/libcaf_riac/CMakeLists.txt")
set
(
LIBCAF_LIBRARIES
"
${
LIBCAF_LIBRARIES
}
"
libcaf_riac_static
)
set
(
LIBCAF_LIBRARIES
"
${
LIBCAF_LIBRARIES
}
"
libcaf_riac_static
)
endif
()
endif
()
# add headers to include directories so other subprojects can use RIAC
# add headers to include directories so other subprojects can use RIAC
include_directories
(
"
${
LIBCAF_INCLUDE_DIRS
}
"
"
${
CMAKE_SOURCE_DIR
}
/libcaf_riac"
)
include_directories
(
"
${
LIBCAF_INCLUDE_DIRS
}
"
"
${
CMAKE_CURRENT_SOURCE_DIR
}
/libcaf_riac"
)
# add libcaf_riac to the list of caf libraries
# add libcaf_riac to the list of caf libraries
set
(
CAF_HAS_RIAC yes
)
set
(
CAF_HAS_RIAC yes
)
else
()
else
()
set
(
CAF_HAS_RIAC no
)
set
(
CAF_HAS_RIAC no
)
endif
()
endif
()
# build nexus if not being told otherwise
# build nexus if not being told otherwise
if
(
NOT CAF_NO_NEXUS AND EXISTS
"
${
CMAKE_SOURCE_DIR
}
/nexus/CMakeLists.txt"
)
if
(
NOT CAF_NO_NEXUS
AND EXISTS
"
${
CMAKE_CURRENT_SOURCE_DIR
}
/nexus/CMakeLists.txt"
)
if
(
NOT CAF_HAS_RIAC
)
if
(
NOT CAF_HAS_RIAC
)
message
(
WARNING
"cannot build nexus without RIAC submodule"
)
message
(
WARNING
"cannot build nexus without RIAC submodule"
)
set
(
CAF_NO_NEXUS yes
)
set
(
CAF_NO_NEXUS yes
)
...
@@ -379,7 +385,8 @@ else()
...
@@ -379,7 +385,8 @@ else()
set
(
CAF_NO_NEXUS yes
)
set
(
CAF_NO_NEXUS yes
)
endif
()
endif
()
# build cash if not being told otherwise
# build cash if not being told otherwise
if
(
NOT CAF_NO_CASH AND EXISTS
"
${
CMAKE_SOURCE_DIR
}
/cash/CMakeLists.txt"
)
if
(
NOT CAF_NO_CASH
AND EXISTS
"
${
CMAKE_CURRENT_SOURCE_DIR
}
/cash/CMakeLists.txt"
)
if
(
NOT CAF_HAS_RIAC
)
if
(
NOT CAF_HAS_RIAC
)
message
(
WARNING
"cannot build cash without RIAC submodule"
)
message
(
WARNING
"cannot build cash without RIAC submodule"
)
set
(
CAF_NO_CASH yes
)
set
(
CAF_NO_CASH yes
)
...
@@ -394,7 +401,8 @@ else()
...
@@ -394,7 +401,8 @@ else()
set
(
CAF_NO_CASH yes
)
set
(
CAF_NO_CASH yes
)
endif
()
endif
()
# build benchmarks if not being told otherwise
# build benchmarks if not being told otherwise
if
(
NOT CAF_NO_BENCHMARKS AND EXISTS
"
${
CMAKE_SOURCE_DIR
}
/benchmarks/CMakeLists.txt"
)
if
(
NOT CAF_NO_BENCHMARKS
AND EXISTS
"
${
CMAKE_CURRENT_SOURCE_DIR
}
/benchmarks/CMakeLists.txt"
)
message
(
STATUS
"Enter subdirectory benchmarks"
)
message
(
STATUS
"Enter subdirectory benchmarks"
)
add_subdirectory
(
benchmarks
)
add_subdirectory
(
benchmarks
)
add_dependencies
(
all_benchmarks libcaf_io
)
add_dependencies
(
all_benchmarks libcaf_io
)
...
@@ -502,8 +510,8 @@ message(STATUS
...
@@ -502,8 +510,8 @@ message(STATUS
"
\n
CXXFLAGS:
${
ALL_CXX_FLAGS
}
"
"
\n
CXXFLAGS:
${
ALL_CXX_FLAGS
}
"
"
\n
LIBRARIES:
${
LD_FLAGS
}
"
"
\n
LIBRARIES:
${
LD_FLAGS
}
"
"
\n
"
"
\n
"
"
\n
Source directory:
${
CMAKE_SOURCE_DIR
}
"
"
\n
Source directory:
${
CMAKE_
CURRENT_
SOURCE_DIR
}
"
"
\n
Build directory:
${
CMAKE_BINARY_DIR
}
"
"
\n
Build directory:
${
CMAKE_
CURRENT_
BINARY_DIR
}
"
"
\n
Executable path:
${
EXECUTABLE_OUTPUT_PATH
}
"
"
\n
Executable path:
${
EXECUTABLE_OUTPUT_PATH
}
"
"
\n
Library path:
${
LIBRARY_OUTPUT_PATH
}
"
"
\n
Library path:
${
LIBRARY_OUTPUT_PATH
}
"
"
\n
Install prefix:
${
CMAKE_INSTALL_PREFIX
}
"
"
\n
Install prefix:
${
CMAKE_INSTALL_PREFIX
}
"
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment