python-config in Makefiles
Replace python static settings of compiler flags with invocation of
python-config.
Signed-off-by: Johnny Chen <johnny.chen@apple.com>
git-svn-id: https://llvm.org/svn/llvm-project/llvdb/trunk@131697 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/Makefile b/Makefile
index fc090a8..bd22515 100644
--- a/Makefile
+++ b/Makefile
@@ -29,14 +29,14 @@
include $(LEVEL)/Makefile.common
# Set Python include directory
-PYTHON_INC_DIR = /usr/include/python2.7
+PYTHON_INC_DIR = $(shell python-config --includes)
# Set common LLDB build flags.
CPP.Flags += -I$(PROJ_SRC_DIR)/$(LLDB_LEVEL)/include
CPP.Flags += -I$(PROJ_OBJ_DIR)/$(LLDB_LEVEL)/include
CPP.Flags += -I$(PROJ_SRC_DIR)/$(LLDB_LEVEL)/../clang/include
CPP.Flags += -I$(PROJ_OBJ_DIR)/$(LLDB_LEVEL)/../clang/include
-CPP.Flags += -I$(PYTHON_INC_DIR)
+CPP.Flags += $(PYTHON_INC_DIR)
CPP.Flags += -I$(PROJ_SRC_DIR)/$(LLDB_LEVEL)/source
CPP.Flags += -I$(PROJ_SRC_DIR)/$(LLDB_LEVEL)/source/Utility
CPP.Flags += -I$(PROJ_SRC_DIR)/$(LLDB_LEVEL)/source/Plugins/Process/Utility