-
Notifications
You must be signed in to change notification settings - Fork 14.7k
Open
Labels
llvm-toolsAll llvm tools that do not have corresponding tagAll llvm tools that do not have corresponding tag
Description
Originally reported in https://discourse.llvm.org/t/compiled-llm-config-executable-programs-do-not-correctly-point-to-the-installation-directory/87766.
Build llvm as follows:
$ mkdir build-llvm-config && cd llvm-config
$ make ../llvm-project/llvm -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=/home/david.spickett/build-llvm-config/llvm.install -G Ninja -DLLVM_CCACHE_BUILD=ON && ninja && ninja install
Note that the install directory is inside the build directory.
This causes the llvm-config
in the installed directory to report an incorrect library path:
~/build-llvm-config$ ./llvm.install/bin/llvm-config --ldflags
-L/home/david.spickett/build-llvm-config/Release/lib
The one in the build directory's bin
points to the build's library dir as expected:
~/build-llvm-config$ ./bin/llvm-config --ldflags
-L/home/david.spickett/build-llvm-config/lib
I think llvm-config has autodetected as InDevelopmentTree
true (which it is, sort of) and DevelopmentTreeLayout
of CMakeBuildModeStyle
. This causes it to put build_mode
in the path which is read from LLVM_BUILDMODE
which would be Release
.
Metadata
Metadata
Assignees
Labels
llvm-toolsAll llvm tools that do not have corresponding tagAll llvm tools that do not have corresponding tag