0
votes

Question 1: What is the proper way to create a "Run Configuration" in Eclipse, to execute an LLVM BitCode .bc file?

And/Or:

Question 2: What is the proper way to configure an alternate Run Configuration to output executable files, rather than .bc files, using llvm-vd, or clang++?

In Eclipse:

  1. "Run As: LLVM BitCode"
  2. "Run As: .exe under Windows"
  3. Future: "Run As: .exe under Wine", (which would probably be similar to #1 ...)

Notes:

  1. By default, the Build Configuration generates .bc files.
  2. In Build Settings/Build Artifact, there is not Build Artifact Type for "Executable", but just for "Static Library"--an no option to create an "Executable Build Artifact Type".

Toolset: 1. Eclipse's CDT with LLVM/Clang 2. MinGW-64

1
Seems like a bit of an XY question - what are you ACTUALLY trying to do? In other words, what are you doing that produces a .bc file, and why do you think that's a good idea?Mats Petersson
Thanks! There is an emit llvm optimization, and I really want to output and run, either the lli .bc file, and/or the .exe file alternatively, (for debugging, cross platform testing, etc) So, the issue really is how to execute either one, after the build. I want to Create "Run As Local BC Application" and another "Run As Local EXE Application".elika kohen

1 Answers

0
votes

After fighting with this, for a while, I have come to the conclusion that with the current LLVM plugin for Eclipse, this just isn't possible, as it is very dated, and doesn't support the latest Clang Toolchain, (clang++, llc, etc), but uses the deprecated llvm-vd, etc.

That being said, there may be a possibility with a regular make project, or using CMake.