build: (fixes #928) Fix pkgconfig generation

This commit is contained in:
Gabriel Ferreira
2023-07-14 15:30:31 -03:00
parent 6a71f98430
commit 2d69a05371

View File

@@ -29,7 +29,7 @@ function(build_required_and_libs_lists module_name visibility libraries
)
set(lib_real_name "-l${lib_real_name}")
else()
if(IS_ABSOLUTE ${lib})
if((IS_ABSOLUTE "${lib}") OR ("${lib}" MATCHES "^-l"))
set(lib_real_name ${lib})
else()
set(lib_real_name "-l${lib}")
@@ -88,6 +88,9 @@ function(pkgconfig_module libname)
string(REPLACE ";-I" " -I" pkgconfig_interface_include_directories
"${pkgconfig_interface_include_directories}"
)
string(REPLACE ";" "" pkgconfig_interface_include_directories
"${pkgconfig_interface_include_directories}"
)
endif()
# Configure pkgconfig file for the module using pkgconfig variables