[Pkg-gmagick-im-team] Bug#1144811: imagemagick: test_float_t.sh script contains invalid C code on sh4
John Paul Adrian Glaubitz
glaubitz at physik.fu-berlin.de
Wed Aug 19 07:20:33 BST 2026
Source: imagemagick
Version: 8:7.1.2.29+dfsg2-1
Severity: normal
X-Debbugs-Cc: debian-superh at lists.debian.org
User: debian-superh at lists.debian.org
Usertags: sh4
Hi,
the script debian/test_float_t.sh contains invalid C code which FTBFS with:
make[1]: Entering directory '/home/glaubitz/imagemagick-sh4-new/imagemagick-7.1.2.29+dfsg2'
/tmp/tmp.ynajwKcpye/float.c: In function 'main':
/tmp/tmp.ynajwKcpye/float.c:13:9: error: duplicate case value
13 | case(sizeof(long double)):
| ^~~~
/tmp/tmp.ynajwKcpye/float.c:10:9: note: previously used here
10 | case(sizeof(double)):
| ^~~~
The C code in the script looks like this:
int main()
{
switch(sizeof(float_t)) {
case(sizeof(float)):
printf("float");
return 0;
case(sizeof(double)):
printf("double");
return 0;
case(sizeof(long double)):
printf("long double");
return 0;
default:
printf("????");
return 1;
}
}
The code becomes invalid the moment any of these types have the same size
so that the switch statement becomes ambigious.
FWIW, the problem is currently obscured on the buildds due to an internal
compiler error that is fixed with GCC 17 [1].
Adrian
> [1] https://buildd.debian.org/status/fetch.php?pkg=imagemagick&arch=sh4&ver=8%3A7.1.2.29%2Bdfsg2-1&stamp=1786936373&raw=0
--
.''`. John Paul Adrian Glaubitz
: :' : Debian Developer
`. `' Physicist
`- GPG: 62FF 8A75 84E0 2956 9546 0006 7426 3B37 F5B5 F913
More information about the Pkg-gmagick-im-team
mailing list