mirror of
https://github.com/ldc-developers/ldc.git
synced 2025-04-30 15:10:59 +03:00
Locate Intrinsics.td in CMakeLists.txt.
The LLVM_INCLUDE_DIR is not always defined (e.g. missing in Windows). We simply locate the file and pass the folder path to the tool.
This commit is contained in:
parent
7674e4292f
commit
add8e91653
2 changed files with 12 additions and 3 deletions
|
@ -6,7 +6,6 @@
|
|||
#include <string.h>
|
||||
#include <assert.h>
|
||||
|
||||
#include <llvm/Config/llvm-config.h>
|
||||
#include <llvm/TableGen/Main.h>
|
||||
#if LDC_LLVM_VER < 302
|
||||
#include <llvm/TableGen/TableGenAction.h>
|
||||
|
@ -148,11 +147,11 @@ int main(int argc, char** argv)
|
|||
return 1;
|
||||
}
|
||||
|
||||
sys::Path file(LLVM_INCLUDEDIR);
|
||||
sys::Path file(LLVM_INTRINSIC_TD_PATH);
|
||||
file.appendComponent("llvm");
|
||||
file.appendComponent("Intrinsics.td");
|
||||
|
||||
string iStr = string("-I=") + string(LLVM_INCLUDEDIR);
|
||||
string iStr = string("-I=") + string(LLVM_INTRINSIC_TD_PATH);
|
||||
string oStr = string("-o=") + argv[1];
|
||||
|
||||
vector<char*> args2(argv, argv + 1);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue