From eacf7decbf78a184cdad7a6fd533aa4f433ec27f Mon Sep 17 00:00:00 2001 From: Michael Maltese Date: Tue, 21 Feb 2017 22:21:49 -0800 Subject: GetPrerequisites: also try to resolve just the basename Fixes #16625. --- Modules/GetPrerequisites.cmake | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/Modules/GetPrerequisites.cmake b/Modules/GetPrerequisites.cmake index 1b23800..417af7c 100644 --- a/Modules/GetPrerequisites.cmake +++ b/Modules/GetPrerequisites.cmake @@ -399,6 +399,11 @@ function(gp_resolve_item context item exepath dirs resolved_item_var) set(ri "ri-NOTFOUND") find_file(ri "${item}" ${exepath} ${dirs} NO_DEFAULT_PATH) find_file(ri "${item}" ${exepath} ${dirs} /usr/lib) + + get_filename_component(basename_item "${item}" NAME) + find_file(ri "${basename_item}" PATHS ${exepath} ${dirs} NO_DEFAULT_PATH) + find_file(ri "${basename_item}" PATHS /usr/lib) + if(ri) #message(STATUS "info: 'find_file' in exepath/dirs (${ri})") set(resolved 1) -- cgit v0.12