[PATCH] D101070: Make `llvm_install_symlink` robust with respect to absolute dirs.

John Ericson via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Thu Jan 20 14:21:45 PST 2022


Ericson2314 updated this revision to Diff 401784.
Ericson2314 added a comment.

Much simpler now

Code taken from D99484 <https://reviews.llvm.org/D99484> and then to D117419 <https://reviews.llvm.org/D117419> and now to here.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D101070/new/

https://reviews.llvm.org/D101070

Files:
  llvm/cmake/modules/LLVMInstallSymlink.cmake


Index: llvm/cmake/modules/LLVMInstallSymlink.cmake
===================================================================
--- llvm/cmake/modules/LLVMInstallSymlink.cmake
+++ llvm/cmake/modules/LLVMInstallSymlink.cmake
@@ -6,7 +6,8 @@
 
 function(install_symlink name target outdir)
   set(DESTDIR $ENV{DESTDIR})
-  set(bindir "${DESTDIR}${CMAKE_INSTALL_PREFIX}/${outdir}")
+  GNUInstallDirs_get_absolute_install_dir(bindir "${outdir}" BINDIR)
+  set(bindir "${DESTDIR}${bindir}")
 
   message(STATUS "Creating ${name}")
 


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D101070.401784.patch
Type: text/x-patch
Size: 519 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20220120/91a3453e/attachment.bin>


More information about the cfe-commits mailing list