Errors in using clang libs

I used the following command to compile test.cpp which calls some libs of
clang.

clang++ -I/home/chen/workspace/llvm/include
-I/home/chen/workspace/llvm/tools/clang/include
-L/home/chen/workspace/llvm/Debug+Asserts/lib -o test test.cpp
-lclangFrontend -lclangParse -lclangSema -lclangAnalysis -lclangAST
-lclangLex -lclangBasic -lclangDriver -lclangSerialization -lclangEdit
-lLLVMMC -lLLVMSupport -lclangRewrite

HOWEVER, SOME ERRORS OCCUR as follows:

In file included from test.cpp:55:
In file included from
/home/chen/workspace/llvm/include/llvm/Support/Host.h:17:
In file included from
/home/chen/workspace/llvm/include/llvm/ADT/StringMap.h:18:
In file included from
/home/chen/workspace/llvm/include/llvm/Support/Allocator.h:18:
In file included from
/home/chen/workspace/llvm/include/llvm/Support/MathExtras.h:17:
In file included from
/home/chen/workspace/llvm/include/llvm/Support/SwapByteOrder.h:18:
/home/chen/workspace/llvm/include/llvm/Support/DataTypes.h:49:3: error:
"Must
      #define __STDC_LIMIT_MACROS before #including Support/DataTypes.h"
# error "Must #define __STDC_LIMIT_MACROS before #including
Support/DataTypes.h"
  ^
/home/chen/workspace/llvm/include/llvm/Support/DataTypes.h:53:3: error:
"Must
      #define __STDC_CONSTANT_MACROS before " "#including
      Support/DataTypes.h"
# error "Must #define __STDC_CONSTANT_MACROS before " \
  ^
In file included from test.cpp:55:
In file included from
/home/chen/workspace/llvm/include/llvm/Support/Host.h:17:
In file included from
/home/chen/workspace/llvm/include/llvm/ADT/StringMap.h:18:
In file included from
/home/chen/workspace/llvm/include/llvm/Support/Allocator.h:18:
/home/chen/workspace/llvm/include/llvm/Support/MathExtras.h:38:24: error:
use of
      undeclared identifier 'INT64_C'
  return N >= 64 || (-(INT64_C(1)<<(N-1)) <= x && x < (INT64_C(1)<<(N-1)));

I did not find out the reason.
Please help me to figure it out. Thanks a lot!

Have you thought about defining the macros that were requested?

-eric

I thought that the macros should have been defined in some header files.
But the compiler did not find them in the included paths.

No, they're defined on the command line. Look in the makefile.

-eric