[Lldb-commits] [lldb] r253153 - Add more autotools/gmake NetBSD glue

Bruce Mitchener via lldb-commits lldb-commits at lists.llvm.org
Sat Nov 14 18:00:09 PST 2015


Author: brucem
Date: Sat Nov 14 20:00:09 2015
New Revision: 253153

URL: http://llvm.org/viewvc/llvm-project?rev=253153&view=rev
Log:
Add more autotools/gmake NetBSD glue

Summary: This diff approaches building the project natively on NetBSD with the autoconf/gmake framework.

Patch by Kamil Rytarowski. Thanks!

Reviewers: emaste, clayborg

Subscribers: tberghammer, joerg, brucem, lldb-commits

Differential Revision: http://reviews.llvm.org/D14531

Modified:
    lldb/trunk/lib/Makefile
    lldb/trunk/tools/driver/Makefile
    lldb/trunk/tools/lldb-mi/Makefile
    lldb/trunk/tools/lldb-server/Makefile

Modified: lldb/trunk/lib/Makefile
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/lib/Makefile?rev=253153&r1=253152&r2=253153&view=diff
==============================================================================
--- lldb/trunk/lib/Makefile (original)
+++ lldb/trunk/lib/Makefile Sat Nov 14 20:00:09 2015
@@ -204,3 +204,14 @@ ifeq ($(HOST_OS),FreeBSD)
     LLVMLibsOptions += $(PYTHON_BUILD_FLAGS) -lrt -L/usr/local/lib -lexecinfo \
                        -ledit -lncurses -lpanel -lpthread
 endif
+
+ifeq ($(HOST_OS),NetBSD)
+    # Include everything from the .a's into the shared library.
+    ProjLibsOptions := -Wl,--whole-archive $(ProjLibsOptions) \
+                       -Wl,--no-whole-archive
+    # Allow unresolved symbols.
+    LLVMLibsOptions += -Wl,--allow-shlib-undefined
+    # Link in python
+    LLVMLibsOptions += $(PYTHON_BUILD_FLAGS) -lrt -L/usr/pkg/lib -lexecinfo \
+                       -ledit -lcurses -lpthread -lkvm -Wl,-rpath,/usr/pkg/lib
+endif

Modified: lldb/trunk/tools/driver/Makefile
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/tools/driver/Makefile?rev=253153&r1=253152&r2=253153&view=diff
==============================================================================
--- lldb/trunk/tools/driver/Makefile (original)
+++ lldb/trunk/tools/driver/Makefile Sat Nov 14 20:00:09 2015
@@ -26,7 +26,7 @@ ifeq ($(HOST_OS),Darwin)
 	LLVMLibsOptions += -Wl,-sectcreate -Wl,__TEXT -Wl,__info_plist -Wl,"$(PROJ_SRC_DIR)/lldb-Info.plist"
 endif
 
-ifneq (,$(filter $(HOST_OS), Linux GNU/kFreeBSD))
+ifneq (,$(filter $(HOST_OS), Linux GNU/kFreeBSD NetBSD))
 	LLVMLibsOptions += -Wl,-rpath,$(LibDir)
 endif
 
@@ -34,4 +34,3 @@ ifeq ($(HOST_OS),FreeBSD)
 	CPP.Flags += -I/usr/include/edit #-v
 	LLVMLibsOptions += -Wl,-rpath,$(LibDir)
 endif
-

Modified: lldb/trunk/tools/lldb-mi/Makefile
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/tools/lldb-mi/Makefile?rev=253153&r1=253152&r2=253153&view=diff
==============================================================================
--- lldb/trunk/tools/lldb-mi/Makefile (original)
+++ lldb/trunk/tools/lldb-mi/Makefile Sat Nov 14 20:00:09 2015
@@ -22,7 +22,7 @@ ifeq ($(HOST_OS),Darwin)
 	LLVMLibsOptions += -Wl,-sectcreate -Wl,__TEXT -Wl,__info_plist -Wl,"$(PROJ_SRC_DIR)/lldb-Info.plist"
 endif
 
-ifneq (,$(filter $(HOST_OS), Linux GNU/kFreeBSD))
+ifneq (,$(filter $(HOST_OS), Linux GNU/kFreeBSD NetBSD))
 	LLVMLibsOptions += -Wl,-rpath,$(LibDir) -lpthread
 endif
 
@@ -30,4 +30,3 @@ ifeq ($(HOST_OS),FreeBSD)
 	CPP.Flags += -I/usr/include/edit #-v
 	LLVMLibsOptions += -Wl,-rpath,$(LibDir) -lpthread
 endif
-

Modified: lldb/trunk/tools/lldb-server/Makefile
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/tools/lldb-server/Makefile?rev=253153&r1=253152&r2=253153&view=diff
==============================================================================
--- lldb/trunk/tools/lldb-server/Makefile (original)
+++ lldb/trunk/tools/lldb-server/Makefile Sat Nov 14 20:00:09 2015
@@ -20,6 +20,6 @@ ifeq ($(HOST_OS),Darwin)
 	LLVMLibsOptions += -Wl,-rpath, at loader_path/../lib/
 endif
 
-ifeq ($(HOST_OS), $(filter $(HOST_OS), Linux FreeBSD GNU/kFreeBSD))
+ifeq ($(HOST_OS), $(filter $(HOST_OS), Linux FreeBSD GNU/kFreeBSD NetBSD))
 	LLVMLibsOptions += -Wl,-rpath,$(LibDir) -lpthread
 endif




More information about the lldb-commits mailing list