[Lldb-commits] [PATCH] D146714: [lldb] Explicitly set libcxx paths when USE_SYSTEM_LIBCXX is provided
    Felipe de Azevedo Piovezan via Phabricator via lldb-commits 
    lldb-commits at lists.llvm.org
       
    Thu Mar 23 08:49:00 PDT 2023
    
    
  
fdeazeve updated this revision to Diff 507756.
fdeazeve added a comment.
Improve error message
Repository:
  rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D146714/new/
https://reviews.llvm.org/D146714
Files:
  lldb/packages/Python/lldbsuite/test/make/Makefile.rules
Index: lldb/packages/Python/lldbsuite/test/make/Makefile.rules
===================================================================
--- lldb/packages/Python/lldbsuite/test/make/Makefile.rules
+++ lldb/packages/Python/lldbsuite/test/make/Makefile.rules
@@ -428,6 +428,16 @@
 	endif
 endif
 
+ifeq (1, $(USE_SYSTEM_STDLIB))
+    ifeq "$(OS)" "Darwin"
+        ifeq "$(SDKROOT)" ""
+             $(error "SDKROOT must be set on Darwin to use the system liccxx")
+        endif
+        CXXFLAGS += -nostdlib++ -nostdinc++ -cxx-isystem $(SDKROOT)/usr/include/c++/v1
+        LDFLAGS += -L$(SDKROOT)/usr/lib -Wl,-rpath,$(SDKROOT)/usr/lib -lc++
+    endif
+endif
+
 # If no explicit request was made, but we have paths to a custom libcxx, use
 # them.
 ifeq ($(or $(USE_LIBSTDCPP), $(USE_LIBCPP), $(USE_SYSTEM_STDLIB)),)
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D146714.507756.patch
Type: text/x-patch
Size: 814 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/lldb-commits/attachments/20230323/e80a3777/attachment-0001.bin>
    
    
More information about the lldb-commits
mailing list