[Lldb-commits] [lldb] r133459 - /lldb/trunk/source/Interpreter/Makefile

Peter Collingbourne peter at pcc.me.uk
Mon Jun 20 12:06:35 PDT 2011


Author: pcc
Date: Mon Jun 20 14:06:35 2011
New Revision: 133459

URL: http://llvm.org/viewvc/llvm-project?rev=133459&view=rev
Log:
Create a _lldb.so symlink in the bin directory

This is required to run the test suite without installing.

Modified:
    lldb/trunk/source/Interpreter/Makefile

Modified: lldb/trunk/source/Interpreter/Makefile
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Interpreter/Makefile?rev=133459&r1=133458&r2=133459&view=diff
==============================================================================
--- lldb/trunk/source/Interpreter/Makefile (original)
+++ lldb/trunk/source/Interpreter/Makefile Mon Jun 20 14:06:35 2011
@@ -16,15 +16,15 @@
 include $(LLDB_LEVEL)/Makefile
 
 LLDB_PYTHON_SWIG_CPP = $(PROJ_OBJ_ROOT)/$(BuildMode)/LLDBWrapPython.cpp
-LLDB_BIN_DIR := $(PROJ_OBJ_ROOT)/$(BuildMode)/bin
-PYTHON_DIR := $(LLDB_BIN_DIR)
+PYTHON_DIR := $(ToolDir)
 ifeq ($(HOST_OS),Darwin)
 PYTHON_DEST_DIR := /Library/Python/$(shell python -c 'import sys; print sys.version[:3]')/site-packages
 else
 PYTHON_DEST_DIR := $(shell python -c 'import sys; print sys.exec_prefix')/lib/python$(shell python -c 'import sys; print sys.version[:3]')/site-packages
 endif
 LLDB_SWIG_INCLUDE_DIRS:= -I"$(PROJ_SRC_DIR)/$(LLDB_LEVEL)/include" -I./.
-LIBLLDB := $(DESTDIR)$(PROJ_libdir)/liblldb$(SHLIBEXT)
+LIBLLDB := $(LibDir)/liblldb$(SHLIBEXT)
+DEST_LIBLLDB := $(DESTDIR)$(PROJ_libdir)/liblldb$(SHLIBEXT)
 
 # We need Swig to process stdint.h, but by default it will not inspect system
 # include directories.  The following should cover the standard locations on
@@ -35,21 +35,23 @@
 LLDBWrapPython.cpp:
 	$(Echo) Generating LLDBWrapPython.cpp
 	$(Verb) swig -c++ -shadow -python $(LLDB_SWIG_INCLUDE_DIRS) \
-          -D__STDC_LIMIT_MACROS -outdir "$(LLDB_BIN_DIR)"   \
+          -D__STDC_LIMIT_MACROS -outdir "$(PYTHON_DIR)"   \
           -o LLDBWrapPython.cpp "$(PROJ_SRC_DIR)/$(LLDB_LEVEL)/scripts/lldb.swig"
 	$(Verb) python "$(PROJ_SRC_DIR)/$(LLDB_LEVEL)/scripts/Python/modify-python-lldb.py" \
-		  "$(LLDB_BIN_DIR)"
+		  "$(PYTHON_DIR)"
 	$(Verb) python "$(PROJ_SRC_DIR)/$(LLDB_LEVEL)/scripts/Python/edit-swig-python-wrapper-file.py" \
 		  "$(PROJ_OBJ_DIR)"
 	$(Verb) if test -f "$(PROJ_OBJ_DIR)/LLDBWrapPython.cpp.edited"; then \
 		  mv "$(PROJ_OBJ_DIR)/LLDBWrapPython.cpp.edited" \
 			 "$(PROJ_OBJ_DIR)/LLDBWrapPython.cpp"; fi
 	$(Verb) cp "$(PROJ_SRC_DIR)/embedded_interpreter.py" "$(PYTHON_DIR)"
+	$(Verb) $(RM) -f $(PYTHON_DIR)/_lldb.so
+	$(Verb) $(AliasTool) $(LIBLLDB) $(PYTHON_DIR)/_lldb.so
 
-install-local:: $(PYTHON_DIR)/lldb.py $(PYTHON_DIR)/embedded_interpreter.py $(LIBLLDB)
+install-local:: $(PYTHON_DIR)/lldb.py $(PYTHON_DIR)/embedded_interpreter.py $(DEST_LIBLLDB)
 	$(Echo) Installing $(BuildMode) LLDB python modules
 	$(Verb) $(MKDIR) $(PYTHON_DEST_DIR)/lib-dynload
 	$(Verb) $(DataInstall) $(PYTHON_DIR)/lldb.py $(PYTHON_DEST_DIR)/lldb.py
 	$(Verb) $(DataInstall) $(PYTHON_DIR)/embedded_interpreter.py $(PYTHON_DEST_DIR)/embedded_interpreter.py
 	$(Verb) $(RM) -f $(PYTHON_DEST_DIR)/lib-dynload/_lldb.so
-	$(Verb) $(AliasTool) $(LIBLLDB) $(PYTHON_DEST_DIR)/lib-dynload/_lldb.so
+	$(Verb) $(AliasTool) $(DEST_LIBLLDB) $(PYTHON_DEST_DIR)/lib-dynload/_lldb.so





More information about the lldb-commits mailing list