Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in / Register
Toggle navigation
O
opencv
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Packages
Packages
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
submodule
opencv
Commits
938d42a8
Commit
938d42a8
authored
Oct 19, 2015
by
Alexander Alekhin
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #5545 from alalek:fix_linker_libs
parents
bf41e791
937a096b
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
22 additions
and
1 deletion
+22
-1
OpenCVModule.cmake
cmake/OpenCVModule.cmake
+4
-1
OpenCVUtils.cmake
cmake/OpenCVUtils.cmake
+18
-0
No files found.
cmake/OpenCVModule.cmake
View file @
938d42a8
...
...
@@ -576,7 +576,10 @@ macro(ocv_create_module)
if
(
NOT
"
${
ARGN
}
"
STREQUAL
"SKIP_LINK"
)
target_link_libraries
(
${
the_module
}
${
OPENCV_MODULE_
${
the_module
}
_DEPS
}
)
target_link_libraries
(
${
the_module
}
LINK_INTERFACE_LIBRARIES
${
OPENCV_MODULE_
${
the_module
}
_DEPS
}
)
target_link_libraries
(
${
the_module
}
${
OPENCV_MODULE_
${
the_module
}
_DEPS_EXT
}
${
OPENCV_LINKER_LIBS
}
${
IPP_LIBS
}
${
ARGN
}
)
set
(
extra_deps
${
OPENCV_MODULE_
${
the_module
}
_DEPS_EXT
}
${
OPENCV_LINKER_LIBS
}
${
IPP_LIBS
}
${
ARGN
}
)
ocv_extract_simple_libs
(
extra_deps _simple_deps _other_deps
)
target_link_libraries
(
${
the_module
}
LINK_INTERFACE_LIBRARIES
${
_simple_deps
}
)
# this list goes to "export"
target_link_libraries
(
${
the_module
}
${
extra_deps
}
)
endif
()
add_dependencies
(
opencv_modules
${
the_module
}
)
...
...
cmake/OpenCVUtils.cmake
View file @
938d42a8
...
...
@@ -630,3 +630,21 @@ function(ocv_source_group group)
file
(
GLOB srcs
${
OCV_SOURCE_GROUP_GLOB
}
)
source_group
(
${
group
}
FILES
${
srcs
}
)
endfunction
()
# build the list of simple dependencies, that links via "-l"
# _all_libs - name of variable with input list
# _simple - name of variable with output list of simple libs
# _other - name of variable with _all_libs - _simple
macro
(
ocv_extract_simple_libs _all_libs _simple _other
)
set
(
${
_simple
}
""
)
set
(
${
_other
}
""
)
foreach
(
_l
${${
_all_libs
}}
)
if
(
TARGET
${
_l
}
)
list
(
APPEND
${
_other
}
${
_l
}
)
elseif
(
EXISTS
"
${
_l
}
"
)
list
(
APPEND
${
_other
}
${
_l
}
)
else
()
list
(
APPEND
${
_simple
}
${
_l
}
)
endif
()
endforeach
()
endmacro
()
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