diff --git a/cmake/Corrosion.cmake b/cmake/Corrosion.cmake index fbd99719..9b767bd7 100644 --- a/cmake/Corrosion.cmake +++ b/cmake/Corrosion.cmake @@ -245,7 +245,7 @@ function(_corrosion_copy_byproduct_deferred target_name output_dir_prop_name car "Internal error: Exactly one filename should be passed for executable types.") endif() _corrosion_bin_target_suffix(${target_name} "suffix") - if(suffix AND (NOT ("${filenames}" MATCHES "\.pdb$"))) + if(suffix AND (NOT ("${filenames}" MATCHES ".*\.pdb$"))) message(STATUS "Appending suffix to filename ${file_names}") # For bin targets we know that there is only one target, not a list. string(APPEND "file_names" "${suffix}")