[CastXML] Building CastXML on a linux machine

Uğur Büyükdurak ugurbd at gmail.com
Thu Nov 26 01:24:40 EST 2015


Hello,

I am trying to build CastXML on a Ubuntu machine. There are couple problems
I have faced but wasn't able to solve. From castxml's github page,

To build CastXML from source, first obtain the prerequisites:

   - A C++ compiler supporting the c++11 standard language level.
   - CMake <http://www.cmake.org/> cross-platform build system generator.
   - LLVM/Clang <http://clang.llvm.org/> compiler SDK install tree built
   using the C++ compiler. This version of CastXML has been tested with
   LLVM/Clang
      - SVN revision 245954
      - Release 3.7
      - Release 3.6
   - Optionally, the Sphinx <http://sphinx-doc.org/> documentation
   generator to build documentation.

Run CMake on the CastXML source tree to generate a build tree using a C++
compiler compatible with that used to build the LLVM/Clang SDK. CMake
options include:
LLVM_DIRLocation of the LLVM/Clang SDK. Set to <prefix>/share/llvm/cmake,
where <prefix> is the top of the LLVM/Clang SDK install tree.
SPHINX_EXECUTABLELocation of the sphinx-build executable. Required only if
building documentation.SPHINX_HTMLBuild documentation in html format.
SPHINX_MANBuild documentation in man format.


I have g++ and clang++ installed in my computer. So my questions are,

1-) Description says to run cmake on CastXML "source tree". Does this mean
I should run cmake with the CMakeLists.txt or there are additional things
that I need to include? What is going to be the input for cmake?

2-)My other question is about LLVM_DIR. It says location of LLVM/Clang SDK.
This is not the clang compiler itself right? This is I suppose Software
Development Kit used by clang compiler?

3-) What does it mean <prefix> to be top of LLVM/Clang install tree?

<prefix>/share/llvm/cmake what does this has to do with LLVM/Clang SDK?

When I run cmake with CMakeLists.txt, I get the following error from the
terminal

CMake Error at /usr/share/llvm-3.6/cmake/LLVMConfig.cmake:52 (include):
  include could not find load file:

    /usr/lib/llvm-3.6/share/llvm/cmake/LLVMExports.cmake
Call Stack (most recent call first):
  CMakeLists.txt:58 (find_package)


CMake Error at /usr/share/llvm-3.6/cmake/LLVMConfig.cmake:55 (include):
  include could not find load file:

    /usr/lib/llvm-3.6/share/llvm/cmake/LLVM-Config.cmake
Call Stack (most recent call first):
  CMakeLists.txt:58 (find_package)


CMake Error at src/CMakeLists.txt:46 (llvm_map_components_to_libnames):
  Unknown CMake command "llvm_map_components_to_libnames".


-- Configuring incomplete, errors occurred!

Do you know what causes this error?

Regards,
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/castxml/attachments/20151126/f8d2ca1b/attachment.html>


More information about the CastXML mailing list