diff options
-rwxr-xr-x | dh_strip | 7 | ||||
-rwxr-xr-x | t/size.t | 2 |
2 files changed, 8 insertions, 1 deletions
@@ -374,6 +374,13 @@ sub process_packages { doit($strip, '--strip-debug', '--remove-section=.comment', '--remove-section=.note', '--enable-deterministic-archives', $_); } + if (-d "$tmp/usr/lib/debug/.dwz" and ($use_build_id > 1 or $dh{DEBUGPACKAGE})) { + my @files = glob_expand(["$tmp/usr/lib/debug/.dwz"], \&glob_expand_error_handler_reject, '*'); + install_dir("$debugtmp/usr/lib/debug/.dwz"); + xargs(\@files, 'cp', '--reflink=auto', "-a", XARGS_INSERT_PARAMS_HERE, "$debugtmp/usr/lib/debug/.dwz"); + doit('rm', '-fr', "$tmp/usr/lib/debug/.dwz"); + } + if ($no_auto_dbgsym and $use_build_id > 1) { # When DEB_BUILD_OPTIONS contains noautodbgsym, remove the # dbgsym dir and clear the build-ids. @@ -21,7 +21,7 @@ foreach my $file (@progs) { while (<$fd>) { $cutting=1 if /^=/; $cutting=0 if /^=cut/; - next if $cutting || /^(?:=|\s*(?:\#.*)?$)/; + next if $cutting || /^(?:=|\s*(?:\#.*|[}]\s*)?$)/; $lines++; $maxlength=length($_) if length($_) > $maxlength; } |