teknoraver / rpms / rpm

Forked from rpms/rpm 4 months ago
Clone

Blame 0042-Update-find-debuginfo.sh-options-and-macros-document.patch

Igor Gnatenko 082d5d
From 201b856c02aeb3c4fc6b3a8b96ce8817278f4fbf Mon Sep 17 00:00:00 2001
Igor Gnatenko 082d5d
From: Mark Wielaard <mark@klomp.org>
Igor Gnatenko 082d5d
Date: Mon, 26 Jun 2017 13:35:48 +0200
Igor Gnatenko 082d5d
Subject: [PATCH 42/49] Update find-debuginfo.sh options and macros
Igor Gnatenko 082d5d
 documentation.
Mark Wielaard 79f78c
Igor Gnatenko 082d5d
This adds some missing documentation for rpm macros and find-debuginfo.sh
Igor Gnatenko 082d5d
options that were recently added (or renamed). -j N, --build-id-seed SEED,
Igor Gnatenko 082d5d
--unique-debug-suffix SUFFIX and --unique-debug-src-base BASE.
Igor Gnatenko 082d5d
Igor Gnatenko 082d5d
Signed-off-by: Mark Wielaard <mark@klomp.org>
Igor Gnatenko 082d5d
(cherry picked from commit 173e5642a97c535f8bdaac5bf88854a103cc125b)
Igor Gnatenko 082d5d
---
Igor Gnatenko 082d5d
 macros.in                 | 14 ++++++++------
Igor Gnatenko 082d5d
 scripts/find-debuginfo.sh | 28 ++++++++++++++++++++++------
Igor Gnatenko 082d5d
 2 files changed, 30 insertions(+), 12 deletions(-)
Mark Wielaard 79f78c
Mark Wielaard 79f78c
diff --git a/macros.in b/macros.in
Igor Gnatenko 082d5d
index 0c055a7fd..2a114ccd7 100644
Mark Wielaard 79f78c
--- a/macros.in
Mark Wielaard 79f78c
+++ b/macros.in
Igor Gnatenko 082d5d
@@ -514,8 +514,9 @@ package or when debugging this package.\
Mark Wielaard 79f78c
 
Mark Wielaard 79f78c
 # Whether build-ids should be made unique between package version/releases
Mark Wielaard 79f78c
 # when generating debuginfo packages. If set to 1 this will pass
Mark Wielaard 79f78c
-# --ver-rel "%{VERSION}-%{RELEASE}" to find-debuginfo.sh which will pass it
Mark Wielaard 79f78c
-# onto debugedit --build-id-seed to be used to prime the build-id note hash.
Mark Wielaard 79f78c
+# --build-id-seed "%{VERSION}-%{RELEASE}" to find-debuginfo.sh which will
Mark Wielaard 79f78c
+# pass it onto debugedit --build-id-seed to be used to prime the build-id
Mark Wielaard 79f78c
+# note hash.
Mark Wielaard 79f78c
 %_unique_build_ids	1
Mark Wielaard 79f78c
 
Mark Wielaard 79f78c
 # Do not recompute build-ids but keep whatever is in the ELF file already.
Igor Gnatenko 082d5d
@@ -525,15 +526,16 @@ package or when debugging this package.\
Mark Wielaard 79f78c
 
Mark Wielaard 79f78c
 # Whether .debug files should be made unique between package version,
Mark Wielaard 79f78c
 # release and architecture. If set to 1 this will pass
Mark Wielaard 79f78c
-# --unique-debug-arch "%{_arch}" to find-debuginfo.sh to create
Mark Wielaard 79f78c
-# debuginfo files which end in -<ver>-<rel>.<arch>.debug
Mark Wielaard 79f78c
+# --unique-debug-suffix "-%{VERSION}-%{RELEASE}.%{_arch} find-debuginfo.sh
Mark Wielaard 79f78c
+# to create debuginfo files which end in -<ver>-<rel>.<arch>.debug
Mark Wielaard 79f78c
 # Requires _unique_build_ids.
Mark Wielaard 79f78c
 %_unique_debug_names	1
Mark Wielaard 79f78c
 
Mark Wielaard 79f78c
 # Whether the /usr/debug/src/<package> directories should be unique between
Mark Wielaard 79f78c
 # package version, release and architecture. If set to 1 this will pass
Mark Wielaard 79f78c
-# --unique-debug-src-base "%{name}" to find-debuginfo.sh to name the
Mark Wielaard 79f78c
-# directory under /usr/debug/src as <name>-<ver>-<rel>.<arch>
Mark Wielaard 79f78c
+# --unique-debug-src-base "%{name}-%{VERSION}-%{RELEASE}.%{_arch}" to
Mark Wielaard 79f78c
+# find-debuginfo.sh to name the directory under /usr/debug/src as
Mark Wielaard 79f78c
+# <name>-<ver>-<rel>.<arch>.
Mark Wielaard 79f78c
 %_unique_debug_srcs	1
Mark Wielaard 79f78c
 
Mark Wielaard 79f78c
 # Whether rpm should put debug source files into its own subpackage
Mark Wielaard 79f78c
diff --git a/scripts/find-debuginfo.sh b/scripts/find-debuginfo.sh
Igor Gnatenko 082d5d
index 3bfc15a79..185d25f96 100644
Mark Wielaard 79f78c
--- a/scripts/find-debuginfo.sh
Mark Wielaard 79f78c
+++ b/scripts/find-debuginfo.sh
Mark Wielaard 79f78c
@@ -3,11 +3,14 @@
Mark Wielaard 79f78c
 #for inclusion in an rpm spec file.
Mark Wielaard 79f78c
 #
Mark Wielaard 79f78c
 # Usage: find-debuginfo.sh [--strict-build-id] [-g] [-r] [-m] [-i] [-n]
Mark Wielaard 79f78c
+#	 		   [-j N]
Mark Wielaard 79f78c
 #	 		   [-o debugfiles.list]
Mark Wielaard 79f78c
 #	 		   [-S debugsourcefiles.list]
Mark Wielaard 79f78c
 #			   [--run-dwz] [--dwz-low-mem-die-limit N]
Mark Wielaard 79f78c
 #			   [--dwz-max-die-limit N]
Mark Wielaard 79f78c
-#			   [--build-id-seed VERSION-RELEASE]
Mark Wielaard 79f78c
+#			   [--build-id-seed SEED]
Mark Wielaard 79f78c
+#			   [--unique-debug-suffix SUFFIX]
Mark Wielaard 79f78c
+#			   [--unique-debug-src-base BASE]
Mark Wielaard 79f78c
 #			   [[-l filelist]... [-p 'pattern'] -o debuginfo.list]
Mark Wielaard 79f78c
 #			   [builddir]
Mark Wielaard 79f78c
 #
Mark Wielaard 79f78c
@@ -19,6 +22,9 @@
Mark Wielaard 79f78c
 # The -i flag says to include a .gdb_index section in the .debug file.
Mark Wielaard 79f78c
 # The -n flag says to not recompute the build-id.
Mark Wielaard 79f78c
 #
Mark Wielaard 79f78c
+# The -j N option will spawn N processes to do the debuginfo extraction
Mark Wielaard 79f78c
+# in parallel.
Mark Wielaard 79f78c
+#
Mark Wielaard 79f78c
 # A single -o switch before any -l or -p switches simply renames
Mark Wielaard 79f78c
 # the primary output file from debugfiles.list to something else.
Mark Wielaard 79f78c
 # A -o switch that follows a -p switch or some -l switches produces
Mark Wielaard 79f78c
@@ -31,11 +37,21 @@
Mark Wielaard 79f78c
 # if available, and --dwz-low-mem-die-limit and --dwz-max-die-limit
Mark Wielaard 79f78c
 # provide detailed limits.  See dwz(1) -l and -L option for details.
Mark Wielaard 79f78c
 #
Mark Wielaard 79f78c
-# If --build-id-seed VERSION-RELEASE is given then debugedit is called to
Mark Wielaard 79f78c
-# update the build-ids it finds adding the VERSION-RELEASE string as
Mark Wielaard 79f78c
-# seed to recalculate the build-id hash.  This makes sure the
Mark Wielaard 79f78c
-# build-ids in the ELF files are unique between versions and releases
Mark Wielaard 79f78c
-# of the same package.
Mark Wielaard 79f78c
+# If --build-id-seed SEED is given then debugedit is called to
Mark Wielaard 79f78c
+# update the build-ids it finds adding the SEED as seed to recalculate
Mark Wielaard 79f78c
+# the build-id hash.  This makes sure the build-ids in the ELF files
Mark Wielaard 79f78c
+# are unique between versions and releases of the same package.
Mark Wielaard 79f78c
+# (Use --build-id-seed "%{VERSION}-%{RELEASE}".)
Mark Wielaard 79f78c
+#
Mark Wielaard 79f78c
+# If --unique-debug-suffix SUFFIX is given then the debug files created
Mark Wielaard 79f78c
+# for <FILE> will be named <FILE>-<SUFFIX>.debug.  This makes sure .debug
Mark Wielaard 79f78c
+# are unique between package version, release and architecture.
Mark Wielaard 79f78c
+# (Use --unique-debug-suffix "-%{VERSION}-%{RELEASE}.%{_arch}".)
Mark Wielaard 79f78c
+#
Mark Wielaard 79f78c
+# If --unique-debug-src-base BASE is given then the source directory
Mark Wielaard 79f78c
+# will be called /usr/debug/src/<BASE>.  This makes sure the debug source
Mark Wielaard 79f78c
+# directories are unique between package version, release and architecture.
Mark Wielaard 79f78c
+# (Use --unique-debug-src-base "%{name}-%{VERSION}-%{RELEASE}.%{_arch}".)
Mark Wielaard 79f78c
 #
Mark Wielaard 79f78c
 # All file names in switches are relative to builddir (. if not given).
Mark Wielaard 79f78c
 #
Igor Gnatenko 082d5d
-- 
Igor Gnatenko 082d5d
2.13.2
Igor Gnatenko 082d5d