From 3fc89584721bd2b750fb79e3a9bed44ada946eb7 Mon Sep 17 00:00:00 2001 From: Kalev Lember Date: Fri, 16 Mar 2012 23:01:13 +0200 Subject: [PATCH] Fix warnings during debuginfo generation Commit f3b87dde removed a needed 'shift' from mingw-find-debuginfo.sh, which made debuginfo generation often complain about directories not found. Add the 'shift' back and at the same time improve argument parsing error messages. --- mingw-filesystem.spec | 5 ++++- mingw-find-debuginfo.sh | 8 ++++++-- 2 files changed, 10 insertions(+), 3 deletions(-) diff --git a/mingw-filesystem.spec b/mingw-filesystem.spec index d836f88..2620bd6 100644 --- a/mingw-filesystem.spec +++ b/mingw-filesystem.spec @@ -2,7 +2,7 @@ Name: mingw-filesystem Version: 95 -Release: 5%{?dist} +Release: 6%{?dist} Summary: MinGW cross compiler base filesystem and environment Group: Development/Libraries @@ -250,6 +250,9 @@ install -m 0644 %{SOURCE12} $RPM_BUILD_ROOT%{_datadir}/mingw/ %changelog +* Fri Mar 16 2012 Kalev Lember - 95-6 +- Fix warnings during debuginfo generation + * Fri Mar 16 2012 Kalev Lember - 95-5 - Simplify the mingw_make_install macro, also moving it to the deprecated section diff --git a/mingw-find-debuginfo.sh b/mingw-find-debuginfo.sh index 72d3d60..62c0b13 100755 --- a/mingw-find-debuginfo.sh +++ b/mingw-find-debuginfo.sh @@ -2,10 +2,14 @@ # mingw-find-debuginfo.sh - automagically generate debug info and file list # for inclusion in an rpm spec file for mingw-* packages. -if [ -z "$1" ] ; then BUILDDIR="." -else BUILDDIR=$1 +if [ "$#" -lt 2 ] ; then + echo "Usage: $0 [TARGET]..." + exit 1 fi +BUILDDIR=$1 +shift + for f in `find $RPM_BUILD_ROOT -type f -name "*.exe" -or -name "*.dll"` do case $(mingw-objdump -h $f 2>/dev/null | egrep -o '(debug[\.a-z_]*|gnu.version)') in