[llvm-commits] CVS: llvm/Makefile.common
John Criswell
criswell at choi.cs.uiuc.edu
Thu Jun 26 16:39:14 PDT 2003
Changes in directory llvm:
Makefile.common updated: 1.88.2.5 -> 1.88.2.6
---
Log message:
Merged with mainline on Thursday, June 26, 2003.
---
Diffs of the changes:
Index: llvm/Makefile.common
diff -u llvm/Makefile.common:1.88.2.5 llvm/Makefile.common:1.88.2.6
--- llvm/Makefile.common:1.88.2.5 Thu Jun 26 10:53:56 2003
+++ llvm/Makefile.common Thu Jun 26 16:33:47 2003
@@ -81,18 +81,24 @@
# Set the source root directory.
#
ifndef BUILD_SRC_ROOT
-BUILD_SRC_ROOT = $(BUILD_SRC_DIR)/$(LEVEL)
+BUILD_SRC_ROOT = $(shell cd $(BUILD_SRC_DIR)/$(LEVEL); pwd)
endif
#
+# Determine the path of the source tree relative from $HOME (the mythical
+# home directory).
+#
+HOME_OBJ_ROOT := $(OBJ_ROOT)/$(patsubst $(HOME)%,%,$(BUILD_SRC_ROOT))
+
+#
# Set the object build directory. Its location depends upon the source path
# and where object files should go.
#
ifndef BUILD_OBJ_DIR
ifeq ($(OBJ_ROOT),.)
-BUILD_OBJ_DIR = $(shell pwd)
+BUILD_OBJ_DIR = $(BUILD_SRC_DIR)
else
-BUILD_OBJ_DIR := $(OBJ_ROOT)$(patsubst $(HOME)%,%,$(shell cd $(BUILD_SRC_DIR); pwd))
+BUILD_OBJ_DIR := $(HOME_OBJ_ROOT)$(patsubst $(BUILD_SRC_ROOT)%,%,$(BUILD_SRC_DIR))
endif
endif
@@ -101,9 +107,9 @@
#
ifndef BUILD_OBJ_ROOT
ifeq ($(OBJ_ROOT),.)
-BUILD_OBJ_ROOT = $(shell cd $(LEVEL); pwd)
+BUILD_OBJ_ROOT = $(BUILD_SRC_ROOT)
else
-BUILD_OBJ_ROOT := $(OBJ_ROOT)$(patsubst $(HOME)%,%,$(shell cd $(LEVEL); pwd))
+BUILD_OBJ_ROOT := $(HOME_OBJ_ROOT)
endif
endif
@@ -141,6 +147,16 @@
# Default rule for test. It ensures everything has a test rule
test::
+
+# Print out the directories used for building
+prdirs::
+ echo "Home Offset : " $(HOME_OBJ_ROOT);
+ echo "Build Source Root: " $(BUILD_SRC_ROOT);
+ echo "Build Source Dir : " $(BUILD_SRC_DIR);
+ echo "Build Object Root: " $(BUILD_OBJ_ROOT);
+ echo "Build Object Dir : " $(BUILD_OBJ_DIR);
+ echo "LLVM Source Root: " $(LLVM_SRC_ROOT);
+ echo "LLVM Object Root: " $(LLVM_OBJ_ROOT);
###########################################################################
# Miscellaneous paths and commands:
More information about the llvm-commits
mailing list