This is an automated email from the git hooks/post-receive script. guillem pushed a commit to branch main in repository dpkg.
View the commit online: https://git.dpkg.org/cgit/dpkg/dpkg.git/commit/?id=6c891218fa8633b33e4d323311097f310bbca731 commit 6c891218fa8633b33e4d323311097f310bbca731 (HEAD -> main) Author: Guillem Jover <[email protected]> AuthorDate: Tue Nov 15 00:58:07 2022 +0100 dpkg-genbuildinfo: Fix implicit function declaration in cross-runnable check We nee to include the required headers otherwise a compiler that conforms to C99 by default might error out on implicit function declarations. Changelog: silent --- scripts/dpkg-genbuildinfo.pl | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/scripts/dpkg-genbuildinfo.pl b/scripts/dpkg-genbuildinfo.pl index a142cc1b3..7f4eaf1b9 100755 --- a/scripts/dpkg-genbuildinfo.pl +++ b/scripts/dpkg-genbuildinfo.pl @@ -263,7 +263,10 @@ sub is_cross_executable { # the host architecture by cross-compiling and executing a small # host-arch binary. my $CC = debarch_to_gnutriplet($host_arch) . '-gcc'; - my $crossprog = 'int main() { write(1, "ok", 2); return 0; }'; + my $crossprog = <<~'CROSSPROG'; + #include <unistd.h> + int main() { write(1, "ok", 2); return 0; } + CROSSPROG my ($stdout, $stderr) = ('', ''); my $tmpfh = File::Temp->new(); spawn( -- Dpkg.Org's dpkg

