Skip to content

Building REx

Matthias Melcher edited this page Feb 5, 2022 · 2 revisions

The REx or ROM extension is a key part of Einstein emulator. ROM extensions were designed in NewtonOS to allow third-party manufacturer to bundle drivers and packages in the ROMs. This mechanism is used by Einstein to plug its own drivers for the display, the battery, etc.

Building Einstein REX originally required Apple's Newton C++ tools, just like original ROM extensions by Apple or third-party manufacturers. More recently (in 2020), Einstein REX could be built using more modern toolchains.

The Rex build process has been automated in 2022 using GitHub Workflows. See rex.yml for details.

It requires:

  • gcc cross compilers for arm-none-eabi (arm-none-eabi-gcc, arm-none-eabi-g++) capable of generating armv3 code. Support was dropped in gcc 9.x and therefore this means gcc 8.4 or older.
  • cross binutils for arm-none-eabi (arm-none-eabi-as, arm-none-eabi-objcopy, arm-none-eabi-ld).
  • DCL's ELFtoPKG
  • Newton C++ tools headers from NewtonDev.

Once requirements are satisfied, compilation is as simple as:

cd Drivers
export NCT_PROJECTS=PATH_TO_NEWTONDEV_NCT_PROJECTS
make
make install