From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mx2.suse.de (mx2.suse.de [195.135.220.15]) by sourceware.org (Postfix) with ESMTPS id 03E2A385701F for ; Tue, 23 Mar 2021 14:09:05 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.3.2 sourceware.org 03E2A385701F Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=suse.cz Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=mliska@suse.cz X-Virus-Scanned: by amavisd-new at test-mx.suse.de Received: from relay2.suse.de (unknown [195.135.221.27]) by mx2.suse.de (Postfix) with ESMTP id 1D474ACBF for ; Tue, 23 Mar 2021 14:09:04 +0000 (UTC) From: =?UTF-8?Q?Martin_Li=c5=a1ka?= Subject: [PATCH] Add --dwz-single-file-mode argument for find-debuginfo.sh. To: debugedit@sourceware.org Message-ID: <1bab6d9a-67d3-3ec1-af8e-d002cd1508d4@suse.cz> Date: Tue, 23 Mar 2021 15:09:03 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.8.1 MIME-Version: 1.0 Content-Type: text/plain; charset=windows-1252; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-11.2 required=5.0 tests=BAYES_00, GIT_PATCH_0, KAM_DMARC_STATUS, RCVD_IN_MSPIKE_H3, RCVD_IN_MSPIKE_WL, SPF_HELO_NONE, SPF_PASS, TXREP autolearn=ham autolearn_force=no version=3.4.2 X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on server2.sourceware.org X-BeenThere: debugedit@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: debugedit development mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 23 Mar 2021 14:09:06 -0000 Sometime it's handy to disable multi-file mode and the patch adds option for that: --dwz-single-file-mode. It will be used in openSUSE for packages that use baselibs.conf mechanism. The patch was already approved in rpm pull request: https://github.com/rpm-software-management/rpm/pull/1579 Signed-off-by: Martin Liska --- scripts/find-debuginfo.sh | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/scripts/find-debuginfo.sh b/scripts/find-debuginfo.sh index 675b8cf..63f7e28 100755 --- a/scripts/find-debuginfo.sh +++ b/scripts/find-debuginfo.sh @@ -25,6 +25,7 @@ # [-S debugsourcefiles.list] # [--run-dwz] [--dwz-low-mem-die-limit N] # [--dwz-max-die-limit N] +# [--dwz-single-file-mode] # [--build-id-seed SEED] # [--unique-debug-suffix SUFFIX] # [--unique-debug-src-base BASE] @@ -60,6 +61,8 @@ # The --run-dwz flag instructs find-debuginfo.sh to run the dwz utility # if available, and --dwz-low-mem-die-limit and --dwz-max-die-limit # provide detailed limits. See dwz(1) -l and -L option for details. +# Use --dwz-single-file-mode to disable multi-file mode, see -m +# for more details. # # If --build-id-seed SEED is given then debugedit is called to # update the build-ids it finds adding the SEED as seed to recalculate @@ -111,6 +114,7 @@ no_recompute_build_id=false run_dwz=false dwz_low_mem_die_limit= dwz_max_die_limit= +dwz_single_file_mode=false # build id seed given by the --build-id-seed option build_id_seed= @@ -144,6 +148,9 @@ while [ $# -gt 0 ]; do dwz_max_die_limit=$2 shift ;; + --dwz-single-file-mode) + dwz_single_file_mode=true + ;; --build-id-seed) build_id_seed=$2 shift @@ -538,7 +545,7 @@ if $run_dwz \ done dwz_multifile_name="${dwz_multifile_name}${dwz_multifile_suffix}" dwz_opts="-h -q -r" - [ ${#dwz_files[@]} -gt 1 ] \ + [ ${#dwz_files[@]} -gt 1 ] && [ "$dwz_single_file_mode" = "false" ] \ && dwz_opts="${dwz_opts} -m .dwz/${dwz_multifile_name}" mkdir -p "${RPM_BUILD_ROOT}/usr/lib/debug/.dwz" [ -n "${dwz_low_mem_die_limit}" ] \ -- 2.30.2