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
e4673e8d
Commit
e4673e8d
authored
6 years ago
by
Martin Beseda
Browse files
Options
Downloads
Patches
Plain Diff
Testing own FindBoost.cmake
parent
8314062e
No related branches found
No related tags found
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
FindBoost.cmake
+15
-2
15 additions, 2 deletions
FindBoost.cmake
external_dependencies/boost
+1
-1
1 addition, 1 deletion
external_dependencies/boost
external_dependencies/exprtk
+1
-1
1 addition, 1 deletion
external_dependencies/exprtk
with
17 additions
and
4 deletions
FindBoost.cmake
+
15
−
2
View file @
e4673e8d
# This file is NOT an original FindBoost.cmake module provided by KitWare!
# This file is NOT an original FindBoost.cmake module provided by KitWare!
#
#
# It's a simplified version whose only purpose is to be used in a software
# It's a simplified version whose only purpose is to be used in a software
# library lib4neuro and it does NOT provide a full funcionality of the original.
# library lib4neuro and it does NOT provide a full funcionality of the original,
# as it only works with the system-layout-named libraries (e.g. libboost_system.so).
# Optional user-defined variables
# Optional user-defined variables
# (can be passed directly to CMake or exported as environmental variables
# (can be passed directly to CMake or exported as environmental variables
...
@@ -27,6 +28,8 @@ message("FindBoost starting...")
...
@@ -27,6 +28,8 @@ message("FindBoost starting...")
# Check if needed Boost components were specified
# Check if needed Boost components were specified
if
(
NOT Boost_FIND_COMPONENTS
)
if
(
NOT Boost_FIND_COMPONENTS
)
message
(
FATAL_ERROR
"No Boost components were specified! Please, set them correctly with flag COMPONENTS (see Module Usage section in this script)."
)
message
(
FATAL_ERROR
"No Boost components were specified! Please, set them correctly with flag COMPONENTS (see Module Usage section in this script)."
)
else
()
message
(
"Required Boost components:
${
Boost_FIND_COMPONENTS
}
"
)
endif
()
endif
()
# Look for a standard boost header file.
# Look for a standard boost header file.
...
@@ -61,9 +64,11 @@ if(NOT DEPENDENCIES_LINK_TYPE)
...
@@ -61,9 +64,11 @@ if(NOT DEPENDENCIES_LINK_TYPE)
message
(
FATAL_ERROR
"Variable DEPENDENCIES_LINK_TYPE is not set! Set it to 'static' or 'shared'."
)
message
(
FATAL_ERROR
"Variable DEPENDENCIES_LINK_TYPE is not set! Set it to 'static' or 'shared'."
)
endif
()
endif
()
set
(
LIB_SUFFIX
"a"
)
set
(
LIB_SUFFIX
"a"
)
# suffix for Linux static libraries
if
(
"
${
DEPENDENCIES_LINK_TYPE
}
"
STREQUAL
"shared"
AND WIN32
)
if
(
"
${
DEPENDENCIES_LINK_TYPE
}
"
STREQUAL
"shared"
AND WIN32
)
set
(
LIB_SUFFIX
"dll"
)
set
(
LIB_SUFFIX
"dll"
)
elseif
(
"
${
DEPENDENCIES_LINK_TYPE
}
"
STREQUAL
"static"
AND WIN32
)
se
(
LIB_SUFFIX
"lib"
)
elseif
(
"
${
DEPENDENCIES_LINK_TYPE
}
"
STREQUAL
"shared"
)
elseif
(
"
${
DEPENDENCIES_LINK_TYPE
}
"
STREQUAL
"shared"
)
set
(
LIB_SUFFIX
"so"
)
set
(
LIB_SUFFIX
"so"
)
endif
()
endif
()
...
@@ -104,6 +109,8 @@ find_path(
...
@@ -104,6 +109,8 @@ find_path(
# targets, so they may be linked
# targets, so they may be linked
set
(
Boost_LIBRARIES
""
)
set
(
Boost_LIBRARIES
""
)
foreach
(
LIBNAME
${
REQUESTED_BOOST_LIBS
}
)
foreach
(
LIBNAME
${
REQUESTED_BOOST_LIBS
}
)
message
(
"Looking for
${
LIBNAME
}
..."
)
set
(
${
LIBNAME
}
"
${
LIBNAME
}
-NOTFOUND"
)
set
(
${
LIBNAME
}
"
${
LIBNAME
}
-NOTFOUND"
)
find_library
(
find_library
(
${
LIBNAME
}
${
LIBNAME
}
...
@@ -121,6 +128,12 @@ foreach(LIBNAME ${REQUESTED_BOOST_LIBS})
...
@@ -121,6 +128,12 @@ foreach(LIBNAME ${REQUESTED_BOOST_LIBS})
NO_DEFAULT_PATH
NO_DEFAULT_PATH
)
)
# Check, if the Boost component was found
if
(
"
${
LIBNAME
}
"
STREQUAL
"
${
LIBNAME
}
-NOTFOUND"
)
message
(
FATAL_ERROR
"Boost library
${
LIBNAME
}
was NOT found!
Please, set variable BOOST_LIBRARYDIR to the correct path and check the library names
format in your Boost installation."
)
message
(
"
${
LIBNAME
}
${${
LIBNAME
}}
"
)
message
(
"
${
LIBNAME
}
${${
LIBNAME
}}
"
)
# Make the target of the same name as the library
# Make the target of the same name as the library
...
...
This diff is collapsed.
Click to expand it.
boost
@
507ad00a
Compare
f7371ecb
...
507ad00a
Subproject commit
f7371ecb0652555ec89cb28e58c18fda56685985
Subproject commit
507ad00a0ad1ce6e8833f2f529fa1e9150c446c0
This diff is collapsed.
Click to expand it.
exprtk
@
9836f21d
Compare
9a8474e7
...
9836f21d
Subproject commit 9
a8474e7a259fa5348658a651cd19af216749674
Subproject commit 9
836f21d07b1bf799e6877324268708f61c01f73
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