[Lldb-commits] [PATCH] D58871: [lldb] [lldbtest] Fix getBuildFlags() not to use libstdc++ on NetBSD

Michał Górny via Phabricator via lldb-commits lldb-commits at lists.llvm.org
Sat Mar 2 02:49:51 PST 2019

mgorny created this revision.
mgorny added reviewers: krytarowski, labath.
Herald added a subscriber: abidh.
Herald added a reviewer: serge-sans-paille.
Herald added a project: LLDB.

Remove the code forcing -stdlib=libstdc++ on NetBSD in getBuildFlags()
method.  NetBSD uses libc++ everywhere else, and using libstdc++ here
causes lang/cpp/dynamic-value to fail to build.

NB: I have no clue what `getBuildFlags()` is supposed to do, and why it's used in the few tests it's used in, so the change can be entirely wrong. However, tests pass for me with it, and it fixes missing symbols I've had when building with libstdc++.




Index: lldb/packages/Python/lldbsuite/test/lldbtest.py
--- lldb/packages/Python/lldbsuite/test/lldbtest.py
+++ lldb/packages/Python/lldbsuite/test/lldbtest.py
@@ -1666,7 +1666,8 @@
         elif self.getPlatform() == "openbsd":
             cflags += " -stdlib=libc++"
         elif self.getPlatform() == "netbsd":
-            cflags += " -stdlib=libstdc++"
+            # NetBSD defaults to libc++
+            pass
         elif "clang" in self.getCompiler():
             cflags += " -stdlib=libstdc++"

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D58871.189040.patch
Type: text/x-patch
Size: 577 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/lldb-commits/attachments/20190302/8f6ae9d1/attachment.bin>

More information about the lldb-commits mailing list