Debian Bug report logs -
#442018
f2c.h: wrong integer size on amd64
Reported by: Sergio Gelato <Sergio.Gelato@astro.su.se>
Date: Wed, 12 Sep 2007 15:21:32 UTC
Severity: normal
Found in version libf2c2/20050501-2
Fixed in version libf2c2/20061008-4.1
Done: Evgeni Golov <sargentd@die-welt.net>
Bug is archived. No further changes may be made.
Toggle useless messages
Report forwarded to debian-bugs-dist@lists.debian.org, Alan Bain <afrb2@debian.org>:
Bug#442018; Package libf2c2-dev.
(full text, mbox, link).
Acknowledgement sent to Sergio Gelato <Sergio.Gelato@astro.su.se>:
New Bug report received and forwarded. Copy sent to Alan Bain <afrb2@debian.org>.
(full text, mbox, link).
Message #5 received at submit@bugs.debian.org (full text, mbox, reply):
Package: libf2c2-dev
Version: 20050501-2
f2c.h defines among others:
typedef long int integer;
typedef float real;
However, the Fortran standard requires INTEGER and REAL to occupy the
same storage size. On amd64, "long int" is 64-bit while "float" is
32-bit.
The same issue was addressed years ago on the alpha platform. From
/usr/share/doc/f2c/README.debian.gz:
"This version of f2c automatically converts the header file
f2c.h to not use long ints when compiled on alpha architecture,
as this generates incorrect code for EQUIVALENCEs (64 bit longs
are used on the alpha), and is not compatible with g77. On
other platforms the file is used as is. Similar changes
may turn out to be needed on other 64 bit architectures."
A similar change does turn out to be needed on amd64.
And that README snippet should probably be moved from package f2c to
package libf2c2-dev now that /usr/include/f2c.h has moved.
Information forwarded to debian-bugs-dist@lists.debian.org, Alan Bain <afrb2@debian.org>:
Bug#442018; Package libf2c2-dev.
(full text, mbox, link).
Acknowledgement sent to Sergio Gelato <Sergio.Gelato@astro.su.se>:
Extra info received and forwarded to list. Copy sent to Alan Bain <afrb2@debian.org>.
(full text, mbox, link).
Message #10 received at 442018@bugs.debian.org (full text, mbox, reply):
I have now tested a fix (ignoring for now the fact that this involves an
ABI change and that one may therefore need to call the fixed package
libf2c3 instead of libf2c2; that's a can of worms I'll leave to others).
Here is what I've added to debian/rules:
elif [ $(arch) == "amd64" ] ;\
then echo "Building for AMD64" ;\
sed 's/long //' f2c.h > f2c.install.h ;\
cp f2c.install.h f2c.h ;\
That last line deserves a comment. If one omits it, then the library
ends up being built with the unpatched f2c.h, which is obviously not
the right thing to do. (It will bite you the moment you try to do any
Fortran I/O.) The corresponding stanza for the alpha architecture is
missing that line, and that looks very suspicious to me. I don't
have the hardware to test it, but I don't see why alpha and amd64
should differ in this respect.
With the fix I described above, my application (a private Debian
packaging of stsci_python,
http://www.stsci.edu/resources/software_hardware/pyraf/stsci_python )
no longer segfaults on amd64 when linked with libf2c.a.
Reply sent
to Evgeni Golov <sargentd@die-welt.net>:
You have taken responsibility.
(Sat, 03 Jan 2009 23:09:02 GMT) (full text, mbox, link).
Notification sent
to Sergio Gelato <Sergio.Gelato@astro.su.se>:
Bug acknowledged by developer.
(Sat, 03 Jan 2009 23:09:02 GMT) (full text, mbox, link).
Message #15 received at 442018-close@bugs.debian.org (full text, mbox, reply):
Source: libf2c2
Source-Version: 20061008-4.1
We believe that the bug you reported is fixed in the latest version of
libf2c2, which is due to be installed in the Debian FTP archive:
libf2c2-dev_20061008-4.1_amd64.deb
to pool/main/libf/libf2c2/libf2c2-dev_20061008-4.1_amd64.deb
libf2c2_20061008-4.1.diff.gz
to pool/main/libf/libf2c2/libf2c2_20061008-4.1.diff.gz
libf2c2_20061008-4.1.dsc
to pool/main/libf/libf2c2/libf2c2_20061008-4.1.dsc
libf2c2_20061008-4.1_amd64.deb
to pool/main/libf/libf2c2/libf2c2_20061008-4.1_amd64.deb
A summary of the changes between this version and the previous one is
attached.
Thank you for reporting the bug, which will now be closed. If you
have further comments please address them to 442018@bugs.debian.org,
and the maintainer will reopen the bug report if appropriate.
Debian distribution maintenance software
pp.
Evgeni Golov <sargentd@die-welt.net> (supplier of updated libf2c2 package)
(This message was generated automatically at their request; if you
believe that there is a problem with it please contact the archive
administrators by mailing ftpmaster@debian.org)
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Format: 1.8
Date: Sat, 03 Jan 2009 03:41:30 +0100
Source: libf2c2
Binary: libf2c2 libf2c2-dev
Architecture: source amd64
Version: 20061008-4.1
Distribution: unstable
Urgency: low
Maintainer: Alan Bain <afrb2@debian.org>
Changed-By: Evgeni Golov <sargentd@die-welt.net>
Description:
libf2c2 - Shared libraries for use with FORTRAN applications
libf2c2-dev - Development libraries for use with f2c
Closes: 442018 508565
Changes:
libf2c2 (20061008-4.1) unstable; urgency=low
.
* Non-maintainer upload.
* Don't sed away long on alpha and ia64, that was an ugly hack.
* Instead add some ifdefs to f2c.h so we catch all archs where
a long is 8 bytes and use only int there (make sure not to break
other architectures by keeping long int there).
Update README.debian accordingly.
Also update f2c.h0 and f2c_master.h, so the files match, even if
they are unused.
Closes: #442018, #508565.
* Clean debian/*.debhelper.log.
Checksums-Sha1:
c7bdd168e6f582bdc34ff92ca88dcb2aa2751680 980 libf2c2_20061008-4.1.dsc
6ae8a4a9f1341be89f93b74492f530ba13be227e 60471 libf2c2_20061008-4.1.diff.gz
7e5b1d8ce7671eda4ee29fe1ade0c724b8beb271 476998 libf2c2-dev_20061008-4.1_amd64.deb
febd228daf93f76823145cbfcbc3d5a2820c65ce 158832 libf2c2_20061008-4.1_amd64.deb
Checksums-Sha256:
55f805311754ff8f8eb7a0f1053775efee1c58bf297658b2d849d2aa56ca9817 980 libf2c2_20061008-4.1.dsc
3878fe559c046d2b7d8795e33281b81ed7b75e13a4c63e6e40927876f2bf0869 60471 libf2c2_20061008-4.1.diff.gz
7a412f15e782ae0fcabaecfa289edef67caaa7e38f7d7129d873d2611c132fdd 476998 libf2c2-dev_20061008-4.1_amd64.deb
cbd63faa7a48e88056f3b6fb43113a49290b5ad1a63411b47e56b0fa90118fa3 158832 libf2c2_20061008-4.1_amd64.deb
Files:
fb3ff8dc35e105c9ed7da1304b5c0a51 980 devel optional libf2c2_20061008-4.1.dsc
6ba584e7a3748e4f8d0c93582d8b2b94 60471 devel optional libf2c2_20061008-4.1.diff.gz
6bf952736e441f3707d412c5cbcc2b91 476998 libdevel optional libf2c2-dev_20061008-4.1_amd64.deb
dab3900424b71e066f400dcfe658c32a 158832 libs optional libf2c2_20061008-4.1_amd64.deb
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (GNU/Linux)
iEYEARECAAYFAklf7FIACgkQeGfVPHR5Nd1ERwCeIPtzFeYiBdhGifYqUnH3souc
Ri8AoLyNYjYcRJ9rLe7Gfk0Ds7gxyQSf
=300Q
-----END PGP SIGNATURE-----
Bug archived.
Request was from Debbugs Internal Request <owner@bugs.debian.org>
to internal_control@bugs.debian.org.
(Wed, 11 Feb 2009 07:27:12 GMT) (full text, mbox, link).
Send a report that this bug log contains spam.
Debian bug tracking system administrator <owner@bugs.debian.org>.
Last modified:
Mon Jul 15 20:00:32 2024;
Machine Name:
bembo
Debian Bug tracking system
Debbugs is free software and licensed under the terms of the GNU
Public License version 2. The current version can be obtained
from https://bugs.debian.org/debbugs-source/.
Copyright © 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson,
2005-2017 Don Armstrong, and many other contributors.