Skip to content

Commit

Permalink
Don't include CMAKE_INSTALL_PREFIX when LIBDIR is absolute (#8552)
Browse files Browse the repository at this point in the history
  • Loading branch information
alexreinking authored Jan 15, 2025
1 parent 5f56f68 commit 59f4fff
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion cmake/HalidePackageConfigHelpers.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -78,9 +78,10 @@ function(_Halide_install_pkgdeps)
)

set(depFile "${CMAKE_CURRENT_BINARY_DIR}/${ARG_FILE_NAME}")
set(installPrefix "$<$<PATH:IS_RELATIVE,${ARG_DESTINATION}>:\${CMAKE_INSTALL_PREFIX}/>")

_Halide_install_code(
"file(READ \"\$ENV{DESTDIR}\${CMAKE_INSTALL_PREFIX}/${ARG_DESTINATION}/${ARG_EXPORT_FILE}\" target_cmake)"
"file(READ \"\$ENV{DESTDIR}${installPrefix}${ARG_DESTINATION}/${ARG_EXPORT_FILE}\" target_cmake)"
"file(WRITE \"${depFile}.in\" \"\")"
)

Expand Down

0 comments on commit 59f4fff

Please sign in to comment.