If the C bootstrap compiler builds on a 64 bit host (x86-64) but Imp programs don't build, you may need to install the 32-bit libraries, with something like: sudo apt-get install gcc-multilib I was able to build on my home 32/64 linux (x86), but my web host's linux fails with the errors appended after the ####, and unfortunately users do not have permission to install new code on that machine so that's the limit of my testing. === Imp77 is invoked here using the script 'imp2021-c' which calls pass1, pass2, and pass3elf; and if successful (and -c is not given) will link to an x86 executable. HOWEVER the exact options for gcc depend somewhat on how exactly gcc has been installed. If your Imp compilation fails at the linking stage, edit imp202-c and modify it until you can link 32 bit programs successfully. === Note that this bootstrap compiler does *not* install/modify the ld.i77.script file recommended at https://github.com/siliconsam/imp2021/tree/main/build/imp-linux and it seems to work just fine. Frankly I don't understand the instructions below, it's not at all clear what exactly goes in the file and precisely where it goes. We need something like a bash+ecce script to apply the mod automatically. Does "SECTION" go in the file? Does "INSERT BEFORE .data" go in the file or is that an instruction? Does the whole bracketed group of four lines go before the .data line, or just the 2 lines in the brackets?: { . = ALIGN(32); ITRAP : { *(ITRAP$B) *(ITRAP$D) *(ITRAP$F) } } +--------------------------------------------------------------------------------------+ | The loader script "ld.i77.script" in "imp-linux/compiler" assumes | | that ld will concatenate this script into the default GCC loader script. | | This ld.i77.script is ESSENTIAL. | | If not then | | * run "ld --verbose" | | * copy the generated ld script into a file "compiler/ld.script" | | * insert the "section" contents of ld.i77.script before the .data | | instructions into the "compiler/ld.script" | | * rename the "compiler/ld.script" to be "compiler/ld.i77.script" | | This potential amendment to ld.i77.script MUST be done BEFORE running | | the "make bootstrap" in the compiler folder | | | | Imp-77 event handling depends on the individual event traps being in | | one section "ITRAP" in the order of ITRAP$B, all ITRAP$D the ITRAP$F sections. | | The Windows linker does this automatically, but the GCC loader ld needs to be told! | +--------------------------------------------------------------------------------------+ ###################################################### It works on my home x86 system: Distributor ID: Ubuntu Description: Ubuntu 18.04.6 LTS Release: 18.04 Codename: bionic Chassis: desktop Operating System: Ubuntu 18.04.6 LTS Kernel: Linux 4.15.0-159-generic Architecture: x86 arch reports i686 But below are the errors from running on this x86-64 system: Distributor ID: Ubuntu Description: Ubuntu 18.04.4 LTS Release: 18.04 Codename: bionic Chassis: server Operating System: Ubuntu 18.04.4 LTS Kernel: Linux 4.14.117-grsec-grsec+ Architecture: x86-64 arch reports x86_64 goodlife:~/tmp/imptest> ./imp2021-c hellow.imp 4 Statements compiled C executable post-execution checksum 3624383233 Code 50 bytes Data 102 bytes Diag 32 bytes Total size 184 bytes Generated for IMP source file: '/home/gtoal/tmp/imptest/hellow-c.imp' /usr/bin/ld: cannot find Scrt1.o: No such file or directory /usr/bin/ld: cannot find crti.o: No such file or directory /usr/bin/ld: skipping incompatible //usr/lib/x86_64-linux-gnu/libm.so when searching for -lm /usr/bin/ld: skipping incompatible //usr/lib/x86_64-linux-gnu/libm.a when searching for -lm /usr/bin/ld: cannot find -lm /usr/bin/ld: skipping incompatible /usr/lib/gcc/x86_64-linux-gnu/7/libgcc.a when searching for -lgcc /usr/bin/ld: cannot find -lgcc /usr/bin/ld: skipping incompatible /usr/lib/gcc/x86_64-linux-gnu/7/libgcc_s.so.1 when searching for libgcc_s.so.1 /usr/bin/ld: cannot find libgcc_s.so.1 /usr/bin/ld: skipping incompatible /usr/lib/gcc/x86_64-linux-gnu/7/libgcc.a when searching for -lgcc /usr/bin/ld: cannot find -lgcc collect2: error: ld returned 1 exit status