Skip to content

Commit ff41a6f

Browse files
committed
Hint the location of dependencies
If a ROCm package knows its installed under PACKAGE_PREFIX_DIR, it should search under that project prefix for related dependencies. This prevents users from having to add that prefix to their CMake module, path, which is a known antipattern.
1 parent d0aa73b commit ff41a6f

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

share/rocmcmakebuildtools/cmake/ROCMPackageConfigHelpers.cmake

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -107,6 +107,7 @@ if (NOT _ROCMCMakeFindDependencyMacro_FOUND)
107107
\${rocm_fd_exact_arg}
108108
\${rocm_fd_quiet_arg}
109109
\${rocm_fd_required_arg}
110+
HINTS \"\${PACKAGE_PREFIX_DIR}\"
110111
)
111112
string(TOUPPER \${dep} cmake_dep_upper)
112113
if (NOT \${dep}_FOUND AND NOT \${cmake_dep_upper}_FOUND)

0 commit comments

Comments
 (0)