Revision: 7904 http://sourceforge.net/p/ipcop/svn/7904 Author: owes Date: 2015-02-23 20:04:40 +0000 (Mon, 23 Feb 2015) Log Message: ----------- Test for package parameter first. Find more filelist variants.
Modified Paths: -------------- ipcop/trunk/tools/package-diff.pl Modified: ipcop/trunk/tools/package-diff.pl =================================================================== --- ipcop/trunk/tools/package-diff.pl 2015-02-23 07:24:09 UTC (rev 7903) +++ ipcop/trunk/tools/package-diff.pl 2015-02-23 20:04:40 UTC (rev 7904) @@ -15,7 +15,7 @@ # You should have received a copy of the GNU General Public License # along with IPCop. If not, see <http://www.gnu.org/licenses/>. # -# (c) 2011-2014 The IPCop Team +# (c) 2011-2015 The IPCop Team # # Usage: package-diff.pl <lfs-package-name> # @@ -33,13 +33,6 @@ use warnings; -my $ipcop_version = `grep "^VERSION=" make.sh | cut -d '=' -f 2`; -chomp(${ipcop_version}); -my $diff_file = "doc/IPCop-${ipcop_version}-diff-list.i486.txt"; -unless (-e $diff_file) { - die "$diff_file does not exist"; -} - unless (defined($ARGV[0])) { die "No package name."; } @@ -49,7 +42,22 @@ my $rootfile = ""; my $filelist = `find files_i486 -name ${package}-${package_version} | grep -v 01_toolchain`; chomp($filelist); +if (! -f "${filelist}") { + # Look for alternative names + $filelist = `find files_i486 -name ${package}.${package_version} | grep -v 01_toolchain`; + chomp($filelist); + if (! -f "${filelist}") { + $filelist = `find files_i486 -name ${package}${package_version} | grep -v 01_toolchain`; + chomp($filelist); + } +} +# Get IPCop version +my $ipcop_version = `grep "^VERSION=" make.sh | cut -d '=' -f 2`; +chomp(${ipcop_version}); + +my $diff_file = "doc/IPCop-${ipcop_version}-diff-list.i486.txt"; + # Get Perl version my $perl_version = `grep "^VER" lfs/perl | cut -d '=' -f 2`; chomp(${perl_version}); @@ -79,6 +87,12 @@ print "<<\n"; } + +unless (-e $diff_file) { + print "#\n#\n$diff_file does not exist\n"; + exit(0); +} + # # Search diff-list.txt for matches # This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. ------------------------------------------------------------------------------ Download BIRT iHub F-Type - The Free Enterprise-Grade BIRT Server from Actuate! Instantly Supercharge Your Business Reports and Dashboards with Interactivity, Sharing, Native Excel Exports, App Integration & more Get technology previously reserved for billion-dollar corporations, FREE http://pubads.g.doubleclick.net/gampad/clk?id=190641631&iu=/4140/ostg.clktrk _______________________________________________ Ipcop-svn mailing list Ipcop-svn@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/ipcop-svn