aboutsummaryrefslogtreecommitdiffstats
path: root/tools/release-update-debian-soversions.sh
diff options
context:
space:
mode:
authorBalint Reczey <balint.reczey@canonical.com>2017-08-05 12:32:37 +0200
committerMichael Mann <mmann78@netscape.net>2017-08-09 00:58:09 +0000
commit5580b3beb70ba51c5d4074e1bf691858ec09de0c (patch)
treec551eaeade4c31aa5d5925033947795a0d5250a7 /tools/release-update-debian-soversions.sh
parentc6a23a4b72c57eb3e81b96563e6a8faa3a810aa5 (diff)
debian: Add script for updating shared library package names
It should be run prior to major release after the new shared library versions are set for cmake. Change-Id: I5cf2a3a9121672c8be14e57a318c9eaf5105e622 Signed-off-by: Balint Reczey <balint.reczey@canonical.com> Reviewed-on: https://code.wireshark.org/review/22967 Reviewed-by: Balint Reczey <balint@balintreczey.hu> Petri-Dish: Balint Reczey <balint@balintreczey.hu> Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com> Reviewed-by: Michael Mann <mmann78@netscape.net>
Diffstat (limited to 'tools/release-update-debian-soversions.sh')
-rwxr-xr-xtools/release-update-debian-soversions.sh35
1 files changed, 35 insertions, 0 deletions
diff --git a/tools/release-update-debian-soversions.sh b/tools/release-update-debian-soversions.sh
new file mode 100755
index 0000000000..4dfd604c40
--- /dev/null
+++ b/tools/release-update-debian-soversions.sh
@@ -0,0 +1,35 @@
+#!/bin/sh
+#
+# Compare ABIs of two Wireshark working copies
+#
+# Copyright 2017 Balint Reczey <balint.reczey@canonical.com>
+#
+# Wireshark - Network traffic analyzer
+# By Gerald Combs <gerald@wireshark.org>
+# Copyright 1998 Gerald Combs
+#
+# This program is free software; you can redistribute it and/or
+# modify it under the terms of the GNU General Public License
+# as published by the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+
+# Set shared library package names and library versions in Debian packaging
+# matching the new major release's so versions
+
+set -e
+
+for i in wireshark wiretap wscodecs wsutil; do
+ NEW_VERSION=$(grep SOVERSION $(grep -l lib${i} */CMakeLists.txt) | sed 's/.*SOVERSION \([0-9]*\).*/\1/')
+ rename "s/0\./${NEW_VERSION}./" debian/lib${i}0.*
+ grep -l -R "lib${i}0" debian/ | xargs sed -i "s/lib${i}0/lib${i}${NEW_VERSION}/"
+ grep -l -R "lib${i}\.so\.0" debian/ | xargs sed -i "s/lib${i}\.so\.0/lib${i}.so.${NEW_VERSION}/"
+done