forked from OSchip/llvm-project
llvm-config-2: Fix --cflags and --includedir which pointed at the wrong
directory when running from a build directory. llvm-svn: 145622
This commit is contained in:
parent
f60485c4cf
commit
5a78bb5686
|
@ -210,16 +210,15 @@ int main(int argc, char **argv) {
|
||||||
std::string ActivePrefix, ActiveBinDir, ActiveIncludeDir, ActiveLibDir;
|
std::string ActivePrefix, ActiveBinDir, ActiveIncludeDir, ActiveLibDir;
|
||||||
std::string ActiveIncludeOption;
|
std::string ActiveIncludeOption;
|
||||||
if (IsInDevelopmentTree) {
|
if (IsInDevelopmentTree) {
|
||||||
|
ActiveIncludeDir = std::string(LLVM_SRC_ROOT) + "/include";
|
||||||
ActivePrefix = CurrentExecPrefix;
|
ActivePrefix = CurrentExecPrefix;
|
||||||
|
|
||||||
// CMake organizes the products differently than a normal prefix style
|
// CMake organizes the products differently than a normal prefix style
|
||||||
// layout.
|
// layout.
|
||||||
if (DevelopmentTreeLayoutIsCMakeStyle) {
|
if (DevelopmentTreeLayoutIsCMakeStyle) {
|
||||||
ActiveIncludeDir = ActiveObjRoot + "/include";
|
|
||||||
ActiveBinDir = ActiveObjRoot + "/bin/" + LLVM_BUILDMODE;
|
ActiveBinDir = ActiveObjRoot + "/bin/" + LLVM_BUILDMODE;
|
||||||
ActiveLibDir = ActiveObjRoot + "/lib/" + LLVM_BUILDMODE;
|
ActiveLibDir = ActiveObjRoot + "/lib/" + LLVM_BUILDMODE;
|
||||||
} else {
|
} else {
|
||||||
ActiveIncludeDir = ActiveObjRoot + "/include";
|
|
||||||
ActiveBinDir = ActiveObjRoot + "/" + LLVM_BUILDMODE + "/bin";
|
ActiveBinDir = ActiveObjRoot + "/" + LLVM_BUILDMODE + "/bin";
|
||||||
ActiveLibDir = ActiveObjRoot + "/" + LLVM_BUILDMODE + "/lib";
|
ActiveLibDir = ActiveObjRoot + "/" + LLVM_BUILDMODE + "/lib";
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue