mirror of https://github.com/microsoft/vcpkg.git
WIP
This commit is contained in:
parent
47e33c2dca
commit
f1ef1c1c94
|
|
@ -179,17 +179,13 @@ function(vcpkg_prepare_pkgconfig config)
|
|||
set(ENV{PKG_CONFIG} "${PKGCONFIG}")
|
||||
endif()
|
||||
|
||||
foreach(path IN ITEMS
|
||||
"${CURRENT_INSTALLED_DIR}/share/pkgconfig"
|
||||
"${CURRENT_PACKAGES_DIR}/share/pkgconfig"
|
||||
"${CURRENT_INSTALLED_DIR}${subdir}/lib/pkgconfig"
|
||||
"${CURRENT_PACKAGES_DIR}${subdir}/lib/pkgconfig"
|
||||
)
|
||||
if(EXISTS "${path}")
|
||||
vcpkg_host_path_list(PREPEND ENV{PKG_CONFIG_PATH} "${path}")
|
||||
endif()
|
||||
endforeach()
|
||||
# After installation, (merged) 'lib' is always searched before 'share'.
|
||||
vcpkg_host_path_list(PREPEND ENV{PKG_CONFIG_PATH}
|
||||
# After installation, (merged) 'lib' is always searched before 'share'.
|
||||
"${CURRENT_PACKAGES_DIR}${subdir}/lib/pkgconfig"
|
||||
"${CURRENT_INSTALLED_DIR}${subdir}/lib/pkgconfig"
|
||||
"${CURRENT_PACKAGES_DIR}/share/pkgconfig"
|
||||
"${CURRENT_INSTALLED_DIR}/share/pkgconfig"
|
||||
)
|
||||
endfunction()
|
||||
|
||||
function(vcpkg_restore_pkgconfig)
|
||||
|
|
|
|||
|
|
@ -44,19 +44,13 @@ function(z_vcpkg_setup_pkgconfig_path)
|
|||
endif()
|
||||
|
||||
foreach(prefix IN ITEMS "${CURRENT_INSTALLED_DIR}" "${CURRENT_PACKAGES_DIR}")
|
||||
if(EXISTS "${prefix}/share/pkgconfig")
|
||||
vcpkg_host_path_list(PREPEND ENV{PKG_CONFIG_PATH} "${prefix}/share/pkgconfig")
|
||||
endif()
|
||||
vcpkg_host_path_list(PREPEND ENV{PKG_CONFIG_PATH} "${prefix}/share/pkgconfig")
|
||||
if(arg_CONFIG STREQUAL "RELEASE")
|
||||
if(EXISTS "${prefix}/lib/pkgconfig")
|
||||
vcpkg_host_path_list(PREPEND ENV{PKG_CONFIG_PATH} "${prefix}/lib/pkgconfig")
|
||||
# search order is lib, share, external
|
||||
endif()
|
||||
vcpkg_host_path_list(PREPEND ENV{PKG_CONFIG_PATH} "${prefix}/lib/pkgconfig")
|
||||
# search order is lib, share, external
|
||||
elseif(arg_CONFIG STREQUAL "DEBUG")
|
||||
if(EXISTS "${prefix}/debug/lib/pkgconfig")
|
||||
vcpkg_host_path_list(PREPEND ENV{PKG_CONFIG_PATH} "${prefix}/debug/lib/pkgconfig")
|
||||
# search order is debug/lib, share, external
|
||||
endif()
|
||||
vcpkg_host_path_list(PREPEND ENV{PKG_CONFIG_PATH} "${prefix}/debug/lib/pkgconfig")
|
||||
# search order is debug/lib, share, external
|
||||
else()
|
||||
message(FATAL_ERROR "CONFIG must be either RELEASE or DEBUG.")
|
||||
endif()
|
||||
|
|
|
|||
Loading…
Reference in New Issue