sudo apt update -y
sudo apt -y install build-essential binutils nasm xorriso grub-common qemu-system-i386 mtools
You need to build GCC cross compiler for i686 or x86_64 supports x32 architecture/s to compile from sources. Also required gcc and stdc++ libraries. Refer to GCC documentation for detailed information - https://gcc.gnu.org/install/
Before build the project set some variables - DEBUG and LIBS_PATH.
These variables may pass through make command make *variables* *rule*
, or usage environment variables export *name*=*value*
.
- DEBUG. Not takes value. If defineв, the debug version of the project will be build, otherwise the release version. Responsible for the debug version of the project to test OS via GDB.
- LIBS_PATH. Takes the path to the required libraries. Now gcc library is required, supplied with the compiled.
Build and run release version
make all
Build and run debug version
make DEBUG=* all
or
export DEBUG=*
make all