##===----------------------------------------------------------------------===##
LEVEL := ..
-PARALLEL_DIRS := llvm-as llvm-dis opt gccas llc llvm-link lli gccld llvm-stub \
- analyze llvm-extract llvm-nm llvm-prof llvm-ar llvm-ranlib \
- llvm-bcanalyzer llvmc llvm-ld llvm-db bugpoint
+# Note .. the tools are organized in triples consisting of one large and two
+# small executables. This is done to minimize memory load in parallel builds.
+# Please retain this ordering.
+PARALLEL_DIRS := llvm-config \
+ opt llvm-as llvm-dis \
+ llc llvm-ranlib llvm-ar \
+ lli llvm-link llvm-nm \
+ bugpoint llvm-db llvm-extract \
+ gccas llvm-bcanalyzer llvm-stub \
+ gccld llvm2cpp \
+ llvm-ld llvmc llvm-prof
include $(LEVEL)/Makefile.config
-# The bugpoint and llvm-db tools are not portable to Win32 because they depend
-# on fork(2) behavior that Win32 doesn't have. At some point they'll be
-# rewritten to not depend on fork at which time they should be added back to
-# the list above.
-ifneq ($(LLVM_ON_UNIX),1)
-PARALLEL_DIRS := $(filter-out bugpoint llvm-db,$(PARALLEL_DIRS))
+# Disable liblto on non-darwin platforms right now until LLVM is built PIC.
+ifeq ($(OS), Darwin)
+PARALLEL_DIRS += lto
endif
-include $(LLVM_SRC_ROOT)/Makefile.rules
+include $(LEVEL)/Makefile.common