Mentions légales du service

Skip to content
Snippets Groups Projects
Commit 7b5ed135 authored by PRUVOST Florent's avatar PRUVOST Florent
Browse files

GenPkgConfig.cmake: fix -L/opt/foo/lib -lfoo case

parent a70a39d2
No related branches found
No related tags found
No related merge requests found
...@@ -108,8 +108,8 @@ macro(gpc_convert_libstyle_to_pkgconfig _liblist) ...@@ -108,8 +108,8 @@ macro(gpc_convert_libstyle_to_pkgconfig _liblist)
endforeach() endforeach()
string(REGEX REPLACE "^lib" "" dep_libname "${dep_libname}") string(REGEX REPLACE "^lib" "" dep_libname "${dep_libname}")
list(APPEND ${_liblist} -L${dep_libdir} -l${dep_libname}) list(APPEND ${_liblist} -L${dep_libdir} -l${dep_libname})
elseif(${_dep} MATCHES "^-l") elseif(${_dep} MATCHES "^-l|^-L")
# case library given with -l (e.g. -lfoo) # case library given with -l (e.g. -lfoo) or -L (e.g. -L/opt/foo/lib -lfoo)
list(APPEND ${_liblist} ${_dep}) list(APPEND ${_liblist} ${_dep})
else() else()
# case library given by name (e.g. foo) # case library given by name (e.g. foo)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment