Subject: | Non POSIX compliant use of "head" and "tail" |
cpan2rpm 2.027 uses "head -1" and "tail -1" which are not POSIX compliant, and will fail with GNU coreutils 5.3.0. Fix attached.
--- cpan2rpm~ 2005-02-07 19:25:27.000000000 +0200
+++ cpan2rpm 2005-03-29 21:39:27.000000000 +0300
@@ -1254,8 +1254,8 @@
system("chmod", "-R", "u+w", $dst);
my $cmd = $zip
- ? "unzip -l $_ | grep -P -o '\\S+/\$' |tail -1"
- : "tar -t${z}vf $_ |head -1"
+ ? "unzip -l $_ | grep -P -o '\\S+/\$' |tail -n 1"
+ : "tar -t${z}vf $_ |head -n 1"
;
chomp($_ = qx/$cmd/);