0091-scripts-feeds-fix-version-detection-for-Make-4.2.1.patch 759 B

123456789101112131415161718192021222324
  1. From: Matthias Schiffer <mschiffer@universe-factory.net>
  2. Date: Wed, 15 Jun 2016 19:31:08 +0200
  3. Subject: scripts: feeds: fix version detection for Make >= 4.2.1
  4. Signed-off-by: Jo-Philipp Wich <jo@mein.io>
  5. Backport of LEDE df18b3756fef6a28d9194368d3156f0cd85fae19
  6. diff --git a/scripts/feeds b/scripts/feeds
  7. index f8f29cd..908e56c 100755
  8. --- a/scripts/feeds
  9. +++ b/scripts/feeds
  10. @@ -22,7 +22,10 @@ my @mkver = split /\s+/, `$mk -v`, 4;
  11. my $valid_mk = 1;
  12. $mkver[0] =~ /^GNU/ or $valid_mk = 0;
  13. $mkver[1] =~ /^Make/ or $valid_mk = 0;
  14. -$mkver[2] >= "3.81" or $valid_mk = 0;
  15. +
  16. +my ($mkv1, $mkv2) = split /\./, $mkver[2];
  17. +($mkv1 >= 4 || ($mkv1 == 3 && $mkv2 >= 81)) or $valid_mk = 0;
  18. +
  19. $valid_mk or die "Unsupported version of make found: $mk\n";
  20. my @feeds;