Skip Menu |

This queue is for tickets about the Tk CPAN distribution.

Report information
The Basics
Id: 85407
Status: resolved
Priority: 0/
Queue: Tk

People
Owner: Nobody in particular
Requestors: ANDK [...] cpan.org
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: (no value)
Fixed in: 804.031



Subject: PNG compile does not find zconf.h
My smokers on linux (Debian sid) all refused to build Tk/PNG due to missing zconf.h. The reason is that zconf.h is in /usr/include/x86_64-linux-gnu/zconf.h and as such is found by gcc (4.7.3) even though it is included from /usr/include/zlib.h with #include "zconf.h" But it's not found by Tk/MakeDepend. The reason is in multiarch. The triplet x86_64-linux-gnu can be found with: % gcc -print-multiarch A tentative prove-of-concept fix works and is attached. At least the compilation is fixed that way. Some occasional test failures remain but have unrelated causes.
Subject: perl-tk-zconf-include-not-found.patch
diff --git a/Tk/MakeDepend.pm b/Tk/MakeDepend.pm index 3c3cba7..0164cc8 100644 --- a/Tk/MakeDepend.pm +++ b/Tk/MakeDepend.pm @@ -247,8 +247,16 @@ sub command_line } } # force /usr/include to be last element of @include - push @include, $Config{'usrinc'} - if (defined $Config{'usrinc'} and $Config{'usrinc'} ne ''); + if (defined $Config{'usrinc'} and $Config{'usrinc'} ne ''){ + push @include, $Config{'usrinc'}; + if ($Config{ccname} eq "gcc") { + my($multiarch) = `gcc -print-multiarch`; + if ($multiarch) { + chomp $multiarch; + push @include, "$Config{'usrinc'}/$multiarch"; + } + } + } # warn "Include:@include\n"; while (@files) {
On 2013-05-18 03:50:13, ANDK wrote: Show quoted text
> My smokers on linux (Debian sid) all refused to build Tk/PNG due to > missing zconf.h. The reason is that zconf.h is in > /usr/include/x86_64-linux-gnu/zconf.h and as such is found by gcc > (4.7.3) even though it is included from /usr/include/zlib.h with > > #include "zconf.h" > > But it's not found by Tk/MakeDepend. The reason is in multiarch. The > triplet x86_64-linux-gnu can be found with: > > % gcc -print-multiarch > > A tentative prove-of-concept fix works and is attached. At least the > compilation is fixed that way. Some occasional test failures remain > but have unrelated causes.
Hopefully fixed in 804.030_502. At least my (new) debian/sid instance compiles now. The fix is different: instead of using gcc -print-multiarch, Tk::MakeDepend parses the output of "cpp -v" which includes the complete search list for includes. This helps also with another issue on Windows, where /usr/include does not exist and $Config{usrinc} cannot be trusted (seen with ActivePerl). Cross reference: there's a similar bug report for Debian, see http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=708624 Regards, Slaven