f2c-compiled program produces no output
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
f2c (Ubuntu) |
New
|
Undecided
|
Unassigned |
Bug Description
$ cat hello.f
print *,"Hello, world"
end
$ f2c hello.f
hello.f:
MAIN:
$ cat hello.c
/* hello.f -- translated by f2c (version 20160102).
You must link the resulting object file with libf2c:
on Microsoft Windows system, link with libf2c.lib;
on Linux or Unix systems, link with .../path/
or, if you install libf2c.a in a standard place, with -lf2c -lm
-- in that order, at the end of the command line, as in
cc *.o -lf2c -lm
Source for libf2c is in /netlib/
http://
*/
#include "f2c.h"
/* Table of constant values */
static integer c__9 = 9;
static integer c__1 = 1;
/* Main program */ int MAIN__(void)
{
/* Builtin functions */
integer s_wsle(cilist *), do_lio(integer *, integer *, char *, ftnlen),
/* Fortran I/O blocks */
static cilist io___1 = { 0, 6, 0, 0, 0 };
s_wsle(
do_lio(&c__9, &c__1, "Hello, world", (ftnlen)12);
e_wsle();
return 0;
} /* MAIN__ */
$ gcc hello.c -lf2c
$ ./a.out
$
ProblemType: Bug
DistroRelease: Ubuntu 20.04
Package: f2c 20160102-1
ProcVersionSign
Uname: Linux 5.4.0-113-generic x86_64
NonfreeKernelMo
ApportVersion: 2.20.11-
Architecture: amd64
CasperMD5CheckR
CurrentDesktop: KDE
Date: Tue May 31 22:15:02 2022
InstallationDate: Installed on 2021-03-27 (430 days ago)
InstallationMedia: Ubuntu-Server 20.04.2 LTS "Focal Fossa" - Release amd64 (20210201.2)
SourcePackage: f2c
UpgradeStatus: No upgrade log present (probably fresh install)