Skip to content

Commit

Permalink
Merge pull request #240 from jbruchon/switch-to-gcc
Browse files Browse the repository at this point in the history
End of transition to GCC-IA16
  • Loading branch information
mfld-fr authored Mar 13, 2019
2 parents 02ef0f8 + 18a46aa commit 1269667
Show file tree
Hide file tree
Showing 235 changed files with 12,827 additions and 4,519 deletions.
2 changes: 0 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@
*.a
*.1.gz
Kbuild
dev86
cross

#
Expand All @@ -33,7 +32,6 @@ target
*.orig
*.rej
/*.patch
elks_todo

#
# Debugging stuff
Expand Down
94 changes: 0 additions & 94 deletions Documentation/historic/README

This file was deleted.

8 changes: 0 additions & 8 deletions Documentation/historic/RELNOTES
Original file line number Diff line number Diff line change
Expand Up @@ -473,7 +473,6 @@ VERSION 0.0.66 NOTES
* Added code to doshd_release() so that floppy changes don't cause
corruption from old buffers.
* Small change to stack_check() %d changed to %ld for t_endbrk.
* Implemented Rob. de Bath changes for Dev86v13.
* Added a simple ramdisk driver which can access up to 8 64K
ramdisks. See Documentation/ramdisk.txt.
* Re-organised the way the debugging macros work, so they now have
Expand Down Expand Up @@ -781,13 +780,6 @@ VERSION 0.0.53(.1) NOTES
again. (I suspect the bug predates bug reports though). Instead
of going to the next track/head it was going back one sector,
which was bad.
* If you don't know already, this release is meant to install
over/into Dev86 0.0.11, so if you haven't gotten it already *get
it now!!!* To get everything working you have to unpack Dev86,
then unpack elks, build the (slightly-modified) Dev86, and then
build the kernel with it. This is done so that you don't have to
manually change dev86, and it dosen't really change anything
except the libc/syscall directory and the rules.86 file.
* minish unpacks into the tests/ directory, along with a new
makefile.
* Optimization is turned off, since there appears to be something
Expand Down
17 changes: 3 additions & 14 deletions Documentation/html/user/writing_apps_in_C.html
Original file line number Diff line number Diff line change
Expand Up @@ -31,20 +31,9 @@
<TD WIDTH=710 VALIGN=TOP>
<H2 CLASS="western"><SPAN STYLE="font-style: normal">Writing
applications for ELKS in C</SPAN></H2>
<P STYLE="margin-bottom: 0.5cm"><FONT FACE="Arial, sans-serif">ELKS
and application programs for ELKS are cross-compiled on a standard
Linux system with the dev86 package. This contains the bcc C
compiler, the ld86 linker, the as86 assembler and the ar86
archiver. You can download the dev86 package from the repository
of your Linux distribution or download it here:
<A HREF="https://github.com/jbruchon/dev86">https://github.com/jbruchon/dev86</A>
and compile and install it from this source code.</FONT></P>
<P STYLE="margin-bottom: 0.5cm"><FONT FACE="Arial, sans-serif">The
package also includes the elksemu program which allows 8086 ELKS
programs to be run under Linux-i386. These programs can be
compiled using the bcc compiler. However, elksemu will not run on
64bit Linux distributions. Therefore test the programs using Qemu
instead as described in the next chapter.</FONT></P>
<p>ELKS and application programs for ELKS are cross-compiled on
a standard Linux system with GCC-IA16.</p>
<p>Test the programs using Qemu as described in the next chapter.</p>
<P STYLE="margin-bottom: 0.5cm"><FONT FACE="Arial, sans-serif">For
a start let's compile a &bdquo;hello world&ldquo; program and run
that in ELKS. Here is the code:</FONT></P>
Expand Down
110 changes: 0 additions & 110 deletions Documentation/text/compile-on-winnt.txt

This file was deleted.

33 changes: 0 additions & 33 deletions Documentation/text/debug.txt

This file was deleted.

2 changes: 2 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -31,11 +31,13 @@ CFG_SHELL := $(shell \
.PHONY: all clean kconfig defconfig config menuconfig

all: .config
$(MAKE) -C libc all
$(MAKE) -C elks all
$(MAKE) -C elkscmd all
$(MAKE) -C image all

clean:
$(MAKE) -C libc clean
$(MAKE) -C elks clean
$(MAKE) -C elkscmd clean
$(MAKE) -C image clean
Expand Down
36 changes: 25 additions & 11 deletions README
Original file line number Diff line number Diff line change
@@ -1,21 +1,31 @@
ELKS, the Embeddable Linux Kernel Subset
----------------------------------------

This is a project to write a Linux-like operating system for systems based on
the Intel IA16 architecture (16 bits processors: i8088, i8086, i80188, i80186,
i80286, V20, V30 and compatibles).

Such systems are ancient computers (IBM-PC XT/AT and clones) or more recent
embedded ones that reuse their huge hardware & software legacy.
What is this ?
--------------

To build ELKS, you need a cross build chain, mainly based on DEV86 (still used
for the user land) and GCC-IA16 (now used for the kernel).
This is a project to write a Linux-like OS for systems based on the Intel
IA16 architecture (16 bits processors: 8088, 8086, 80188, 80186, 80286,
Nec V20, V30 and compatibles).

A script is provided to automatically download and build that cross chain:
Such systems are ancient computers (IBM-PC XT / AT and clones), or more
recent SBC / SoC / FPGA that reuse the huge hardware & software legacy
from that popular platform.


How to build ?
--------------

To build ELKS, you need a cross build tool chain, mainly based on the latest
GCC-IA16 (DEV86 including BCC was used for previous versions, but has been
dropped because it was obsolete and no more actively maintained).

A script is provided to automatically download and build that tool chain:

'tools/build.sh'

Note: all the scripts must be executed with the top folder 'elks/' as the
Note: all the scripts must be executed within the top folder 'elks/' as the
current one.

A script is provided to automate the whole build process (configuration,
Expand Down Expand Up @@ -46,10 +56,14 @@ The general build procedure for ELKS is as follows:
The target root folder is built in 'target/', and depending on your
configuration, that folder is packed as either a floppy disk image (fd1440,
fd1680, fd1200, fd720, fd360, without MBR), a hard-disk image (hd, with MBR),
or a file image (rom, tar), into the '/image' folder.
or a file image (ROM, TAR), into the '/image' folder.

Before writting the image on the real device, you can test it first on QEMU
with './qemu.sh' (will configure QEMU for an ISA system).
with './qemu.sh' (will configure QEMU as an ISA system).


More information
----------------

Questions? Problems? Patches? Open an issue in this project! You can also join
and email the 'Linux-8086' list at [email protected].
Expand Down
12 changes: 4 additions & 8 deletions build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -29,21 +29,17 @@ clean_exit () {
exit $E
}

# Disk images cannot be built unless we're UID 0
if [ "$UID" != "0" ] && [ "$1" != "clean" ]
then echo -e "\nWARNING: Disk images can only be built if you have root permissions"
fi

# Build environment setup
# TODO: check script status on return
. tools/env.sh

# Check tools
if [ ! -x "$CROSSDIR/bin/bcc" ]
if [ ! -x "$CROSSDIR/bin/ia16-elf-gcc" ]
then
echo "ERROR: BCC not found. You must build the cross tools"
echo "ERROR: GCC-IA16 not found. You must build the cross tools"
echo " before attempting to build ELKS. Run tools/build.sh"
echo " to automatically build that cross tools. Aborting."
exit 1
clean_exit 1
fi

# Working directory
Expand Down
Loading

0 comments on commit 1269667

Please sign in to comment.