Git-Url: http://git.frugalware.org/gitweb/gitweb.cgi?p=pacman-g2.git;a=commitdiff;h=6a4b5bfafb6621e8964eb982f793f0b40dc2b91c
commit 6a4b5bfafb6621e8964eb982f793f0b40dc2b91c Author: Michel Hermier <[email protected]> Date: Tue Nov 20 07:42:51 2012 +0100 scripts/makepkg * Transform strip_pkg to an hook of the previously introduced subpkg facility. diff --git a/scripts/makepkg b/scripts/makepkg index bcd1476..d326359 100755 --- a/scripts/makepkg +++ b/scripts/makepkg @@ -588,27 +588,6 @@ create_pkg() fi } -strip_pkg() -{ - local dir="" subpkg="" - if [ "$1" = "$pkgname" ]; then - dir="$startdir/pkg" - else - dir="$startdir/pkg.$1" - subpkg="subpackage " - fi - if [ ! "`check_option NOSTRIP`" -a "$NOSTRIP" = "0" ]; then - msg "Stripping debugging symbols from libraries from $subpkg$1..." - find $dir/{,usr,usr/local,opt/*}/lib -type f -not -name "*.dll" -not -name "*.exe" \ - -exec /usr/bin/strip --strip-debug '{}' \; 2>&1 \ - | grep -v "No such file" | grep -v "format not recognized" - msg "Stripping symbols from binaries from $subpkg$1..." - find $dir/{,usr,usr/local,opt/*}/{bin,sbin} -type f -not -name "*.dll" -not -name "*.exe" \ - -exec /usr/bin/strip '{}' \; 2>&1 \ - | grep -v "No such file" | grep -v "format not recognized" - fi -} - in_array() { local i @@ -1780,6 +1759,21 @@ _subpkgs_removeemptydirfix() 2>/dev/null } +_pkg_strip_hook() +{ + msg "Stripping debugging symbols from libraries from $subpkg$1..." + find {,usr,usr/local,opt/*}/lib -type f -not -name "*.dll" -not -name "*.exe" \ + -exec /usr/bin/strip --strip-debug '{}' \; 2>&1 \ + | grep -v "No such file" | grep -v "format not recognized" + msg "Stripping symbols from binaries from $subpkg$1..." + find {,usr,usr/local,opt/*}/{bin,sbin} -type f -not -name "*.dll" -not -name "*.exe" \ + -exec /usr/bin/strip '{}' \; 2>&1 \ + | grep -v "No such file" | grep -v "format not recognized" +} +if [ ! "`check_option NOSTRIP`" -a "$NOSTRIP" = "0" ]; then + _P_subpkgsfixes+=(_pkg_strip_hook) +fi + do_subpkgsfixes() { local hook package_name _______________________________________________ Frugalware-git mailing list [email protected] http://frugalware.org/mailman/listinfo/frugalware-git
