Index: tools/llvm-config/BuildVariables.inc.in =================================================================== --- tools/llvm-config/BuildVariables.inc.in +++ tools/llvm-config/BuildVariables.inc.in @@ -34,3 +34,4 @@ #define LLVM_DYLIB_COMPONENTS "@LLVM_DYLIB_COMPONENTS@" #define LLVM_DYLIB_VERSION "@LLVM_DYLIB_VERSION@" #define LLVM_HAS_GLOBAL_ISEL "@LLVM_HAS_GLOBAL_ISEL@" +#define LLVM_TOOLS_INSTALL_DIR "@LLVM_TOOLS_INSTALL_DIR@" Index: tools/llvm-config/llvm-config.cpp =================================================================== --- tools/llvm-config/llvm-config.cpp +++ tools/llvm-config/llvm-config.cpp @@ -328,7 +328,7 @@ } else { ActivePrefix = CurrentExecPrefix; ActiveIncludeDir = ActivePrefix + "/include"; - ActiveBinDir = ActivePrefix + "/bin"; + ActiveBinDir = ActivePrefix + "/" + LLVM_TOOLS_INSTALL_DIR; ActiveLibDir = ActivePrefix + "/lib" + LLVM_LIBDIR_SUFFIX; ActiveIncludeOption = "-I" + ActiveIncludeDir; }