From 77781be832eea78e2942b3a9422e0f3b438045ac Mon Sep 17 00:00:00 2001 Message-Id: <77781be832eea78e2942b3a9422e0f3b438045ac.1714644341.git.mdw@distorted.org.uk> From: Mark Wooding Date: Mon, 10 Jul 2017 10:32:23 +0100 Subject: [PATCH 1/1] configure.ac: Hack probed Wireshark plugin dir in case of corruption. Organization: Straylight/Edgeware From: Mark Wooding Somehow the Debian package (at least) of Wireshark ships with a `pkg-config' dropping which contains a broken `libdir' -- and, hence, `plugindir'. This has happened before, and it's therefore not unlikely to happen again. Defend ourselves against this mess by spotting the bungled value (which is distinctively and obviously wrong) and fixing it. --- configure.ac | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/configure.ac b/configure.ac index 4e83e754..f3b75ea2 100644 --- a/configure.ac +++ b/configure.ac @@ -225,7 +225,14 @@ case "$haveshark,$wireshark_plugindir" in AC_CACHE_CHECK([where to put Wireshark plugins], [mdw_cv_wireshark_plugin_dir], [ mdw_cv_wireshark_plugin_dir=$( - $PKG_CONFIG --variable=plugindir "wireshark >= 1.12.1")]) + $PKG_CONFIG --variable=plugindir "wireshark >= 1.12.1") + dnl It seems that the Debian package has a habit of bungling the + dnl plugin path (#779788, #857729, ...). + case "$mdw_cv_wireshark_plugin_dir" in + /usr//usr/*) + mdw_cv_wireshark_plugin_dir=${mdw_cv_wireshark_plugin_dir#/usr/} + ;; + esac]) case "$mdw_cv_wireshark_plugin_dir" in /*) if test ! -d "$mdw_cv_wireshark_plugin_dir"; then -- [mdw]