Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Building Jonesforth - asm/unistd.h: No such file or directory

When attempting to build Jonesforth (32-bit GNU Assembler program) on Ubuntu 16.04.4 64-bit (Xenial Xerus), I'm seeing the following:

~/src/jonesforth $ make
gcc -m32 -nostdlib -static -o jonesforth jonesforth.S
jonesforth.S:1154:24: fatal error: asm/unistd.h: No such file or directory
compilation terminated.
Makefile:11: recipe for target 'jonesforth' failed

Looking in the file jonesforth.S, I noticed the following lines:

//#include <asm-i386/unistd.h>  // You might need this instead
#include <asm/unistd.h>

I've tried using asm-i386/unistd.h instead, but that also didn't seem to help.

Is the best course of action to install more headers via sudo apt install linux-headers...? If so, which should I go with? Should linux-headers-generic be sufficient?

Or, should I change the header that jonesforth.S is referring to?

like image 648
dharmatech Avatar asked Dec 08 '25 11:12

dharmatech


1 Answers

You need to install package multilib.

like image 67
Phos V Avatar answered Dec 10 '25 07:12

Phos V



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!