the immediate field of pshufw is actually an 8-bit field, not a 8-bit field that...
[oota-llvm.git] / CMakeLists.txt
index 7959f65647b93621e6aa666c5ec51f805bc818b3..d473f51b59beabe6cf3c6bfaa73b14e4d000548d 100644 (file)
@@ -66,6 +66,7 @@ set(LLVM_ALL_TARGETS
   MSP430
   PIC16
   PowerPC
+  PTX
   Sparc
   SystemZ
   X86
@@ -323,6 +324,11 @@ foreach(t ${LLVM_TARGETS_TO_BUILD})
     set(LLVM_ENUM_ASM_PRINTERS 
       "${LLVM_ENUM_ASM_PRINTERS}LLVM_ASM_PRINTER(${t})\n")
   endif( EXISTS ${LLVM_MAIN_SRC_DIR}/lib/Target/${t}/AsmPrinter/CMakeLists.txt )
+  if( EXISTS ${LLVM_MAIN_SRC_DIR}/lib/Target/${t}/InstPrinter/CMakeLists.txt )
+    add_subdirectory(lib/Target/${t}/InstPrinter)
+    set(LLVM_ENUM_ASM_PRINTERS
+      "${LLVM_ENUM_ASM_PRINTERS}LLVM_ASM_PRINTER(${t})\n")
+  endif( EXISTS ${LLVM_MAIN_SRC_DIR}/lib/Target/${t}/InstPrinter/CMakeLists.txt )
   if( EXISTS ${LLVM_MAIN_SRC_DIR}/lib/Target/${t}/AsmParser/CMakeLists.txt )
     add_subdirectory(lib/Target/${t}/AsmParser)
     set(LLVM_ENUM_ASM_PARSERS 
@@ -336,6 +342,11 @@ foreach(t ${LLVM_TARGETS_TO_BUILD})
   set(CURRENT_LLVM_TARGET)
 endforeach(t)
 
+# PIC16 contains an odd library:
+if( LLVM_TARGETS_TO_BUILD MATCHES ".*PIC16.*" )
+  add_subdirectory(lib/Target/PIC16/PIC16Passes)
+endif()
+
 # Produce llvm/Config/AsmPrinters.def
 configure_file(
   ${LLVM_MAIN_INCLUDE_DIR}/llvm/Config/AsmPrinters.def.in
@@ -363,17 +374,28 @@ add_subdirectory(lib/Archive)
 
 add_subdirectory(projects)
 
-option(LLVM_BUILD_TOOLS "Build LLVM tool programs." ON)
-add_subdirectory(tools)
-
-option(LLVM_BUILD_EXAMPLES "Build LLVM example programs." OFF)
-add_subdirectory(examples)
+option(LLVM_BUILD_TOOLS
+  "Build the LLVM tools. If OFF, just generate build targets." ON)
+option(LLVM_INCLUDE_TOOLS "Generate build targets for the LLVM tools." ON)
+if( LLVM_INCLUDE_TOOLS )
+  add_subdirectory(tools)
+endif()
 
-option(LLVM_BUILD_TESTS "Build LLVM unit tests." OFF)
-add_subdirectory(test)
-add_subdirectory(utils/unittest)
-add_subdirectory(unittests)
+option(LLVM_BUILD_EXAMPLES
+  "Build the LLVM example programs. If OFF, just generate build targets." OFF)
+option(LLVM_INCLUDE_EXAMPLES "Generate build targets for the LLVM examples" ON)
+if( LLVM_INCLUDE_EXAMPLES )
+  add_subdirectory(examples)
+endif()
 
+option(LLVM_BUILD_TESTS
+  "Build LLVM unit tests. If OFF, just generate build targes." OFF)
+option(LLVM_INCLUDE_TESTS "Generate build targets for the LLVM unit tests." ON)
+if( LLVM_INCLUDE_TESTS )
+  add_subdirectory(test)
+  add_subdirectory(utils/unittest)
+  add_subdirectory(unittests)
+endif()
 
 add_subdirectory(cmake/modules)