summaryrefslogtreecommitdiffstats
path: root/debian/highest_symbol_version
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-19 17:03:56 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-19 17:03:56 +0000
commitad07a2b86334c23fe063be97e8dd44e586c324b4 (patch)
treebb0f3e91284adc84f813a6e46867915be34b704f /debian/highest_symbol_version
parentAdding upstream version 31+20240202. (diff)
downloadkmod-ad07a2b86334c23fe063be97e8dd44e586c324b4.tar.xz
kmod-ad07a2b86334c23fe063be97e8dd44e586c324b4.zip
Adding debian version 31+20240202-2.debian/31+20240202-2
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'debian/highest_symbol_version')
-rw-r--r--debian/highest_symbol_version20
1 files changed, 20 insertions, 0 deletions
diff --git a/debian/highest_symbol_version b/debian/highest_symbol_version
new file mode 100644
index 0000000..ce6039a
--- /dev/null
+++ b/debian/highest_symbol_version
@@ -0,0 +1,20 @@
+#!/usr/bin/perl
+# print the highest package version found in the symbols file read as input
+
+use v5.30;
+use warnings;
+
+use Dpkg::Version;
+
+my $highest = 0;
+while (<>) {
+ my ($version) = /^\s+\S+\s+(\S+)$/;
+ next if not $version;
+ next if version_compare($highest, $version) == 1;
+ $highest = $version;
+}
+
+die 'could not find a version number in the input' if not $highest;
+
+say $highest;
+