Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
lib4neuro
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Deploy
Releases
Container Registry
Model registry
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
MolDyn
lib4neuro
Commits
5e4a38f4
Commit
5e4a38f4
authored
6 years ago
by
Martin Beseda
Browse files
Options
Downloads
Patches
Plain Diff
FIX: ARAM_LIBS is now set to OpenBLAS_LIBRARIES.
parent
bac2d19c
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
CMakeLists.txt
+18
-21
18 additions, 21 deletions
CMakeLists.txt
FindOpenBLAS.cmake
+3
-1
3 additions, 1 deletion
FindOpenBLAS.cmake
with
21 additions
and
22 deletions
CMakeLists.txt
+
18
−
21
View file @
5e4a38f4
...
...
@@ -89,14 +89,18 @@ message("Build will be performed on ${N_CORES} cores.")
#---------------#
# Set variables #
#---------------#
set
(
ROOT_DIR
"
${
CMAKE_CURRENT_LIST_DIR
}
"
)
set
(
LROOT_DIR
${
CMAKE_CURRENT_LIST_DIR
}
)
set
(
SRC_DIR
${
CMAKE_CURRENT_LIST_DIR
}
/src
)
set
(
PROJECT_BINARY_DIR
${
CMAKE_CURRENT_LIST_DIR
}
/build
)
set
(
ROOT_DIR
${
CMAKE_CURRENT_LIST_DIR
}
)
set
(
SRC_DIR
${
ROOT_DIR
}
/src
)
set
(
PROJECT_BINARY_DIR
${
ROOT_DIR
}
/build
)
set
(
CMAKE_LIBRARY_OUTPUT_DIRECTORY lib
)
set
(
CMAKE_ARCHIVE_OUTPUT_DIRECTORY lib
)
set
(
CMAKE_RUNTIME_OUTPUT_DIRECTORY
${
PROJECT_BINARY_DIR
}
/bin
)
#---------------------------------------------------#
# Add subdirectory with source codes to be compiled #
#---------------------------------------------------#
add_subdirectory
(
${
SRC_DIR
}
${
PROJECT_BINARY_DIR
}
)
#----------------------------------------#
# Set prefixes and suffixes of libraries #
#----------------------------------------#
...
...
@@ -114,7 +118,6 @@ endif()
#-------------------------#
# Find external libraries #
#-------------------------#
message
(
"Looking for external libraries..."
)
set
(
CMAKE_MODULE_PATH
${
CMAKE_CURRENT_SOURCE_DIR
}
)
...
...
@@ -157,12 +160,17 @@ endif()
message
(
"Checking Armadillo dependencies"
)
find_package
(
LAPACK
)
find_package
(
BLAS
)
find_package
(
OpenBLAS
)
if
(
NOT LAPACK_FOUND AND NOT BLAS_FOUND AND NOT OpenBLAS_FOUND AND ALLOW_DEPENDENCIES_DOWNLOAD
)
# Download and build OpenBLAS locally
message
(
"LAPACK nor BLAS were found - OpenBLAS will be downloaded and built."
)
include
(
DownloadOpenBLAS
)
set
(
ARMA_LIBS
""
)
if
(
NOT LAPACK_FOUND AND NOT BLAS_FOUND
)
find_package
(
OpenBLAS
)
if
(
NOT OpenBLAS_FOUND AND ALLOW_DEPENDENCIES_DOWNLOAD
)
# Download and build OpenBLAS locally
message
(
"LAPACK nor BLAS were found - OpenBLAS will be downloaded and built."
)
include
(
DownloadOpenBLAS
)
endif
()
endif
()
set
(
ARMA_LIBS
"
${
OpenBLAS_LIBRARIES
}
"
)
find_package
(
Armadillo
)
if
(
NOT ARMADILLO_FOUND AND ALLOW_DEPENDENCIES_DOWNLOAD
)
...
...
@@ -170,15 +178,4 @@ if(NOT ARMADILLO_FOUND AND ALLOW_DEPENDENCIES_DOWNLOAD)
include
(
DownloadArmadillo
)
endif
()
#----------------------------------------#
# Dependencies for the lib4neuro library #
#----------------------------------------#
message
(
"Running CMake in:
${
SRC_DIR
}
${
PROJECT_BINARY_DIR
}
"
)
#
#if("${BUILD_LIB}" STREQUAL "no")
#
# link_directories(${LIB4NEURO_DIR})
#
#endif()
add_subdirectory
(
${
SRC_DIR
}
${
PROJECT_BINARY_DIR
}
)
This diff is collapsed.
Click to expand it.
FindOpenBLAS.cmake
+
3
−
1
View file @
5e4a38f4
...
...
@@ -19,7 +19,9 @@ FIND_PATH(
include/x86_64-linux-gnu
)
FIND_LIBRARY
(
OpenBLAS_LIBRARIES
FIND_LIBRARY
(
OpenBLAS_LIBRARIES
NAMES
${
LIB_PREFIX
}
openblas.
${
LIB_SUFFIX
}
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment