diff -Nru jack-capture-0.9.73/debian/changelog jack-capture-0.9.73/debian/changelog --- jack-capture-0.9.73/debian/changelog 2023-09-18 18:44:41.000000000 +0100 +++ jack-capture-0.9.73/debian/changelog 2024-01-25 20:44:18.000000000 +0000 @@ -1,3 +1,10 @@ +jack-capture (0.9.73-4ubuntu1) noble; urgency=medium + + * backport upstream patch to fix FTBFS by removing custom version of + asprintf. (LP: #2038849) + + -- Sudip Mukherjee Thu, 25 Jan 2024 20:44:18 +0000 + jack-capture (0.9.73-4) unstable; urgency=medium * Team upload diff -Nru jack-capture-0.9.73/debian/control jack-capture-0.9.73/debian/control --- jack-capture-0.9.73/debian/control 2023-09-18 18:44:23.000000000 +0100 +++ jack-capture-0.9.73/debian/control 2024-01-25 20:39:51.000000000 +0000 @@ -1,7 +1,8 @@ Source: jack-capture Section: sound Priority: optional -Maintainer: Debian Multimedia Maintainers +Maintainer: Ubuntu Developers +XSBC-Original-Maintainer: Debian Multimedia Maintainers Uploaders: Jaromír Mikeš , Adrian Knoth diff -Nru jack-capture-0.9.73/debian/patches/06-fix_asprintf.patch jack-capture-0.9.73/debian/patches/06-fix_asprintf.patch --- jack-capture-0.9.73/debian/patches/06-fix_asprintf.patch 1970-01-01 01:00:00.000000000 +0100 +++ jack-capture-0.9.73/debian/patches/06-fix_asprintf.patch 2024-01-25 20:36:36.000000000 +0000 @@ -0,0 +1,72 @@ +Description: Compile with _GNU_SOURCE to avoid custom version of asprintf +Origin: upstream, https://github.com/kmatheussen/jack_capture/commit/00c986d41dc932982d248b7c27221fccaec90f0b +Bug-Ubuntu: https://launchpad.net/bugs/2038849 +Last-Update: 2024-01-25 +--- + +--- jack-capture-0.9.73.orig/jack_capture.c ++++ jack-capture-0.9.73/jack_capture.c +@@ -20,6 +20,8 @@ + + #include "das_config.h" + ++#define _GNU_SOURCE 1 ++ + #include + #include + #include +@@ -900,54 +902,6 @@ static void stop_helper_thread(void){ + ///////////////////////////////////////////////////////////////////// + + +-#ifndef __USE_GNU +-/* This code has been derived from an example in the glibc2 documentation. +- * "asprintf() implementation for braindamaged operating systems" +- * Copyright (C) 1991, 1994-1999, 2000, 2001 Free Software Foundation, Inc. +- */ +-#ifdef _WIN32 +-#define vsnprintf _vsnprintf +-#endif +-#ifndef __APPLE__ +-int asprintf(char **buffer, char *fmt, ...) { +- /* Guess we need no more than 200 chars of space. */ +- int size = 200; +- int nchars; +- va_list ap; +- +- *buffer = (char*)malloc(size); +- if (*buffer == NULL) return -1; +- +- /* Try to print in the allocated space. */ +- va_start(ap, fmt); +- nchars = vsnprintf(*buffer, size, fmt, ap); +- va_end(ap); +- +- if (nchars >= size) +- { +- char *tmpbuff; +- /* Reallocate buffer now that we know how much space is needed. */ +- size = nchars+1; +- tmpbuff = (char*)realloc(*buffer, size); +- +- if (tmpbuff == NULL) { /* we need to free it*/ +- free(*buffer); +- return -1; +- } +- +- *buffer=tmpbuff; +- /* Try again. */ +- va_start(ap, fmt); +- nchars = vsnprintf(*buffer, size, fmt, ap); +- va_end(ap); +- } +- +- if (nchars < 0) return nchars; +- return size; +-} +-#endif +-#endif +- + #define ARGS_ADD_ARGV(FMT,ARG) \ + argv=(char**) realloc((void*)argv, (argc+2)*sizeof(char*)); \ + asprintf(&argv[argc++], FMT, ARG); argv[argc] = 0; diff -Nru jack-capture-0.9.73/debian/patches/series jack-capture-0.9.73/debian/patches/series --- jack-capture-0.9.73/debian/patches/series 2023-09-18 18:44:23.000000000 +0100 +++ jack-capture-0.9.73/debian/patches/series 2024-01-25 20:34:52.000000000 +0000 @@ -1,2 +1,3 @@ 01-fix_hardening.patch 05-spelling.patch +06-fix_asprintf.patch