Group: Software/research/ProgrammingLanguages
(→Programming languages: split autotools in automake and autoconf) |
(→Parabola status: Ruby is now fixed in Parabola. I tested on x86_64 and I can even run ruby programs.) |
||
(78 intermediate revisions by 2 users not shown) | |||
Line 1: | Line 1: | ||
== Introduction == | == Introduction == | ||
− | + | The goal of this page is to understand the status of various programming languages and toolchains. It can help people deciding on a programming language to choose or to learn, or enable people to understand where distributions need contributions to support well a language. | |
− | == | + | It could also contain information on what language works where or if we can target specific operating systems with free software or not. |
+ | |||
+ | == Toolchain status == | ||
+ | |||
+ | === Compilers features and languages === | ||
{| border="0" style="font-size: smaller" | {| border="0" style="font-size: smaller" | ||
|- bgcolor="#6699ff" | |- bgcolor="#6699ff" | ||
− | ! | + | ! Language |
+ | ! Autoconf | ||
+ | ! Automake | ||
+ | ! Libtool<ref name="libtool">libtool is part of the autotools and it abstracts linking to make it work on a lot of operating systems. The status of the programming languages other than C and C++ can be found here: https://www.gnu.org/software/libtool/manual/libtool.html#Tags</ref> | ||
+ | ! GCC 13 support<ref>Compared with other compilers like LLVM and rustc, GCC supports many CPU architectures and it's quite well integrated with various other software (gdb, gprof, build systems, etc). It also has long term support in mind as it continues to support other programming language standards. It also has good documentation that explain how it handles C code for instance. In addition it's a GNU project, so it has users freedom in mind. In addition Guix has made GCC bootstrapable from a binary that is less than 1KB, and it doesn't require huge resources to build or bootstrap.</ref> | ||
+ | ! Other free compilers | ||
+ | ! Shared libraries<ref name="shared-libraries">Shared libraries systems enable way better performances on older computers as it uses way less RAM.</ref> | ||
+ | ! Microcontrollers<ref name="microcontrollers">Can we compile and/or run code for/on microcontrollers, if so which compilers/interpreters are used / necessary for that.</ref> | ||
+ | ! Strict specifications<ref name="strict-specifications">Having a standard or something similar to refer to enables people to write code that can still be used without requiring too much maintenance to adapt to newer compiler versions.</ref> | ||
+ | |- | ||
! Ada | ! Ada | ||
+ | | | ||
+ | | | ||
+ | | | ||
+ | | {{yes}}<ref name="gcc-supported-languages">https://gcc.gnu.org/onlinedocs/gcc-13.2.0/gcc/G_002b_002b-and-GCC.html</ref> | ||
+ | | | ||
+ | | {{yes}} | ||
+ | | {{yes|GCC}}<ref>At the FOSDEM 2023 I was told at the Ada table that it worked fine on microcontrollers with 16k of RAM, and that it was widely used in microcontrollers. The table also had several microcontroller boards.</ref> | ||
+ | | {{yes}}<ref>The ISO standard specification can be found [http://www.ada-auth.org/arg.html here]. It is provided by the ARG (Ada Rapporteur Group) free of charge and the license allows for modifications and reproductions while requiring the license to be reproduced.</ref> | ||
+ | |- | ||
! C | ! C | ||
+ | | {{yes}} | ||
+ | | {{yes}} | ||
+ | | {{yes}} | ||
+ | | {{yes}}<ref name="gcc-supported-languages"></ref> | ||
+ | | | ||
+ | * [https://packages.guix.gnu.org/packages/cc65/ cc65] | ||
+ | * [https://packages.guix.gnu.org/packages/clang/ clang] | ||
+ | * [https://packages.guix.gnu.org/packages/dev86/ dev86] | ||
+ | * [https://packages.guix.gnu.org/packages/mes mes] | ||
+ | * [https://packages.guix.gnu.org/packages/tcc tcc] | ||
+ | * [https://packages.guix.gnu.org/packages/sdcc sdcc] | ||
+ | | {{yes|defaults to shared libraries}} | ||
+ | | {{yes|GCC, SDCC}} | ||
+ | | {{Orange|Drafts are available gratis, probably not under free licenses.}}<ref>Ideally the specifications should be available under free licenses.</ref> | ||
+ | |- | ||
! C++ | ! C++ | ||
+ | | {{yes}} | ||
+ | | {{yes}} | ||
+ | | {{yes}} | ||
+ | | {{yes}}<ref name="gcc-supported-languages"></ref> | ||
+ | | | ||
+ | | {{yes|defaults to shared libraries}} | ||
+ | | {{yes|GCC, other?}} | ||
+ | | ? | ||
+ | |- | ||
! D | ! D | ||
+ | | | ||
+ | | | ||
+ | | | ||
+ | | {{yes}}<ref name="gcc-supported-languages"></ref> | ||
+ | | | ||
+ | | | ||
+ | | ? | ||
+ | |- | ||
+ | ! Erlang | ||
+ | | {{yes}} | ||
+ | | | ||
+ | | | ||
+ | | {{no}}<ref name="gcc-supported-languages"></ref> | ||
+ | | | ||
+ | | | ||
+ | | | ||
+ | | ? | ||
+ | |- | ||
! Fortran | ! Fortran | ||
+ | | {{yes|Fortran 77, Fortran 90, Fortran 95}} | ||
+ | | {{yes|Fortran 77, Fortran 9x}} | ||
+ | | {{yes|Fortran, Fortran 77}} | ||
+ | | {{yes}}<ref name="gcc-supported-languages"></ref> | ||
+ | | | ||
+ | | | ||
+ | | | ||
+ | | ? | ||
+ | |- | ||
+ | ! GNU C | ||
+ | | {{yes}} | ||
+ | | {{yes}} | ||
+ | | {{yes}} | ||
+ | | {{yes}}<ref name="gcc-supported-languages"></ref> | ||
+ | | | ||
+ | * [https://packages.guix.gnu.org/packages/clang/ clang]<ref>https://clang.llvm.org/features.html#gcccompat</ref> | ||
+ | * [https://packages.guix.gnu.org/packages/tcc tcc] | ||
+ | | {{yes|defaults to shared libraries}} | ||
+ | | {{yes|GCC}} | ||
+ | | {{yes|Documented under the GFDL.}}<ref>https://www.gnu.org/software/gnu-c-manual/</ref> | ||
+ | |- | ||
! Go | ! Go | ||
− | + | | {{yes|basic support for gccgo}} | |
− | + | | {{orange|no}}<ref>While automake isn't supported, it's still possible to use it if we add a rule to handle .go files in our Makefile.am. [https://mail.gnu.org/archive/html/automake-patches/2001-07/msg00012.html For some reasons] we then also need to add link rules for every program/library we create. I've created a [https://framagit.org/GNUtoo/autotools-go-hello-world autotools-go-hello-world] project to show how to use autoconf and automake together with go. Note that I didn't look if that scaled well or the limitations in more complex projects. For instance I'm unsure how to handle shared libraries, how to link to dependencies, etc.</ref> | |
− | + | | {{yes}} | |
− | + | | {{yes}}<ref name="gcc-supported-languages"></ref> | |
+ | | | ||
+ | | | ||
+ | | ? | ||
|- | |- | ||
− | ! | + | ! Java |
+ | | | ||
+ | | {{yes|with CGJ}} | ||
+ | | {{yes|with CGJ}} | ||
+ | | {{no}}<ref name="gcc-supported-languages"></ref><ref>The last GCC version supporting GCJ seems to be 6.5.0: https://gcc.gnu.org/onlinedocs/gcc-6.5.0/gcc/G_002b_002b-and-GCC.html#G_002b_002b-and-GCC</ref> | ||
+ | | | ||
| | | | ||
+ | | ? | ||
+ | |- | ||
+ | ! Objective-C | ||
| {{yes}} | | {{yes}} | ||
| {{yes}} | | {{yes}} | ||
| | | | ||
− | | {{yes | + | | {{yes}}<ref name="gcc-supported-languages"></ref> |
− | | | + | | |
+ | | | ||
+ | | | ||
+ | | ? | ||
+ | |- | ||
+ | ! Objective-C++ | ||
| {{yes}} | | {{yes}} | ||
| {{yes}} | | {{yes}} | ||
+ | | | ||
+ | | {{yes}}<ref name="gcc-supported-languages"></ref> | ||
+ | | | ||
+ | | | ||
+ | | | ||
+ | | ? | ||
+ | |- | ||
+ | ! Rust | ||
| {{no}} | | {{no}} | ||
+ | | {{no}} | ||
+ | | {{no}} | ||
+ | | {{no|Work in progress}}<ref name="gcc-supported-languages"></ref> | ||
+ | | | ||
+ | | | ||
+ | | | ||
+ | | {{no}}<ref>See one of the two talks on rust in [https://gcc.gnu.org/wiki/cauldron2022 GNU cauldron 2022].</ref> | ||
+ | |- | ||
+ | ! Unified Parallel C. | ||
+ | | | ||
| {{yes|partial}} | | {{yes|partial}} | ||
+ | | | ||
+ | | {{no}}<ref name="gcc-supported-languages"></ref> | ||
+ | | | ||
+ | | | ||
+ | | | ||
+ | | ? | ||
+ | |- | ||
+ | ! Vala | ||
+ | | | ||
+ | | {{yes|partial}} | ||
+ | | | ||
+ | | {{yes|valac uses GCC}} | ||
+ | | | ||
+ | * [https://packages.guix.gnu.org/packages/vala/ valac] | ||
+ | | | ||
+ | | {{no|depends on glib}} | ||
+ | | ? | ||
+ | |- | ||
+ | |} | ||
+ | |||
+ | === Compilers bootstraping === | ||
+ | |||
+ | {| border="0" style="font-size: smaller" | ||
+ | |- bgcolor="#6699ff" | ||
+ | ! Compiler | ||
+ | ! Languages | ||
+ | ! Dependencies | ||
+ | |- | ||
+ | | gcc-ada | ||
+ | | | ||
+ | * Ada | ||
+ | | {{no|Depends on gcc-ada}} | ||
+ | |- | ||
+ | | nim | ||
+ | | | ||
+ | * nim | ||
+ | | {{orange|nim depends on itself but translated C files are provided by upstream}} | ||
+ | |- | ||
+ | | valac | ||
+ | | | ||
+ | * vala | ||
+ | | {{orange|valac depends on itself but translated C files are provided by upstream}} | ||
+ | |} | ||
+ | |||
+ | === Interpreters features and languages === | ||
+ | {| border="0" style="font-size: smaller" | ||
+ | |- bgcolor="#6699ff" | ||
+ | ! Language | ||
+ | ! Interpreter | ||
+ | ! Dependencies | ||
+ | ! Microcontrollers<ref name="microcontrollers"></ref> | ||
+ | ! Strict specifications<ref name="strict-specifications"></ref> | ||
+ | |- | ||
+ | ! Perl | ||
+ | | Perl | ||
+ | | {{yes|C, some C libraries}} | ||
+ | | {{no}} | ||
+ | | {{no}}<ref>From [https://en.wikipedia.org/wiki/Perl#Implementation Wikipedia article on perl]: "No written specification or standard for the Perl language exists for Perl versions through Perl 5"</ref> | ||
+ | |- | ||
+ | ! rowspan="2" | Python | ||
+ | | CPython | ||
+ | | {{yes|C, some C libraries}} | ||
+ | | {{no}} | ||
+ | ! rowspan="2" | ? | ||
|- | |- | ||
− | + | | MicroPython | |
+ | | {{yes|C, some C libraries}} | ||
| {{yes}} | | {{yes}} | ||
+ | |- | ||
+ | |} | ||
+ | |||
+ | == Build system status == | ||
+ | |||
+ | {| border="0" style="font-size: smaller" | ||
+ | |- bgcolor="#6699ff" | ||
+ | ! Build system | ||
+ | ! Cross compilation | ||
+ | ! Easy to support in distributions | ||
+ | ! Targets | ||
+ | |- | ||
+ | ! Autotools | ||
| {{yes}} | | {{yes}} | ||
| {{yes}} | | {{yes}} | ||
+ | | | ||
+ | * Most Posix-like systems<ref>Autotools contains *a lot* of information and/or workarounds on how to support most Posix-like systems, including less well known systems. See the [https://www.gnu.org/savannah-checkouts/gnu/autoconf/manual/autoconf-2.71/autoconf.html] and [https://www.gnu.org/software/automake/manual/automake.html automake] manuals for more details.</ref>. | ||
+ | * Windows support possible, but it requires special care<ref>https://autotools.info/libtool/windows.html</ref>. | ||
+ | |- | ||
+ | ! setup.py | ||
+ | | ? | ||
| {{yes}} | | {{yes}} | ||
− | | {{yes}} | + | |} |
− | | {{yes}} | + | |
− | | {{yes}} | + | == Didstributions status == |
− | | {{ | + | |
− | | {{no| | + | === Guix status === |
− | | {{yes| | + | |
+ | Guix is the most strict FSDG compliant distribution with regard to languages support: it requires the bootstrap process to be reproducible. | ||
+ | |||
+ | While there are still binary compilers being used in the bootstrap process for some languages, other languages are completely bootstrapped from source. | ||
+ | |||
+ | {| border="0" style="font-size: smaller" | ||
+ | <!-- Below is the column for easy copy-paste and replacement --> | ||
+ | <!-- Language --> | ||
+ | <!-- Toolchain --> | ||
+ | <!-- GNU/Hurd i586 --> | ||
+ | <!-- GNU/Linux armv7h --> | ||
+ | <!-- GNU/Linux aarch64 --> | ||
+ | <!-- GNU/Linux i686 --> | ||
+ | <!-- GNU/Linux mips64el --> | ||
+ | <!-- GNU/Linux powerpc --> | ||
+ | <!-- GNU/Linux powerpc64le --> | ||
+ | <!-- GNU/Linux riscv64 --> | ||
+ | <!-- GNU/Linux x86_64 --> | ||
+ | <!-- Mingw i686 --> | ||
+ | <!-- Mingw x86_64 --> | ||
+ | |- bgcolor="#6699ff" | ||
+ | ! Language | ||
+ | ! Toolchain | ||
+ | ! GNU/Hurd i586 | ||
+ | ! GNU/Linux armv7h | ||
+ | ! GNU/Linux aarch64 | ||
+ | ! GNU/Linux i686 | ||
+ | ! GNU/Linux mips64el | ||
+ | ! GNU/Linux powerpc | ||
+ | ! GNU/Linux powerpc64le | ||
+ | ! GNU/Linux riscv64 | ||
+ | ! GNU/Linux x86_64 | ||
+ | ! Mingw i686 | ||
+ | ! Mingw x86_64 | ||
+ | |- | ||
+ | | Ada | ||
+ | | {{no}} | ||
+ | |- | ||
+ | | C | ||
+ | | gcc-toolchain | ||
+ | | {{Orange}} | ||
+ | | {{Orange}} | ||
+ | | {{Orange}} | ||
+ | | {{Yes|Bootstraped from source with a 25 MiB Guile binary.}}<ref name="reduced-binary-seed-manual-section">https://guix.gnu.org/en/blog/2023/the-full-source-bootstrap-building-from-source-all-the-way-down</ref> | ||
+ | | {{Orange}} | ||
+ | | {{Orange}} | ||
+ | | {{Orange}} | ||
+ | | {{Orange}} | ||
+ | | {{Yes|Bootstraped from source with a 25 MiB Guile binary}}<ref name="reduced-binary-seed-manual-section"></ref> | ||
+ | | {{Orange}} | ||
+ | | {{Orange}} | ||
+ | |- | ||
+ | | C# | ||
+ | | {{no}} | ||
+ | |- | ||
+ | | Haskell | ||
+ | | ghc | ||
+ | | {{no}} | ||
+ | | {{no}} | ||
+ | | {{no}} | ||
+ | | {{Orange|Bootstrapped from generated C code}}<ref name="guix-ghc-4">https://git.savannah.gnu.org/cgit/guix.git/tree/gnu/packages/haskell.scm?h=v1.4.0#n363</ref> | ||
+ | | {{no}} | ||
+ | | {{no}} | ||
+ | | {{no}} | ||
+ | | {{no}} | ||
+ | | {{Orange|Bootstrapped from generated C code}}<ref name="guix-ghc-4"></ref> | ||
+ | | {{no}} | ||
+ | | {{no}} | ||
+ | |- | ||
+ | | Java | ||
+ | | openjdk | ||
+ | | ? | ||
+ | | ? | ||
+ | | ? | ||
+ | | {{yes|bootstraped from source}}<ref name="opejdk-bootstrap">In gnu/packages/java.scm icedtea-7 depends on jamvm which depends on jamvm-1-bootstrap which is built from source. The source bootstrap is not architecture specific.</ref> | ||
+ | | ? | ||
+ | | ? | ||
+ | | ? | ||
+ | | ? | ||
+ | | {{yes|bootstraped from source}}<ref name="opejdk-bootstrap"></ref> | ||
+ | | ? | ||
+ | | ? | ||
+ | |- | ||
+ | | colspan="2" | nim | ||
+ | | ? | ||
+ | | ? | ||
+ | | ? | ||
+ | | {{Orange|Bootstrapped from generated C code}}<ref name="nim">Both the [https://packages.guix.gnu.org/packages/nim/ Guix package] and the [https://nim-lang.org/install_unix.html#source-archive official build instructions] use the build.sh script that compiles code (in the c_code directory) that has been generated with the nim compiler.</ref> | ||
+ | | ? | ||
+ | | ? | ||
+ | | ? | ||
+ | | ? | ||
+ | | {{Orange|Bootstrapped from generated C code}}<ref name="nim"></ref> | ||
+ | | ? | ||
+ | | ? | ||
+ | |- | ||
+ | | Rust | ||
+ | | rustc | ||
+ | | {{no}}<ref name="rust-1.54-bootstrap">See supported-systems in the rust 1.54 package definition</ref> | ||
+ | | {{no}}<ref name="rust-1.54-bootstrap"></ref> | ||
+ | | {{yes|Bootstrapped from source with mrustc}}<ref name="rust-1.54-bootstrap"></ref> | ||
+ | | {{no}}<ref name="rust-1.54-bootstrap"></ref> | ||
+ | | {{no}}<ref name="rust-1.54-bootstrap"></ref> | ||
+ | | {{no}}<ref name="rust-1.54-bootstrap"></ref> | ||
+ | | {{no}}<ref name="rust-1.54-bootstrap"></ref> | ||
+ | | {{yes|Bootstrapped from source with mrustc}}<ref name="rust-1.54-bootstrap"></ref> | ||
+ | | {{yes|Bootstrapped from source with mrustc}}<ref name="rust-1.54-bootstrap"></ref> | ||
+ | | {{no}}<ref name="rust-1.54-bootstrap"></ref> | ||
+ | | {{no}}<ref name="rust-1.54-bootstrap"></ref> | ||
|- | |- | ||
− | + | | vala | |
+ | | valac | ||
+ | | ? | ||
| ? | | ? | ||
− | |||
| ? | | ? | ||
+ | | {{Orange|Bootstrapped from generated C code}}<ref name="vala">The vala source code contains C files generated from vala source code that is also present in that source code. Since the [https://packages.guix.gnu.org/packages/vala/ Guix package] and the README.md included in the vala source code require a C compiler but not a vala compiler to compile vala, the C code is then used to build it.</ref> | ||
| ? | | ? | ||
| ? | | ? | ||
| ? | | ? | ||
| ? | | ? | ||
+ | | {{Orange|Bootstrapped from generated C code}}<ref name="vala"></ref> | ||
| ? | | ? | ||
− | |||
| ? | | ? | ||
|} | |} | ||
+ | |||
+ | === Parabola status === | ||
+ | |||
+ | Parabola has a policy which requires all the packages to be built from source. But it doesn't have a policy to reduce the size of the bootstrap binaries, so there can be circular dependencies. | ||
+ | |||
+ | {| border="0" style="font-size: smaller" | ||
+ | <!-- Below is the column for easy copy-paste and replacement --> | ||
+ | <!-- Language --> | ||
+ | <!-- Toolchain --> | ||
+ | <!-- GNU/Linux armv7h --> | ||
+ | <!-- GNU/Linux i686 --> | ||
+ | <!-- GNU/Linux x86_64 --> | ||
+ | |- bgcolor="#6699ff" | ||
+ | ! Language | ||
+ | ! Toolchain | ||
+ | ! GNU/Linux armv7h | ||
+ | ! GNU/Linux i686 | ||
+ | ! GNU/Linux x86_64 | ||
+ | |- | ||
+ | | Ada | ||
+ | | gcc-ada | ||
+ | | {{no}} | ||
+ | | {{yes}} | ||
+ | | {{yes}} | ||
+ | |- | ||
+ | | C | ||
+ | | gcc-toolchain | ||
+ | | {{yes}} | ||
+ | | {{yes}} | ||
+ | | {{yes}} | ||
+ | |- | ||
+ | | C# | ||
+ | | mono | ||
+ | | {{yes}} | ||
+ | | {{yes}} | ||
+ | | {{yes}} | ||
+ | |- | ||
+ | | Haskell | ||
+ | | ghc | ||
+ | | {{no}} | ||
+ | | {{yes}} | ||
+ | | {{yes}} | ||
+ | |- | ||
+ | | Java | ||
+ | | openjdk | ||
+ | | {{yes}} | ||
+ | | {{yes}} | ||
+ | | {{yes}} | ||
+ | |- | ||
+ | | colspan="2"| nim | ||
+ | | {{yes}} | ||
+ | | {{yes}} | ||
+ | | {{yes}} | ||
+ | |- | ||
+ | | Ruby | ||
+ | | ruby | ||
+ | | {{yes}}<ref name="parabola-ruby">Before it was broken due to the removal of rubygems, but it now works agains thanks to libre/ruby.</ref> | ||
+ | | {{yes}}<ref name="parabola-ruby"></ref> | ||
+ | | {{yes}}<ref name="parabola-ruby"></ref> | ||
+ | |- | ||
+ | | Rust | ||
+ | | rustc | ||
+ | | {{yes}} | ||
+ | | {{yes}} | ||
+ | | {{yes}} | ||
+ | |- | ||
+ | | Vala | ||
+ | | valac | ||
+ | | {{yes}} | ||
+ | | {{yes}} | ||
+ | | {{yes}} | ||
+ | |- | ||
+ | |} | ||
+ | |||
+ | == Trisquel 11 (aramo) == | ||
+ | |||
+ | {| border="0" style="font-size: smaller" | ||
+ | <!-- Below is the column for easy copy-paste and replacement --> | ||
+ | <!-- Language --> | ||
+ | <!-- Toolchain --> | ||
+ | <!-- amd64 --> | ||
+ | <!-- arm64 --> | ||
+ | <!-- armhf --> | ||
+ | <!-- ppc64el --> | ||
+ | |- bgcolor="#6699ff" | ||
+ | ! Language | ||
+ | ! Toolchain | ||
+ | ! amd64 | ||
+ | ! arm64 | ||
+ | ! armhf | ||
+ | ! ppc64el | ||
+ | |- | ||
+ | | Ada | ||
+ | | [https://packages.trisquel.org/aramo/gnat gcc-ada] | ||
+ | | {{yes}} | ||
+ | | {{yes}} | ||
+ | | {{yes}} | ||
+ | | {{yes}} | ||
+ | |- | ||
+ | | C# | ||
+ | | [https://packages.trisquel.org/aramo/all/mono-mcs mono] | ||
+ | | {{yes}}<ref name="mono-mcs">mono-mcs is architecture independent. It depends on packages like [https://packages.trisquel.org/aramo/mono-runtime mono-runtime] which works on amd64, arm64, armhf, ppc64el.</ref> | ||
+ | | {{yes}}<ref name="mono-mcs"></ref> | ||
+ | | {{yes}}<ref name="mono-mcs"></ref> | ||
+ | | {{yes}}<ref name="mono-mcs"></ref> | ||
+ | |- | ||
+ | | Haskell | ||
+ | | [https://packages.trisquel.org/aramo/ghc ghc] | ||
+ | | {{yes}} | ||
+ | | {{yes}} | ||
+ | | {{yes}} | ||
+ | | {{yes}} | ||
+ | |} | ||
+ | |||
+ | == Standalone toolchains == | ||
+ | |||
+ | {| border="1" style="font-size: smaller" | ||
+ | ! Programming languages | ||
+ | ! Distributor | ||
+ | ! Release | ||
+ | | Host | ||
+ | | Target | ||
+ | | Source code review | ||
+ | |- | ||
+ | | rowspan=5 | | ||
+ | * Ada | ||
+ | | rowspan=5 | Adacore | ||
+ | | rowspan=5 | [https://www.adacore.com/download/more 2021]<ref>This release also had additional hosts like Windows and darwin, and additional targets too like "Raspberry Pi 2 Linux (32bits)" but I didn't look into them.</ref> | ||
+ | | GNU/Linux (i686?) | ||
+ | | ARM ELF 32bit | ||
+ | | rowspan=5 | | ||
+ | {| border="1" style="font-size: smaller" | ||
+ | ! Source<ref>Here we used GNU/Linux x86_64 host and target source code for the review. I hope that all the host/target combination have the same source but I didn't check.</ref> | ||
+ | ! License<ref>So far I used 'guix package --show=<package-name>' to find the license. I also didn't check license compatibilities.</ref> | ||
+ | |- | ||
+ | | als-2021-20210701-19A88-src.tar.gz | ||
+ | | | ||
+ | |- | ||
+ | | alt-ergo-for-spark-2021-20210518-19982-src.tar.gz | ||
+ | | | ||
+ | |- | ||
+ | | antlr-3.4-complete.jar | ||
+ | | | ||
+ | |- | ||
+ | | aunit-2021-20210518-19DC5-src.tar.gz | ||
+ | | | ||
+ | |- | ||
+ | | aws-2021-20210518-19F65-src.tar.gz | ||
+ | | | ||
+ | |- | ||
+ | | bb-runtimes-2021-20210518-19CE8-src.tar.gz | ||
+ | | | ||
+ | |- | ||
+ | | binutils-2.33.50s-2021-20210518-19EF2-src.tar.gz | ||
+ | | {{yes|GPL 3+}} | ||
+ | |- | ||
+ | | colibri-2021-20210518-19CDE-src.tar.gz | ||
+ | | | ||
+ | |- | ||
+ | | cvc4-2021-20210518-19B60-src.tar.gz | ||
+ | | | ||
+ | |- | ||
+ | | expat-2.2.6.tar.bz2 | ||
+ | | {{yes|Expat}} | ||
+ | |- | ||
+ | | gcc-10-2021-20210519-19A74-src.tar.gz | ||
+ | | {{yes|GPL 3+}} | ||
+ | |- | ||
+ | | gcc-interface-10-2021-20210519-19A75-src.tar.gz | ||
+ | | | ||
+ | |- | ||
+ | | gdb-10-2021-20210518-19C88-src.tar.gz | ||
+ | | {{yes|GPL 3+}} | ||
+ | |- | ||
+ | | gmp-6.1.2.tar.bz2 | ||
+ | | {{yes|LGPL 3+}} | ||
+ | |- | ||
+ | | gnat-2021-20210519-19A70-src.tar.gz | ||
+ | | | ||
+ | |- | ||
+ | | gnatcoll-bindings-2021-20210518-19B15-src.tar.gz | ||
+ | | | ||
+ | |- | ||
+ | | gnatcoll-core-2021-20210518-19ADF-src.tar.gz | ||
+ | | | ||
+ | |- | ||
+ | | gnatmem-2021-20210518-19F7B-src.tar.gz | ||
+ | | | ||
+ | |- | ||
+ | | gnatsymbolize-2021-20210518-19D3B-src.tar.gz | ||
+ | | | ||
+ | |- | ||
+ | | gprbuild-2021-20210519-19A34-src.tar.gz | ||
+ | | | ||
+ | |- | ||
+ | | gps-2021-20210701-19B6B-src.tar.gz | ||
+ | | | ||
+ | |- | ||
+ | | langkit-2021-20210518-19B8E-src.tar.gz | ||
+ | | | ||
+ | |- | ||
+ | | libadalang-2021-20210518-199BE-src.tar.gz | ||
+ | | | ||
+ | |- | ||
+ | | libadalang-tools-2021-20210519-19A69-src.tar.gz | ||
+ | | | ||
+ | |- | ||
+ | | libantlr3c-3.4.tar.gz | ||
+ | | {{yes|Modified BSD}} | ||
+ | |- | ||
+ | | libffi-3.2.1-patched.tar.gz | ||
+ | | {{yes|Expat}} | ||
+ | |- | ||
+ | | libiconv-1.15.tar.gz | ||
+ | | {{yes|LGPL 3+}} | ||
+ | |- | ||
+ | | mpc-1.0.3.tar.gz | ||
+ | | {{yes|LGPL 3+}} | ||
+ | |- | ||
+ | | mpfr-3.1.5.tar.bz2 | ||
+ | | {{yes|LGPL 3+}} | ||
+ | |- | ||
+ | | opam-ocaml-4-11-1-2021-20210518-19D84-src.tar.gz | ||
+ | | {{orange|LGPL 3, It's a package manager for OCaml, so its repository may need to be reviewed as well.}} | ||
+ | |- | ||
+ | | spark-2021-2021-20210519-19A1A-src.tar.gz | ||
+ | | | ||
+ | |- | ||
+ | | spawn-2021-20210701-19A43-src.tar.gz | ||
+ | | | ||
+ | |- | ||
+ | | sqlite-autoconf-3270200.tar.gz | ||
+ | | | ||
+ | |- | ||
+ | | vss-2021-20210701-198AA-src.tar.gz | ||
+ | | | ||
+ | |- | ||
+ | | why3-2021-20210519-19ADF-src.tar.gz | ||
+ | | | ||
+ | |- | ||
+ | | xmlada-2021-20210518-19D50-src.tar.gz | ||
+ | | {{yes|LGPL 2.1}} | ||
+ | |- | ||
+ | | xz-5.2.2.tar.gz | ||
+ | | {{yes|GPL 2+, LGPL 2.1+}} | ||
+ | |- | ||
+ | | z3-2021-20210518-1A000-src.tar.gz | ||
+ | | {{yes|Expat}} | ||
+ | |- | ||
+ | | zlib-1.2.6.tar.gz | ||
+ | | {{yes|Zlib}} | ||
+ | |- | ||
+ | |} | ||
+ | |- | ||
+ | | colspan=2 | GNU/Linux i686 | ||
+ | |- | ||
+ | | GNU/Linux x86_64 | ||
+ | | RISCV ELF 32bit | ||
+ | |- | ||
+ | | GNU/Linux x86_64 | ||
+ | | RISCV ELF 64bit | ||
+ | |- | ||
+ | | colspan=2 | GNU/Linux x86_64 | ||
+ | |} | ||
+ | |||
+ | == References == | ||
+ | |||
+ | <references /> |
Latest revision as of 11:15, 13 September 2024
Contents
Introduction
The goal of this page is to understand the status of various programming languages and toolchains. It can help people deciding on a programming language to choose or to learn, or enable people to understand where distributions need contributions to support well a language.
It could also contain information on what language works where or if we can target specific operating systems with free software or not.
Toolchain status
Compilers features and languages
Language | Autoconf | Automake | Libtool[1] | GCC 13 support[2] | Other free compilers | Shared libraries[3] | Microcontrollers[4] | Strict specifications[5] |
---|---|---|---|---|---|---|---|---|
Ada | Yes[6] | Yes | GCC[7] | Yes[8] | ||||
C | Yes | Yes | Yes | Yes[6] | defaults to shared libraries | GCC, SDCC | Drafts are available gratis, probably not under free licenses.[9] | |
C++ | Yes | Yes | Yes | Yes[6] | defaults to shared libraries | GCC, other? | ? | |
D | Yes[6] | ? | ||||||
Erlang | Yes | No[6] | ? | |||||
Fortran | Fortran 77, Fortran 90, Fortran 95 | Fortran 77, Fortran 9x | Fortran, Fortran 77 | Yes[6] | ? | |||
GNU C | Yes | Yes | Yes | Yes[6] | defaults to shared libraries | GCC | Documented under the GFDL.[11] | |
Go | basic support for gccgo | no[12] | Yes | Yes[6] | ? | |||
Java | with CGJ | with CGJ | No[6][13] | ? | ||||
Objective-C | Yes | Yes | Yes[6] | ? | ||||
Objective-C++ | Yes | Yes | Yes[6] | ? | ||||
Rust | No | No | No | Work in progress[6] | No[14] | |||
Unified Parallel C. | partial | No[6] | ? | |||||
Vala | partial | valac uses GCC | depends on glib | ? |
Compilers bootstraping
Compiler | Languages | Dependencies |
---|---|---|
gcc-ada |
|
Depends on gcc-ada |
nim |
|
nim depends on itself but translated C files are provided by upstream |
valac |
|
valac depends on itself but translated C files are provided by upstream |
Interpreters features and languages
Language | Interpreter | Dependencies | Microcontrollers[4] | Strict specifications[5] |
---|---|---|---|---|
Perl | Perl | C, some C libraries | No | No[15] |
Python | CPython | C, some C libraries | No | ? |
MicroPython | C, some C libraries | Yes |
Build system status
Build system | Cross compilation | Easy to support in distributions | Targets |
---|---|---|---|
Autotools | Yes | Yes | |
setup.py | ? | Yes |
Didstributions status
Guix status
Guix is the most strict FSDG compliant distribution with regard to languages support: it requires the bootstrap process to be reproducible.
While there are still binary compilers being used in the bootstrap process for some languages, other languages are completely bootstrapped from source.
Language | Toolchain | GNU/Hurd i586 | GNU/Linux armv7h | GNU/Linux aarch64 | GNU/Linux i686 | GNU/Linux mips64el | GNU/Linux powerpc | GNU/Linux powerpc64le | GNU/Linux riscv64 | GNU/Linux x86_64 | Mingw i686 | Mingw x86_64 |
---|---|---|---|---|---|---|---|---|---|---|---|---|
Ada | No | |||||||||||
C | gcc-toolchain | Yes | Yes | Yes | Bootstraped from source with a 25 MiB Guile binary.[18] | Yes | Yes | Yes | Yes | Bootstraped from source with a 25 MiB Guile binary[18] | Yes | Yes |
C# | No | |||||||||||
Haskell | ghc | No | No | No | Bootstrapped from generated C code[19] | No | No | No | No | Bootstrapped from generated C code[19] | No | No |
Java | openjdk | ? | ? | ? | bootstraped from source[20] | ? | ? | ? | ? | bootstraped from source[20] | ? | ? |
nim | ? | ? | ? | Bootstrapped from generated C code[21] | ? | ? | ? | ? | Bootstrapped from generated C code[21] | ? | ? | |
Rust | rustc | No[22] | No[22] | Bootstrapped from source with mrustc[22] | No[22] | No[22] | No[22] | No[22] | Bootstrapped from source with mrustc[22] | Bootstrapped from source with mrustc[22] | No[22] | No[22] |
vala | valac | ? | ? | ? | Bootstrapped from generated C code[23] | ? | ? | ? | ? | Bootstrapped from generated C code[23] | ? | ? |
Parabola status
Parabola has a policy which requires all the packages to be built from source. But it doesn't have a policy to reduce the size of the bootstrap binaries, so there can be circular dependencies.
Language | Toolchain | GNU/Linux armv7h | GNU/Linux i686 | GNU/Linux x86_64 |
---|---|---|---|---|
Ada | gcc-ada | No | Yes | Yes |
C | gcc-toolchain | Yes | Yes | Yes |
C# | mono | Yes | Yes | Yes |
Haskell | ghc | No | Yes | Yes |
Java | openjdk | Yes | Yes | Yes |
nim | Yes | Yes | Yes | |
Ruby | ruby | Yes[24] | Yes[24] | Yes[24] |
Rust | rustc | Yes | Yes | Yes |
Vala | valac | Yes | Yes | Yes |
Trisquel 11 (aramo)
Language | Toolchain | amd64 | arm64 | armhf | ppc64el |
---|---|---|---|---|---|
Ada | gcc-ada | Yes | Yes | Yes | Yes |
C# | mono | Yes[25] | Yes[25] | Yes[25] | Yes[25] |
Haskell | ghc | Yes | Yes | Yes | Yes |
Standalone toolchains
Programming languages | Distributor | Release | Host | Target | Source code review | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
Adacore | 2021[26] | GNU/Linux (i686?) | ARM ELF 32bit |
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
GNU/Linux i686 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
GNU/Linux x86_64 | RISCV ELF 32bit | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
GNU/Linux x86_64 | RISCV ELF 64bit | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
GNU/Linux x86_64 |
References
- ↑ libtool is part of the autotools and it abstracts linking to make it work on a lot of operating systems. The status of the programming languages other than C and C++ can be found here: https://www.gnu.org/software/libtool/manual/libtool.html#Tags
- ↑ Compared with other compilers like LLVM and rustc, GCC supports many CPU architectures and it's quite well integrated with various other software (gdb, gprof, build systems, etc). It also has long term support in mind as it continues to support other programming language standards. It also has good documentation that explain how it handles C code for instance. In addition it's a GNU project, so it has users freedom in mind. In addition Guix has made GCC bootstrapable from a binary that is less than 1KB, and it doesn't require huge resources to build or bootstrap.
- ↑ 4.04.1 Can we compile and/or run code for/on microcontrollers, if so which compilers/interpreters are used / necessary for that.
- ↑ 5.05.1 Having a standard or something similar to refer to enables people to write code that can still be used without requiring too much maintenance to adapt to newer compiler versions.
- ↑ 6.006.016.026.036.046.056.066.076.086.096.106.116.12 https://gcc.gnu.org/onlinedocs/gcc-13.2.0/gcc/G_002b_002b-and-GCC.html
- ↑ At the FOSDEM 2023 I was told at the Ada table that it worked fine on microcontrollers with 16k of RAM, and that it was widely used in microcontrollers. The table also had several microcontroller boards.
- ↑ The ISO standard specification can be found here. It is provided by the ARG (Ada Rapporteur Group) free of charge and the license allows for modifications and reproductions while requiring the license to be reproduced.
- ↑ Ideally the specifications should be available under free licenses.
- ↑ https://clang.llvm.org/features.html#gcccompat
- ↑ https://www.gnu.org/software/gnu-c-manual/
- ↑ While automake isn't supported, it's still possible to use it if we add a rule to handle .go files in our Makefile.am. For some reasons we then also need to add link rules for every program/library we create. I've created a autotools-go-hello-world project to show how to use autoconf and automake together with go. Note that I didn't look if that scaled well or the limitations in more complex projects. For instance I'm unsure how to handle shared libraries, how to link to dependencies, etc.
- ↑ The last GCC version supporting GCJ seems to be 6.5.0: https://gcc.gnu.org/onlinedocs/gcc-6.5.0/gcc/G_002b_002b-and-GCC.html#G_002b_002b-and-GCC
- ↑ See one of the two talks on rust in GNU cauldron 2022.
- ↑ From Wikipedia article on perl: "No written specification or standard for the Perl language exists for Perl versions through Perl 5"
- ↑ Autotools contains *a lot* of information and/or workarounds on how to support most Posix-like systems, including less well known systems. See the [1] and automake manuals for more details.
- ↑ https://autotools.info/libtool/windows.html
- ↑ 18.018.1 https://guix.gnu.org/en/blog/2023/the-full-source-bootstrap-building-from-source-all-the-way-down
- ↑ 19.019.1 https://git.savannah.gnu.org/cgit/guix.git/tree/gnu/packages/haskell.scm?h=v1.4.0#n363
- ↑ 20.020.1 In gnu/packages/java.scm icedtea-7 depends on jamvm which depends on jamvm-1-bootstrap which is built from source. The source bootstrap is not architecture specific.
- ↑ 21.021.1 Both the Guix package and the official build instructions use the build.sh script that compiles code (in the c_code directory) that has been generated with the nim compiler.
- ↑ 22.0022.0122.0222.0322.0422.0522.0622.0722.0822.0922.10 See supported-systems in the rust 1.54 package definition
- ↑ 23.023.1 The vala source code contains C files generated from vala source code that is also present in that source code. Since the Guix package and the README.md included in the vala source code require a C compiler but not a vala compiler to compile vala, the C code is then used to build it.
- ↑ 24.024.124.2 Before it was broken due to the removal of rubygems, but it now works agains thanks to libre/ruby.
- ↑ 25.025.125.225.3 mono-mcs is architecture independent. It depends on packages like mono-runtime which works on amd64, arm64, armhf, ppc64el.
- ↑ This release also had additional hosts like Windows and darwin, and additional targets too like "Raspberry Pi 2 Linux (32bits)" but I didn't look into them.
- ↑ Here we used GNU/Linux x86_64 host and target source code for the review. I hope that all the host/target combination have the same source but I didn't check.
- ↑ So far I used 'guix package --show=<package-name>' to find the license. I also didn't check license compatibilities.