cmake TableGen

When trying to cmake TableGen, I got these error and warning:

CMake Error at CMakeLists.txt:5 (add_tablegen):
Unknown CMake command “add_tablegen”.

CMake Warning (dev) in CMakeLists.txt:
No cmake_minimum_required command is present. A line of code such as

cmake_minimum_required(VERSION 2.8)

should be added at the top of the file. The version specified may be lower
if you wish to support older CMake versions for this project. For more
information run “cmake --help-policy CMP0000”.
This warning is for project developers. Use -Wno-dev to suppress it.

– Configuring incomplete, errors occurred!

Any idea?


Are you calling cmake from the TableGen subdir? If yes, that's not
going to fly - you need to call cmake with the toplevel directory, and
it will recurse automatically.



I have no idea whether / how you can compile clang with gcc 4.1. I
cc'ed the list back in, so somebody else might be able to help.


There is gcc 4.4.0 in repositories of RHEL 5 / CentOS 5.