An open-source COBOL contender emerges

An all-FOSS, direct-to-binary compiler for the 63-year-old programming language


The newly announced gcobol compiler is a fresh front end for GCC, and builds native binary executables.

There are already other FOSS and freeware compilers for COBOL out there, but few are fully open source. Notably, there's GnuCOBOL, which evolved out of OpenCOBOL. The OpenCOBOL FAQ is worth a read, and notes that: "OpenCOBOL was initially developed by Keisuke Nishida from experience working on TinyCOBOL originally developed by Rildo Pragana."

There's nothing wrong with GnuCOBOL: it's mature, in active development, and supports various COBOL standards and dialects – but as the announcement for gcobol says: "Our project should not be confused with GnuCOBOL. That project is a Cobol translator: it compiles Cobol to C, and invokes gcc to produce executable code."

You can still get COBOL-IT. This French project developed an open-source compiler suite until it was acquired by "the guardians of business COBOL" – or alternatively, a retirement home for ageing software businesses – aka Micro Focus – in 2017.

Micro Focus does offer a free trial of Visual COBOL, though this is only under a one-year personal trial license.

Don't put me on the cart

Despite now being over 60 years old, COBOL is very much alive, well, and relevant. The last two standards were COBOL-2002, which standardized object oriented programming, and COBOL 2014, which among other things added IEEE-754 floating-point arithmetic handling, method overloading, and dynamic capacity tables.

Over on the commercial side of things, IBM introduced a 64-bit compiler for AIX and later a native x86 one. Micro Focus' Visual COBOL lets you build for .NET and Cloudflare will run it in the cloud.

These are still very early days for the new compiler, which has so far seen one man-year of work – which is to say, two programmers have been working on it full-time since October last year, although its Gitlab page shows that work started earlier.

So far, as a validation suite, they are working through the example programs from the 2014 book Beginning COBOL for Programmers, and gcobol successfully compiles a hundred of them. If you're curious, the programs are on GitHub. After this, the developers plan to move on to the NIST COBOL-85 test suite. ®

Bootnote

Yes, new books about learning COBOL are being published. There's considerable demand for COBOL programmers – ever since the Y2K problem, old hands have been coming out of retirement, at premium rates of course. Now they're dying off, and increasingly desperate COBOL users were previously appealing for volunteers to help. If you can wrap your head around this relatively simple but verbose language, you are basically guaranteed a job.

Similar topics


Other stories you might like

Biting the hand that feeds IT © 1998–2022