From c8d58f8db33360a0610a6dabd29916b4081a73db Mon Sep 17 00:00:00 2001
From: callum_linden <none@none>
Date: Wed, 17 Oct 2012 13:51:53 -0700
Subject: [PATCH] Update script that generates Google Breakpad symbols to look
 in tghe right place first and default to the original location if not found.

---
 indra/newview/generate_breakpad_symbols.py | 9 ++++++++-
 1 file changed, 8 insertions(+), 1 deletion(-)

diff --git a/indra/newview/generate_breakpad_symbols.py b/indra/newview/generate_breakpad_symbols.py
index 5ebec1563e9..ddc8a41136c 100644
--- a/indra/newview/generate_breakpad_symbols.py
+++ b/indra/newview/generate_breakpad_symbols.py
@@ -75,7 +75,14 @@ def list_files():
 
     def dump_module(m):
         print "dumping module '%s' with '%s'..." % (m, dump_syms_tool)
-        child = subprocess.Popen([dump_syms_tool, m] , stdout=subprocess.PIPE)
+        dsym_full_path = m
+        if sys.platform in ['darwin']:
+            dsym_dir=os.path.join(m+".dSYM", 'Contents', 'Resources', 'DWARF')
+            if os.path.isdir(dsym_dir):
+                dsym_full_path=os.path.join(dsym_dir, os.path.basename(m))
+            else:
+                dsym_full_path = m
+        child = subprocess.Popen([dump_syms_tool, dsym_full_path] , stdout=subprocess.PIPE)
         out, err = child.communicate()
         return (m,child.returncode, out, err)
 
-- 
GitLab