Fortran 77 in Manjaro

The gcc-fortran package in official Manjaro repos only provides Fortran 95 (f95) compiler, whereas gfortran package in Ubuntu provides both f95 and f77 compilers. Can I install f77 compiler from the official Manjaro repos?

Not sure if possible from the official Manjaro repos, but it seems to be possible from the AUR:

pamac build fort77

Thank you. But while I build fort77 in pamac

Building fort77...
==> Making package: fort77 1.18-3 (Thursday 12 August 2021 08:42:16 AM)
==> Checking runtime dependencies...
==> Checking buildtime dependencies...
==> Retrieving sources...
  -> Found fort77-1.18.tar.gz
==> Validating source files with sha256sums...
    fort77-1.18.tar.gz ... Passed
==> Removing existing $srcdir/ directory...
==> Extracting sources...
  -> Extracting fort77-1.18.tar.gz with bsdtar
==> Removing existing $pkgdir/ directory...
==> Starting check()...
(cd tests; ./ -v)
./fort77 -c foo.f ... test successful.
./fort77 -c bar.F ... test successful.
./fort77 -c -o gargle.o foo.f ... test successful.
./fort77 foo.f ... test successful.
./fort77 baz/bazfoo.f ... test successful.
./fort77 -c baz/bazfoo.f ... test successful.
./fort77 -o bar.o -c baz/bazfoo.f ... test successful.
./fort77 -o tscht foo.f ... test successful.
./fort77 -k foo.f ... test successful.
./fort77 -g -k foo.f ... test successful.
./fort77 -c -f long.f ... test successful.
./fort77 mainmiss.f ... "a.out" should not be generated by "( ./fort77 mainmiss.f ) >/dev/null 2>&1"
./fort77 -c foo.f && ./fort77 -c mainmiss.f && ./fort77 -o foo foo.o mainmiss.o ..../fort77 -c foo.f && ./fort77 -o foo foo.o mainmiss.f ..../fort77 synerr.f && touch gargle ...Total 1 error(s) encountered.
make: *** [Makefile:7: test] Error 1
==> ERROR: A failure occurred in check().

What is causing the error?

Having some problems on my side aswell. What purpose do you have for using this old compiler? If it’s to compile software meant for Ubuntu or older systems, may want to look into using a docker image of Ubuntu and build it using that.

Nothing like that actually, just my course instructor provided a worksheet in which a few programs were to be compiled using f77, just for some familiarity. :sweat_smile:

Recommendation: Use the same OS that your course instructor is using in a VM. It’ll likely make your life a lot easier.

As much as I detest Ubuntu, can’t really hurt to have it in a VM to make your life easier here.

1 Like

I second that. I guess it’s just a few months where you require a lot of old libraries and versions which probably will break your system in the future. Inside a VM, you can install and do anything you like without breaking your actual system.

Also, after the course, you can just delete the VM and be done with it.

1 Like

The compiler fails a test case. If you don’t care about it, edit the PKGBUILD to delete the check() function and you’re good to go.

1 Like

Thanks a lot @Evernow and @mithrial for the excellent recommendation, that’s a very good idea, indeed!
And, @leledumbo 's post solves the error! Thank you all very much :slightly_smiling_face:.

This topic was automatically closed 24 hours after the last reply. New replies are no longer allowed.