diff options
Diffstat (limited to 'debian')
-rw-r--r-- | debian/changelog | 2 | ||||
-rw-r--r-- | debian/patches/0140-avahi.patch | 53 | ||||
-rw-r--r-- | debian/patches/0145-avahi.patch | 7 | ||||
-rw-r--r-- | debian/patches/series | 4 | ||||
-rwxr-xr-x | debian/rules | 2 |
5 files changed, 52 insertions, 16 deletions
diff --git a/debian/changelog b/debian/changelog index 5bb32cf..456c0da 100644 --- a/debian/changelog +++ b/debian/changelog @@ -24,7 +24,7 @@ sane-backends (1.0.31-1~experimental1) UNRELEASED; urgency=medium - New debian/sane-utils.logrotate to pack and remove old logs. * debian/libsane-common.lintian-overrides: - Rename tags. - * debian/patches/0125-multiarch_dll_search_path.patch: + * debian/patches/0125-multiarch_dll_search_path.patch: - Add $(prefix)/lib64/sane to lib search path (Closes: #931297). * Fix FTCBFS: (Closes: #948711) - 0060-cross.patch: Make gphoto2 detection use the host architecture diff --git a/debian/patches/0140-avahi.patch b/debian/patches/0140-avahi.patch index ef35e1c..9c993b0 100644 --- a/debian/patches/0140-avahi.patch +++ b/debian/patches/0140-avahi.patch @@ -9,45 +9,80 @@ Index: trunk/backend/net.c =================================================================== --- trunk.orig/backend/net.c +++ trunk/backend/net.c -@@ -1045,12 +1045,12 @@ sane_init (SANE_Int * version_code, SANE +@@ -771,7 +771,7 @@ net_avahi_browse_callback (AvahiServiceB + { + case AVAHI_BROWSER_FAILURE: + DBG (1, "net_avahi_browse_callback: %s\n", avahi_strerror (avahi_client_errno (avahi_service_browser_get_client (b)))); +- avahi_threaded_poll_quit (avahi_thread); ++ if (avahi_thread) avahi_threaded_poll_quit (avahi_thread); + return; + + case AVAHI_BROWSER_NEW: +@@ -836,7 +836,7 @@ net_avahi_callback (AvahiClient *c, Avah + if (avahi_browser == NULL) + { + DBG (1, "net_avahi_callback: could not create service browser: %s\n", avahi_strerror (avahi_client_errno (c))); +- avahi_threaded_poll_quit (avahi_thread); ++ if (avahi_thread) avahi_threaded_poll_quit (avahi_thread); + } + break; + +@@ -859,14 +859,14 @@ net_avahi_callback (AvahiClient *c, Avah + if (avahi_client == NULL) + { + DBG (1, "net_avahi_init: could not create Avahi client: %s\n", avahi_strerror (error)); +- avahi_threaded_poll_quit (avahi_thread); ++ if (avahi_thread) avahi_threaded_poll_quit (avahi_thread); + } + } + else + { + /* Another error happened - game over */ + DBG (1, "net_avahi_callback: server connection failure: %s\n", avahi_strerror (error)); +- avahi_threaded_poll_quit (avahi_thread); ++ if (avahi_thread) avahi_threaded_poll_quit (avahi_thread); + } + break; + } +@@ -1045,12 +1041,12 @@ sane_init (SANE_Int * version_code, SANE continue; } - #ifdef WITH_AVAHI + #if WITH_AVAHI - avahi_threaded_poll_lock (avahi_thread); + if (avahi_thread) avahi_threaded_poll_lock (avahi_thread); #endif /* WITH_AVAHI */ DBG (2, "sane_init: trying to add %s\n", device_name); add_device (device_name, 0); - #ifdef WITH_AVAHI + #if WITH_AVAHI - avahi_threaded_poll_unlock (avahi_thread); + if (avahi_thread) avahi_threaded_poll_unlock (avahi_thread); #endif /* WITH_AVAHI */ } -@@ -1096,12 +1096,12 @@ sane_init (SANE_Int * version_code, SANE +@@ -1096,12 +1092,12 @@ sane_init (SANE_Int * version_code, SANE continue; #endif /* ENABLE_IPV6 */ - #ifdef WITH_AVAHI + #if WITH_AVAHI - avahi_threaded_poll_lock (avahi_thread); + if (avahi_thread) avahi_threaded_poll_lock (avahi_thread); #endif /* WITH_AVAHI */ DBG (2, "sane_init: trying to add %s\n", host); add_device (host, 0); - #ifdef WITH_AVAHI + #if WITH_AVAHI - avahi_threaded_poll_unlock (avahi_thread); + if (avahi_thread) avahi_threaded_poll_unlock (avahi_thread); #endif /* WITH_AVAHI */ } free (copy); -@@ -1519,11 +1519,11 @@ sane_open (SANE_String_Const full_name, +@@ -1519,11 +1520,11 @@ sane_open (SANE_String_Const full_name, "sane_open: device %s not found, trying to register it anyway\n", nd_name); - #ifdef WITH_AVAHI + #if WITH_AVAHI - avahi_threaded_poll_lock (avahi_thread); + if (avahi_thread) avahi_threaded_poll_lock (avahi_thread); #endif /* WITH_AVAHI */ status = add_device (nd_name, &dev); - #ifdef WITH_AVAHI + #if WITH_AVAHI - avahi_threaded_poll_unlock (avahi_thread); + if (avahi_thread) avahi_threaded_poll_unlock (avahi_thread); #endif /* WITH_AVAHI */ diff --git a/debian/patches/0145-avahi.patch b/debian/patches/0145-avahi.patch index 066291d..67c874b 100644 --- a/debian/patches/0145-avahi.patch +++ b/debian/patches/0145-avahi.patch @@ -13,21 +13,22 @@ Index: trunk/backend/net.c first_device = NULL; first_handle = NULL; --#ifdef WITH_AVAHI +-#if WITH_AVAHI - net_avahi_init (); -#endif /* WITH_AVAHI */ - auth_callback = authorize; /* Return the version number of the sane-backends package to allow -@@ -1119,6 +1115,10 @@ sane_init (SANE_Int * version_code, SANE +@@ -1119,6 +1115,11 @@ sane_init (SANE_Int * version_code, SANE DBG (2, "sane_init: connect timeout set to %d seconds from env\n", connect_timeout); } -+#ifdef WITH_AVAHI ++#if WITH_AVAHI + net_avahi_init (); +#endif /* WITH_AVAHI */ + ++ DBG (2, "sane_init: done\n"); return SANE_STATUS_GOOD; } diff --git a/debian/patches/series b/debian/patches/series index 67211d9..7933b48 100644 --- a/debian/patches/series +++ b/debian/patches/series @@ -2,8 +2,8 @@ 0040-remove_git.patch 0100-source_spelling.patch 0125-multiarch_dll_search_path.patch -#0140-avahi.patch -#0145-avahi.patch +0140-avahi.patch +0145-avahi.patch 0600-scanimage_manpage.patch #0700-mk_reproducible_results.patch 0705-kfreebsd.patch diff --git a/debian/rules b/debian/rules index d798b9e..8bab3c0 100755 --- a/debian/rules +++ b/debian/rules @@ -63,8 +63,8 @@ override_dh_autoreconf: override_dh_auto_build-indep: # generate POT file for translators - (cd po && make sane-backends.pot) $(MAKE) + (cd po && make sane-backends.pot) override_dh_auto_clean: # Autoconf-generated files |