Skip to content

Releases: modula3/cm3

d5.11.4

21 Dec 13:34
Compare
Choose a tag to compare

See Getting Started for help building and installing this release.

Available downloads:


This release introduces a new installer that supports a simple, source-based distribution containing a bootstrap compiler in C++. Because it is source-based, we only need to provide a small number of downloads to cover all tested systems. And because it includes a bootstrap, we no longer have to provide separate binary and source releases for each platform.

cm3 is now regularly built and tested on ARM.

This release includes a fix for alignment of 64-bit data on 32-bit systems, so that the I368_NT and I386_LINUX platforms now work.

It also includes a number of fixes for formal default and field default array constructors, bringing cm3 more in-line with the language definition.

Finally, there have been many fixes to the compiler test suite.

cm3-d5.11.3-20211007

08 Oct 10:48
Compare
Choose a tag to compare

d5.11.3 is a minor bugfix release, including

  • an important correction to structural typing of records,
  • a fix for static initializers in the C backend, and
  • better support for building on MacOS.

See the Getting Started pages in the wiki for install instructions.

EDIT The most current Windows release can be found here https://github.com/VictorMiasnikov/cm3/releases/tag/d5.11.3_8a842be

Binary releases

Debian-11 or Ubuntu-20.04 (Intel)

Debian-11 or Ubuntu-20.04 (Arm)

Debian-10 or Ubuntu-18.04 (Intel)

MacOS X or MacOS 11 (Intel)

Bootstrap releases

Linux

MacOS

Unix 64-bit little-endian

EDIT https://github.com/modula3/cm3/releases/download/d5.11.3/cm3-boot-unix64le-d5.11.3-20211011.cpp.gz includes a patch for building on Linux/aarch64.

Source releases

cm3-boot-AMD64_MINGW-d5.11.2-20210623

23 Jun 18:59
0350f81
Compare
Choose a tag to compare

This is the first AMD64_MINGW release.
It was an exceedingly small amount of work, building on the C backend.

Prerequisites:
Get Python2 working, such as with:
Install Python2 from somewhere such as python.org or activestate.com or apt-get.
Sometimes required: Install Python from Windows Store. For py.exe. i.e. for msys2 host.

Have a mingw64 toolchain working and in path.
Specifically we need x86_64-w64-mingw32-g++.exe, though this is configurable.
The specific "host" of this toolchain does not matter.
It can be Cygwin, msys2, etc. I used msys2.

To produce the bootstrap:
Have a working cm3 on any platform. I generally use AMD64_NT but they are basically all the same. Linux should work.

  cd scripts/python
  ./boot1.py amd64_mingw # Maybe prefix with "py" e.g. on msys2.

To install the bootstrap:

  tar xf cm3-boot-AMD64_MINGW-d5.11.2-20210623.tgz
  cd cm3-boot-AMD64_MINGW-d5.11.2-20210623
  # Optionally review the top of Makefile
  make -j 
  # Test it, it should print an error about cm3.cfg:
  ./cm3.exe
  # See that debugging works:
  gdb ./cm3.exe
  break main
  r
  q
  # Install it somewhere:
  mkdir -p /c/cm3/bin
  mv cm3.exe /c/cm3/bin
  export PATH=/c/cm3/bin:$PATH
  cd ..
  # Build more. Maybe prefix next with "py" e.g. on msys2.
  ./boot2min.py amd64_mingw
  # Optionally, and again maybe with "py" at start.
  ./do-cm3-all.py buildship amd64_mingw

cm3-unix64le-d5.11.1-20210610

10 Jun 09:26
b3b343c
Compare
Choose a tag to compare

Remember some recurring values:

CM3VER=d5.11.1-20210610
CM3INST=$HOME/cm3 # or /cm3, etc

Download:

wget https://github.com/modula3/cm3/releases/download/unix64le-${CM3VER}/cm3-boot-unix64le-${CM3VER}.cpp.gz
wget https://github.com/modula3/cm3/archive/refs/tags/unix64le-${CM3VER}.tar.gz

The rest:

gunzip cm3-boot-unix64le-${CM3VER}.cpp.gz

g++ -g -pthread -c cm3-boot-unix64le-${CM3VER}.cpp
g++ -g -pthread -o cm3 cm3-boot-unix64le-${CM3VER}.o
sudo rm -rf ${CM3INST}  # optionally remove previous
sudo mkdir -p ${CM3INST}/bin
sudo chown -R $USER ${CM3INST}
mv cm3 ${CM3INST}/bin
tar xf unix64le-${CM3VER}.tar.gz
cd cm3-unix64le-${CM3VER}
# Remove some stuff that is not used.
rm -rf m3-sys/m3cc 
rm -rf m3-sys/m3gdb 
cd scripts/python
sudo apt-get install python2
export PATH=${CM3INST}/bin:$PATH
./boot2min.py c
# At this point you have a working compiler and runtime, and
# "extra" build was done so the compiler built itself.
# And then optionally build more (somewhat error prone).
./do-cm3-all.py buildship c 

The configuration sometimes defaults to using the gcc backend.
Edit ${CM3INST}/bin/cm3.cfg, put this line first:

readonly M3_BACKEND_MODE = "C"

(i.e. for the AMD64 targets, this is already the default for ARM64 and RISCV64).

You will want:

export PATH=${CM3INST}/bin:$PATH

in .bashrc or similar.

This for 64bit little endian Unix.
e.g. Linux, Mac, Solaris, BSD, amd64, arm64, riscv64.
Not all combinations tested.

There is plenty of support for 32bit, big endian, Windows, etc. but this is a sort of "binary" release that does not support everything.

cm3-unix64le-d5.11.0-20210608

09 Jun 04:19
c64c350
Compare
Choose a tag to compare
wget https://github.com/modula3/cm3/releases/download/cm3-d5.11.0-20210608/cm3-boot-unix64le-d5.11.0-20210608.cpp.gz
gunzip cm3-boot-unix64le-d5.11.0-20210608.cpp.gz
g++ -g -pthread -c cm3-boot-unix64le-d5.11.0-20210608.cpp
# This will take a while but should succeed.
g++ -g -pthread -o cm3 cm3-boot-unix64le-d5.11.0-20210608.o
sudo rm -rf /cm3  # optionally remove previous
sudo mkdir -p /cm3/bin
sudo chown -R $USER /cm3
mv cm3 /cm3/bin
wget https://github.com/modula3/cm3/archive/refs/tags/cm3-d5.11.0-20210608.tar.gz 
tar xf cm3-d5.11.0-20210608.tar.gz 
# "cm3" is twice in these paths, the repo and the tag.
cd cm3-cm3-d5.11.0-20210608
# Remove some stuff that is not used.
rm -rf m3-sys/m3cc 
rm -rf m3-sys/m3gdb 
cd scripts/python
sudo apt-get install python2
export PATH=/cm3/bin:$PATH
./boot2min.py c
# At this point you have a working compiler and runtime, and
# "extra" build was done so the compiler built itself.
# And then optionally build more (somewhat error prone).
./do-cm3-all.py buildship c 

The configuration sometimes defaults to using the gcc backend.
Edit /cm3/bin/cm3.cfg, put this line first:

readonly M3_BACKEND_MODE = "C"

(i.e. for the AMD64 targets, this is already the default for ARM64 and RISCV64).

You will want:

export PATH=/cm3/bin:$PATH

in .bashrc or similar.

This for 64bit little endian Unix.
e.g. Linux, amd64, arm64, riscv64.
It was meant to work with Solaris and Mac but this release does not.
It likely works with BSDs but that is not tested.
Directions presume install path and Linux but can be varied.

There is plenty of support for 32bit, big endian, Windows, etc. but this is a sort of "binary" release that does not support everything.
This is the first known release of cm3 of this kind, leveraging the C backend to avoid distributing binaries or assembly and targeting multiple systems with one distribution.

20210312 (March 12 2021)

13 Mar 01:40
Compare
Choose a tag to compare

Windows binary releases for x86 ("Win32") and AMD64 ("Win64").
Several C-based minimal distributions for Linux, Mac, and Windows.
March 12 2021

RISCV64_LINUX-20210227

27 Feb 22:39
Compare
Choose a tag to compare

RISCV64_LINUX-20210227
bootstrapped with C backend from AMD64_NT
Then natively built under qemu-system (qemu usermode is much faster but does not tolerate preemptive suspend)
A few packages skipped for expediency (caltech-other, m3scheme).
.deb also skipped because it failed.

AMD64_DARWIN-20210226

26 Feb 09:53
Compare
Choose a tag to compare

AMD64_DARWIN build Feb 26 2021.
With C backend.
Bootstrapped from AMD64_NT.
Might need a one line change to config, to enable C backend (m3cc is omitted)
i.e. M3_BACKEND_MODE = "C"

ARM64_DARWIN-20210224

24 Feb 18:49
Compare
Choose a tag to compare

ARM64_DARWIN release Feb 24 2021. C backend.
Missing X11/OpenGL/ODBC but Homebrew can likely fix that.

20210223

24 Feb 00:24
Compare
Choose a tag to compare

AMD64_LINUX and I386_LINUX built today with gcc backend.
Bootstrapped from AMD64_NT with boot1.py.
Then boot2.py and make-dist.py on native hosts.

x86 is:
$ lsb_release -a
Distributor ID: Debian
Description: Debian GNU/Linux 10 (buster)
Release: 10
Codename: buster
$ uname -a
Linux debx1 4.19.0-14-686-pae #1 SMP Debian 4.19.171-2 (2021-01-30) i686 GNU/Linux

amd64 is:
$ lsb_release -a
Distributor ID: Ubuntu
Description: Ubuntu 20.04.1 LTS
Release: 20.04
Codename: focal
$ uname -a
Linux ub1 5.4.0-65-generic #73-Ubuntu SMP Mon Jan 18 17:25:17 UTC 2021 x86_64 x86_64 x86_64 GNU/Linux