Operating Systems/Development Environment

From Wikiversity
Jump to navigation Jump to search

Start[edit | edit source]

Generally almost all developing of operating systems is done on a Unix like system. We will just assume you are running windows, and have a knowledge of Unix commands however.

In order to get a Unix like environment on windows it is necessary to install Cygwin. The mirrors are known to be unreliable, so try to choose a well known server during the install. For later purposes it will also be necessary to change the selection of the "devel" section to install, this commands it to install every development package in the section. (probably wasteful, but it is the only way I know to get binutils to build, comment in the discussion page if you know a better way.)

To get a working compiler for our operating system, we will have to compile our own because of the default one creating programs that rely on libraries that wont exist, but there are a few things that need to addressed before that.

First there are some dependencies that need to be taken care of for the gcc compiler.

GNU MP Bignum Library

MPFR Library

download and extract the tarballs, and follow the instructions from their documentation pages for installing in the Cygwin window. The usual choice for saving the tarballs is in cygwin\usr\src. (yes this will take some time, and laptop users should be concerned about possible overheating.)

Next you will need to download binutils and gcc sources from ftp.gnu.org and put them in your src directory. You are looking for the files that end in .tar.gz or tar.bz2 The latest versions as of April 4, 2008 are binutils-2.18 and gcc-4.3.0, for gcc it is recommended to get the gcc-core and g++ package, they will extract into the same directory and support c and c++ languages.