зеркало из https://github.com/mozilla/pjs.git
backout patch for bug 378463 due to bustage
This commit is contained in:
Родитель
aef474d2ac
Коммит
a11d15c226
34
Makefile.in
34
Makefile.in
|
@ -134,39 +134,16 @@ ifdef MOZ_PROFILE
|
|||
/bin/find $(DIST) -name "*.dbg" -exec mv {} $(DIST)/$(BUILDID) \;
|
||||
endif # MOZ_PROFILE
|
||||
endif # MOZILLA_OFFICIAL
|
||||
endif # WINNT
|
||||
|
||||
ifeq ($(OS_ARCH),WINNT)
|
||||
SYM_FIND_CMD := /bin/find . -path dist -prune -o -name "*.exe" \
|
||||
-o -name "*.dll" -o -name "*.EXE" | sed "s/\.[^\.]*$$/\.pdb/"
|
||||
# we want to copy PDB files on Windows
|
||||
MAKE_SYM_STORE_ARGS := -c
|
||||
DUMP_SYMS_BIN := $(topsrcdir)/toolkit/airbag/tools/win32/dump_syms.exe
|
||||
endif
|
||||
ifeq ($(OS_ARCH),Darwin)
|
||||
# need to pass arch flags for universal builds
|
||||
ifdef UNIVERSAL_BINARY
|
||||
MAKE_SYM_STORE_ARGS := -a "ppc i386"
|
||||
SYM_DIST := $(DIST)/universal
|
||||
else
|
||||
MAKE_SYM_STORE_ARGS := -a $(OS_TEST)
|
||||
SYM_DIST := $(DIST)
|
||||
endif
|
||||
# |file| is stupid on universal binaries, it produces one line of output
|
||||
# for the file, and one line of output for each architecture contained within.
|
||||
SYM_FIND_CMD := find -L $(SYM_DIST) -type f -a -perm -100 -o -name "*.dylib" \
|
||||
| xargs file -L | grep "Mach-O" | grep -v "for architecture" | cut -f1 -d':'
|
||||
DUMP_SYMS_BIN := $(DIST)/host/bin/dump_syms
|
||||
endif
|
||||
|
||||
buildsymbols:
|
||||
ifdef MOZ_DEBUG_SYMBOLS
|
||||
ifdef MOZ_AIRBAG
|
||||
echo building symbol store
|
||||
mkdir -p $(DIST)/crashreporter-symbols/$(BUILDID)
|
||||
$(SYM_FIND_CMD) | \
|
||||
xargs $(topsrcdir)/toolkit/airbag/tools/make_symbol_store.pl \
|
||||
$(MAKE_SYM_STORE_ARGS) $(DUMP_SYMS_BIN) \
|
||||
/bin/find . -path "./dist" -prune -o -name "*.exe" \
|
||||
-o -name "*.dll" -o -name "*.EXE" | sed "s/\.[^\.]*$$/\.pdb/" | \
|
||||
xargs $(topsrcdir)/toolkit/airbag/tools/make_symbol_store.pl -c \
|
||||
$(topsrcdir)/toolkit/airbag/tools/win32/dump_syms.exe \
|
||||
$(DIST)/crashreporter-symbols/$(BUILDID) > \
|
||||
$(DIST)/crashreporter-symbols/$(BUILDID)/$(MOZ_APP_NAME)-$(MOZ_APP_VERSION)-$(OS_ARCH)-$(BUILDID)-symbols.txt
|
||||
echo packing symbols
|
||||
|
@ -185,7 +162,6 @@ ifdef MOZ_AIRBAG
|
|||
endif
|
||||
endif
|
||||
|
||||
ifeq ($(OS_ARCH),WINNT)
|
||||
signnss:
|
||||
ifdef MOZILLA_OFFICIAL
|
||||
echo signing NSS libs
|
||||
|
@ -193,8 +169,8 @@ ifdef MOZILLA_OFFICIAL
|
|||
cd $(DIST)/bin; ./shlibsign.exe -v -i freebl3.dll
|
||||
endif # MOZILLA_OFFICIAL
|
||||
|
||||
BUILDID = $(shell cat $(DEPTH)/config/build_number)
|
||||
deliver: splitsymbols rebase signnss
|
||||
|
||||
endif # WINNT
|
||||
|
||||
BUILDID = $(shell cat $(DEPTH)/config/build_number)
|
||||
|
|
|
@ -86,9 +86,9 @@ postflight_all:
|
|||
# a universal binary too early, before the unified bits have been staged.
|
||||
# Set SIGN_NSS= to skip shlibsign.
|
||||
$(MAKE) -C $(OBJDIR_PPC)/$(INSTALLER_DIR) \
|
||||
UNIVERSAL_BINARY= SIGN_NSS= PKG_SKIP_STRIP=1 stage-package
|
||||
UNIVERSAL_BINARY= SIGN_NSS= stage-package
|
||||
$(MAKE) -C $(OBJDIR_X86)/$(INSTALLER_DIR) \
|
||||
UNIVERSAL_BINARY= SIGN_NSS= PKG_SKIP_STRIP=1 stage-package
|
||||
UNIVERSAL_BINARY= SIGN_NSS= stage-package
|
||||
# Remove .chk files that may have been copied from the NSS build. These will
|
||||
# cause unify to warn or fail if present. New .chk files that are
|
||||
# appropriate for the merged libraries will be generated when the universal
|
||||
|
|
|
@ -61,12 +61,9 @@ ifeq ($(OS_ARCH),WINNT)
|
|||
endif
|
||||
|
||||
ifeq ($(OS_ARCH),Darwin)
|
||||
DIRS += \
|
||||
airbag/src/common/ \
|
||||
airbag/src/common/mac \
|
||||
airbag/src/client/mac/handler \
|
||||
airbag/src/tools/mac/dump_syms \
|
||||
$(NULL)
|
||||
DIRS += airbag/src/common/mac \
|
||||
airbag/src/client/mac/handler \
|
||||
$(NULL)
|
||||
endif
|
||||
|
||||
DIRS += client
|
||||
|
|
|
@ -1,65 +0,0 @@
|
|||
# ***** BEGIN LICENSE BLOCK *****
|
||||
# Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
#
|
||||
# The contents of this file are subject to the Mozilla Public License Version
|
||||
# 1.1 (the "License"); you may not use this file except in compliance with
|
||||
# the License. You may obtain a copy of the License at
|
||||
# http://www.mozilla.org/MPL/
|
||||
#
|
||||
# Software distributed under the License is distributed on an "AS IS" basis,
|
||||
# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
|
||||
# for the specific language governing rights and limitations under the
|
||||
# License.
|
||||
#
|
||||
# The Original Code is Mozilla Breakpad integration
|
||||
#
|
||||
# The Initial Developer of the Original Code is
|
||||
# Ted Mielczarek <ted.mielczarek@gmail.com>
|
||||
# Portions created by the Initial Developer are Copyright (C) 2007
|
||||
# the Initial Developer. All Rights Reserved.
|
||||
#
|
||||
# Contributor(s):
|
||||
#
|
||||
# Alternatively, the contents of this file may be used under the terms of
|
||||
# either the GNU General Public License Version 2 or later (the "GPL"), or
|
||||
# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
|
||||
# in which case the provisions of the GPL or the LGPL are applicable instead
|
||||
# of those above. If you wish to allow use of your version of this file only
|
||||
# under the terms of either the GPL or the LGPL, and not to allow others to
|
||||
# use your version of this file under the terms of the MPL, indicate your
|
||||
# decision by deleting the provisions above and replace them with the notice
|
||||
# and other provisions required by the GPL or the LGPL. If you do not delete
|
||||
# the provisions above, a recipient may use your version of this file under
|
||||
# the terms of any one of the MPL, the GPL or the LGPL.
|
||||
#
|
||||
# ***** END LICENSE BLOCK *****
|
||||
|
||||
DEPTH = ../../../../..
|
||||
topsrcdir = @top_srcdir@
|
||||
srcdir = @srcdir@
|
||||
VPATH = @srcdir@
|
||||
|
||||
include $(DEPTH)/config/autoconf.mk
|
||||
|
||||
MODULE = breakpad_common
|
||||
LIBRARY_NAME = breakpad_common_s
|
||||
HOST_LIBRARY_NAME = host_breakpad_common_s
|
||||
|
||||
LOCAL_INCLUDES = -I$(srcdir)/..
|
||||
|
||||
CPPSRCS = \
|
||||
string_conversion.cc \
|
||||
$(NULL)
|
||||
|
||||
CSRCS = \
|
||||
convert_UTF.c \
|
||||
$(NULL)
|
||||
|
||||
HOST_CPPSRCS = $(CPPSRCS)
|
||||
|
||||
HOST_CSRCS = $(CSRCS)
|
||||
|
||||
# need static lib
|
||||
FORCE_STATIC_LIB = 1
|
||||
|
||||
include $(topsrcdir)/config/rules.mk
|
|
@ -43,29 +43,24 @@ include $(DEPTH)/config/autoconf.mk
|
|||
|
||||
MODULE = breakpad_mac_common
|
||||
LIBRARY_NAME = breakpad_mac_common_s
|
||||
HOST_LIBRARY_NAME = host_breakpad_mac_common_s
|
||||
|
||||
LOCAL_INCLUDES = -I$(srcdir)/../..
|
||||
|
||||
# This is a little weird, but we're building a host and a target lib here.
|
||||
# The host lib is used for dump_syms, and the target lib for the
|
||||
# crash reporter client. Therefore, we don't need all the srcs in both.
|
||||
CPPSRCS = \
|
||||
file_id.cc \
|
||||
macho_id.cc \
|
||||
macho_walker.cc \
|
||||
string_utilities.cc \
|
||||
$(NULL)
|
||||
CPPSRCS = \
|
||||
file_id.cc \
|
||||
macho_id.cc \
|
||||
macho_walker.cc \
|
||||
string_utilities.cc \
|
||||
../string_conversion.cc \
|
||||
$(NULL)
|
||||
|
||||
CMSRCS = \
|
||||
HTTPMultipartUpload.m \
|
||||
$(NULL)
|
||||
CMSRCS = \
|
||||
HTTPMultipartUpload.m \
|
||||
$(NULL)
|
||||
|
||||
HOST_CPPSRCS = $(CPPSRCS)
|
||||
CSRCS = \
|
||||
../convert_UTF.c
|
||||
|
||||
HOST_CMMSRCS = \
|
||||
dump_syms.mm \
|
||||
$(NULL)
|
||||
|
||||
# need static lib
|
||||
FORCE_STATIC_LIB = 1
|
||||
|
|
|
@ -1,68 +0,0 @@
|
|||
# ***** BEGIN LICENSE BLOCK *****
|
||||
# Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
#
|
||||
# The contents of this file are subject to the Mozilla Public License Version
|
||||
# 1.1 (the "License"); you may not use this file except in compliance with
|
||||
# the License. You may obtain a copy of the License at
|
||||
# http://www.mozilla.org/MPL/
|
||||
#
|
||||
# Software distributed under the License is distributed on an "AS IS" basis,
|
||||
# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
|
||||
# for the specific language governing rights and limitations under the
|
||||
# License.
|
||||
#
|
||||
# The Original Code is Mozilla Breakpad integration
|
||||
#
|
||||
# The Initial Developer of the Original Code is
|
||||
# Ted Mielczarek <ted.mielczarek@gmail.com>
|
||||
# Portions created by the Initial Developer are Copyright (C) 2007
|
||||
# the Initial Developer. All Rights Reserved.
|
||||
#
|
||||
# Contributor(s):
|
||||
#
|
||||
# Alternatively, the contents of this file may be used under the terms of
|
||||
# either the GNU General Public License Version 2 or later (the "GPL"), or
|
||||
# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
|
||||
# in which case the provisions of the GPL or the LGPL are applicable instead
|
||||
# of those above. If you wish to allow use of your version of this file only
|
||||
# under the terms of either the GPL or the LGPL, and not to allow others to
|
||||
# use your version of this file under the terms of the MPL, indicate your
|
||||
# decision by deleting the provisions above and replace them with the notice
|
||||
# and other provisions required by the GPL or the LGPL. If you do not delete
|
||||
# the provisions above, a recipient may use your version of this file under
|
||||
# the terms of any one of the MPL, the GPL or the LGPL.
|
||||
#
|
||||
# ***** END LICENSE BLOCK *****
|
||||
|
||||
DEPTH = ../../../../../../..
|
||||
topsrcdir = @top_srcdir@
|
||||
srcdir = @srcdir@
|
||||
VPATH = @srcdir@
|
||||
|
||||
include $(DEPTH)/config/autoconf.mk
|
||||
|
||||
HOST_PROGRAM = dump_syms
|
||||
|
||||
LOCAL_INCLUDES = \
|
||||
-I$(srcdir)/../../.. \
|
||||
-I$(srcdir)/../../../common/mac \
|
||||
$(NULL)
|
||||
|
||||
HOST_CMSRCS = \
|
||||
dump_syms_tool.m \
|
||||
$(NULL)
|
||||
|
||||
HOST_LIBS += \
|
||||
$(DEPTH)/toolkit/airbag/airbag/src/common/mac/$(LIB_PREFIX)host_breakpad_mac_common_s.$(LIB_SUFFIX) \
|
||||
$(DEPTH)/toolkit/airbag/airbag/src/common/$(LIB_PREFIX)host_breakpad_common_s.$(LIB_SUFFIX) \
|
||||
$(NULL)
|
||||
|
||||
HOST_LDFLAGS += \
|
||||
-framework Foundation \
|
||||
-lcrypto \
|
||||
$(NULL)
|
||||
|
||||
# force C++ linking
|
||||
CPP_PROG_LINK = 1
|
||||
|
||||
include $(topsrcdir)/config/rules.mk
|
|
@ -35,33 +35,27 @@
|
|||
#
|
||||
# ***** END LICENSE BLOCK *****
|
||||
#
|
||||
# Usage: make_symbol_store.pl <params> <dump_syms path> <symbol store path>
|
||||
# <debug info files>
|
||||
# Runs dump_syms on each debug info file specified on the command line,
|
||||
# Usage: make_symbol_store.pl <params> <dump_syms path> <symbol store path> <pdb files>
|
||||
# Runs dump_syms on each pdb file specified on the command line,
|
||||
# then places the resulting symbol file in the proper directory
|
||||
# structure in the symbol store path. Accepts multiple files
|
||||
# structure in the symbol store path. Accepts multiple pdb files
|
||||
# on the command line, so can be called as part of a pipe using
|
||||
# find <dir> | xargs make_symbol_store.pl <dump_syms> <storepath>
|
||||
# find <dir> -name "*.pdb" | xargs make_symbol_store.pl <dump_syms> <storepath>
|
||||
# Parameters accepted:
|
||||
# -c : Copy debug info files to the same directory structure
|
||||
# as sym files
|
||||
# -a "<archs>" : Run dump_syms -a <arch> for each space separated
|
||||
# cpu architecture in <archs> (only on OS X)
|
||||
# -c : Copy pdb files to the same directory structure as sym files
|
||||
|
||||
use FileHandle;
|
||||
use File::Path;
|
||||
use File::Copy;
|
||||
use File::Basename;
|
||||
|
||||
print "Usage: make_symbol_store.pl <params>" .
|
||||
"<dump_syms path> <storepath> <debug info files>\n"
|
||||
and exit if scalar @ARGV < 3;
|
||||
print "Usage: make_symbol_store.pl <dump_syms path> <storepath> <pdb files>>\n" and exit if scalar @ARGV < 3;
|
||||
|
||||
# Given a symbol file generated by dump_syms,
|
||||
# and a directory to store the resulting symbol path,
|
||||
# move the symbol file into the directory structure
|
||||
# expected by the breakpad processor. For details, see:
|
||||
# http://google-breakpad.googlecode.com/svn/trunk/src/processor/simple_symbol_supplier.h
|
||||
# expected by the airbag processor:
|
||||
# file.pdb/GUID+age/file.sym
|
||||
sub rename_symbol_file
|
||||
{
|
||||
my ($symbol_file, $dest_path) = @_;
|
||||
|
@ -69,15 +63,13 @@ sub rename_symbol_file
|
|||
return "" unless $fh;
|
||||
|
||||
my $line = <$fh>;
|
||||
return "" unless $line;
|
||||
$line =~ s/\s*$//;
|
||||
$fh->close();
|
||||
return "" unless $line =~ m/^MODULE/;
|
||||
|
||||
# the first line of a sym file looks like:
|
||||
# MODULE os cpu identifier debug_file
|
||||
my ($guid,$dbgfile) = (split(/ +/, $line))[3..4];
|
||||
my $newpath = $dest_path . "/" . $dbgfile . "/" . $guid;
|
||||
my ($guid,$age,$dbgfile) = (split(/ +/, $line))[1..3];
|
||||
$guid =~ s/\-//g;
|
||||
my $newpath = $dest_path . "/" . $dbgfile . "/" . uc($guid . $age);
|
||||
eval { mkpath($newpath) };
|
||||
return "" if $@;
|
||||
|
||||
|
@ -93,36 +85,24 @@ sub rename_symbol_file
|
|||
return "";
|
||||
}
|
||||
|
||||
my $copy_dbg = 0;
|
||||
my @archs = ('');
|
||||
while (@ARGV && $ARGV[0] =~ m/^-/) {
|
||||
my $arg = shift;
|
||||
if ($arg eq '-c') {
|
||||
$copy_dbg = 1;
|
||||
}
|
||||
elsif ($arg eq '-a') {
|
||||
@archs = (split(/\s+/, shift));
|
||||
}
|
||||
my $copy_pdbs = 0;
|
||||
if($ARGV[0] eq '-c') {
|
||||
$copy_pdbs = 1;
|
||||
shift;
|
||||
}
|
||||
|
||||
my $dump_syms = shift;
|
||||
my $symbol_path = shift;
|
||||
foreach my $dbgfile (@ARGV) {
|
||||
next unless -f $dbgfile;
|
||||
# get filename without path or .pdb extension, if it exists
|
||||
my ($sf) = fileparse($dbgfile, ".pdb");
|
||||
foreach my $pdbfile (@ARGV) {
|
||||
next unless -f $pdbfile;
|
||||
my ($sf) = fileparse($pdbfile, ".pdb");
|
||||
my $symfile = $symbol_path . "/" . $sf . ".sym";
|
||||
foreach my $arch (@archs) {
|
||||
my $a = '';
|
||||
$a = "-a $arch" if $arch ne '';
|
||||
system("${dump_syms} ${a} ${dbgfile} > ${symfile}");
|
||||
my $newpath = rename_symbol_file $symfile, $symbol_path;
|
||||
if ($copy_dbg && $newpath ne "") {
|
||||
system("$dump_syms $pdbfile > $symfile");
|
||||
my $newpath = rename_symbol_file $symfile, $symbol_path;
|
||||
if($copy_pdbs && $newpath ne "") {
|
||||
my $out = $newpath;
|
||||
$out =~ s/^$symbol_path//;
|
||||
$out =~ s|^/||;
|
||||
print "$out/${sf}.pdb\n";
|
||||
copy($dbgfile, $newpath);
|
||||
}
|
||||
copy($pdbfile, $newpath);
|
||||
}
|
||||
}
|
||||
|
|
Двоичные данные
toolkit/airbag/tools/win32/dump_syms.exe
Двоичные данные
toolkit/airbag/tools/win32/dump_syms.exe
Двоичный файл не отображается.
|
@ -200,7 +200,6 @@ endif
|
|||
ifeq ($(OS_ARCH),Darwin)
|
||||
SHARED_LIBRARY_LIBS += \
|
||||
$(DEPTH)/toolkit/airbag/airbag/src/client/mac/handler/$(LIB_PREFIX)exception_handler_s.$(LIB_SUFFIX) \
|
||||
$(DEPTH)/toolkit/airbag/airbag/src/common/$(LIB_PREFIX)breakpad_common_s.$(LIB_SUFFIX) \
|
||||
$(DEPTH)/toolkit/airbag/airbag/src/common/mac/$(LIB_PREFIX)breakpad_mac_common_s.$(LIB_SUFFIX)
|
||||
endif
|
||||
endif
|
||||
|
|
Загрузка…
Ссылка в новой задаче