Move DataTypes.h to include/llvm/System, update all users. This breaks the last
[oota-llvm.git] / Makefile
index 03ab0446522a55dff64c73aa62b687fb16474cce..001d2ad1895e3c10fd1548fb8470ff30d91facf9 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -19,6 +19,12 @@ LEVEL := .
 #
 # When cross-compiling, there are some things (tablegen) that need to
 # be build for the build system first.
+
+# If "RC_ProjectName" exists in the environment, and its value is
+# "llvmCore", then this is an "Apple-style" build; search for
+# "Apple-style" in the comments for more info.  Anything else is a
+# normal build.
+ifneq ($(RC_ProjectName),llvmCore)  # Normal build (not "Apple-style").
 ifeq ($(BUILD_DIRS_ONLY),1)
   DIRS := lib/System lib/Support utils
   OPTIONAL_DIRS :=
@@ -62,7 +68,7 @@ ifeq ($(MAKECMDGOALS),install-clang)
 endif
 
 ifeq ($(MAKECMDGOALS),clang-only)
-  DIRS := $(filter-out tools runtime docs, $(DIRS)) tools/clang
+  DIRS := $(filter-out tools runtime docs unittests, $(DIRS)) tools/clang
   OPTIONAL_DIRS :=
 endif
 
@@ -127,8 +133,7 @@ dist-hook::
        $(Echo) Eliminating files constructed by configure
        $(Verb) $(RM) -f \
          $(TopDistDir)/include/llvm/Config/config.h  \
-         $(TopDistDir)/include/llvm/Support/DataTypes.h  \
-         $(TopDistDir)/include/llvm/Support/ThreadSupport.h
+         $(TopDistDir)/include/llvm/System/DataTypes.h
 
 clang-only: all
 tools-only: all
@@ -144,7 +149,8 @@ FilesToConfig := \
   include/llvm/Config/config.h \
   include/llvm/Config/Targets.def \
        include/llvm/Config/AsmPrinters.def \
-  include/llvm/Support/DataTypes.h
+  include/llvm/System/DataTypes.h \
+       tools/llvmc/plugins/Base/Base.td
 FilesToConfigPATH  := $(addprefix $(LLVM_OBJ_ROOT)/,$(FilesToConfig))
 
 all-local:: $(FilesToConfigPATH)
@@ -210,3 +216,9 @@ happiness: update all check unittests
 
 .NOTPARALLEL:
 
+else # Building "Apple-style."
+# In an Apple-style build, once configuration is done, lines marked
+# "Apple-style" are removed with sed!  Please don't remove these!
+# Look for the string "Apple-style" in utils/buildit/build_llvm.
+include $(shell find . -name GNUmakefile) # Building "Apple-style."
+endif # Building "Apple-style."