1
0
Fork
You've already forked dev86
0
forked from jbruchon/dev86
C compiler, assembler and linker environment for the production of 8086 executables
  • C 86.9%
  • Assembly 5.5%
  • Makefile 2%
  • Logos 1.8%
  • AngelScript 1.5%
  • Other 2.3%
Find a file
2023年09月17日 09:29:13 -04:00
ar ar: prevent buffer overflow on archive creation 2022年07月19日 19:54:53 +02:00
as as86: Allow rep[nz] prefix before other prefixes 2013年12月22日 09:48:26 +01:00
bcc Make dev86 working "in tree" 2017年12月02日 22:33:13 +01:00
bin86 Import Dev86src-0.16.18.tar.gz 2013年10月23日 23:48:50 +02:00
bootblocks Merge pull request #12 from mgorny/makez 2018年04月18日 07:36:26 -04:00
copt Revert "copt: fix a minor glitch in copt/rules.86" 2015年12月12日 08:19:40 -05:00
cpp cpp: fix race writing token.h files 2022年04月29日 16:52:27 +01:00
dev86arc Add .travis.yml for running "make distribution" tests. 2018年04月20日 23:17:15 +01:00
dis88 [dis88] Move back from ELKS 2017年01月23日 21:46:45 +01:00
doselks Import Dev86src-0.13.0.tar.gz 2013年10月23日 23:40:02 +02:00
elksemu Import Dev86src-0.16.18.tar.gz 2013年10月23日 23:48:50 +02:00
ld Merge pull request #26 from Schievel1/master 2023年09月17日 09:29:13 -04:00
libbsd Merge pull request #12 from mgorny/makez 2018年04月18日 07:36:26 -04:00
libc [libc] update _signal syscall semantics, per ABI change in ELKS 2020年05月20日 23:28:28 +08:00
man Add -7 option to compiler to enable ancient construct 2013年10月29日 16:30:52 +01:00
tests libc tests for MSDOS target (far away from complete ;)) 2018年10月14日 17:52:33 +02:00
unproto unproto: fix macOS Sierra compilation error reported by scontini76 2016年10月04日 12:05:48 -04:00
.gitignore libc tests for MSDOS target (far away from complete ;)) 2018年10月14日 17:52:33 +02:00
.travis.yml Add .travis.yml for running "make distribution" tests. 2018年04月20日 23:17:15 +01:00
Changes Import Dev86src-0.16.17.tar.gz 2013年10月23日 23:48:50 +02:00
Contributors formatting (tabs) 2018年10月04日 15:39:18 +02:00
COPYING Import Dev86src-0.0.11.tar.gz 2013年10月23日 23:38:07 +02:00
GNUmakefile Import Dev86src-0.16.19.tar.gz 2013年10月23日 23:48:50 +02:00
ifdef.c Import Dev86src-0.16.18.tar.gz 2013年10月23日 23:48:50 +02:00
libcompat Import Dev86src-0.13.0.tar.gz 2013年10月23日 23:40:02 +02:00
MAGIC Import Dev86src-0.16.3.tar.gz 2013年10月23日 23:48:46 +02:00
Makefile Makefile: support BUILD_CC for cross-compilationof dev86 2022年04月29日 16:34:30 +01:00
makefile.in Add .travis.yml for running "make distribution" tests. 2018年04月20日 23:17:15 +01:00
Mk_dist Create distribution directory if required 2013年10月29日 16:30:52 +01:00
mkcompile Import Dev86src-0.16.11.tar.gz 2013年10月23日 23:48:48 +02:00
README Import Dev86src-0.16.18.tar.gz 2013年10月23日 23:48:50 +02:00

This is a development environment for ELKS-86 and standalone 8086 code.
All you need to do is 'make' from the top directory and the main parts
of the package will be made. These can be tested by using the 'ncc'
program from the newly created bin subdirectory. (ncc is a varient of
the bcc driver program that doesn't need to be installed to be used).
Use 'make install' to install them.
Some other bits can be built by 'make other' and installed with
'make install-other'.
Note the the make files for the libraries can only be run using
GNU-make but version 3.82 has a bug (No. 30612) that prevents this
working properly.
If you want it to install under /usr/local instead you can specify
the prefix on the first make ie: 'make PREFIX=/usr/local' this is
remembered until 'make.fil' is rebuilt. 
The manual pages in the man subdirectory are matched to these programs,
there are also some hints for using as86 well. The tests and bootblocks
directories give some example code.
The bcc command defaults to using /usr/lib/bcc/include and /usr/lib/bcc
the libraries _and_ include files are copied to these locations by
install. This can be changed by overriding 'PREFIX=/usr/...' or
'LIBDIR=/usr/...' on the initial make. Also available in the
same way are the BINDIR, INCLDIR, ASLDDIR, MANDIR and ELSESRC.
The 'ELKSSRC=/usr/src/elks' variable can be altered if you have ELKS on
path different from the default or ELKSSRC=/dev/null uses the supplied
ELKS headers. The ASLDDIR variable can be used to move as86 and ld86
into the LIBDIR with 'ASLDDIR=$(LIBDIR)'. The final '/include' is added
to the end of INCLDIR.
In the unlikely event you're makeing a non-cross development environment
you can, on the initial make, do "make PREFIX=/' to have the libraries
and include files in 'Native' locations.
Note: These prefix options only effect the 'bcc.c' driver program and
 the install scripts, all the others get their paths from bcc.c.
 The ELKSSRC location can, however, greatly effect how the ELKS
 libraries are built.
If you don't want to install in the locations specified above there
is also a DIST= argument to make install that is used to specify the
distribution root to install to.
The last option is not to install at all. All the executables in the
bin directory can be moved to whereever you wish except for bcc and ncc.
To use bcc at any other location you can create a symlink from your
new location to the 'ncc' executable and it will be able to find
the libraries in the build directory:
eg:
 cp ar86 elksemu objdump86 $HOME/bin/.
 cp as86 as86_encap ld86 $HOME/bin/.	# Optional.
 ln -s `pwd`/ncc $HOME/bin/bcc
All the versions of the library are built by make; 'normal', 'fast',
'MSDOS', 'standalone' and Linux-i386.
You use the other libraries like this:
 'FAST' 	$ bcc -Mf prog.c -o prog
 Caller saves $ bcc -Mc prog.c -o prog
 MSDOS	$ bcc -Md prog.c -o prog.com
 Standalone	$ bcc -Ms prog.c -o prog.sys
 Linux-i386	$ bcc -Ml prog.c -o prog
The 'Fast' and 'Caller saves' versions alter the function call assember 
in an effort to make it smaller and faster.
The 'MSDOS' version creates _small_ model (64k+64k) COM files. Because
of DOS limitations the filesize is limited to about 65000 bytes but
the BSS and Stack can be upto 64k on top of that.
The 'standalone' version creates executables like normal ELKS a.out
files but with no operating system calls, just BIOS ones. These 
files are suitable for running on a bare machine started by one of
the boot blocks in the bootblocks subdirectory. If you add a '-d'
option to the link stage the a.out header will be removed.
The Linux-i386 version generates static Linux OMAGIC a.out programs,
they need neither elksemu nor a.out shared libraries to run. Unfortunatly
these can no longer be converted to ELF executables as Linux will not
execute unpageable ELF executables. To allow conversion to ELF if you
pass the '-z' flag to 'bcc -Ml' the linker will now create QMAGIC a.out
executables, these are somewhat larger but can be converted with objcopy.
If you want to install everything in one go just login as root an do:
$ make install-all
The as86 and ld86 with this are _different_ from the minimum version
needed for the linux-i386 kernel and can replace them, versions before
0.12.0 will not work with this version of bcc.
I suggest you install the kernel patch or load the module to allow
transparent execution of elks executables. If you're using a post
2.1.43 or 2.0.36 kernel the only module you need is the binfmt_misc
driver configured like this:
echo ':i86-elks:M::\x01\x03\x20\x00:\xff\xff\xff\x83:/usr/bin/elksemu:' \
 > /proc/sys/fs/binfmt_misc/register
The elksemu executable must be stored in /usr/bin/elksemu or the above
line adjusted.
Previous kernel versions need a special module or patch described in
elksemu/README (All the options need the elksemu executable installed
correctly)
Copyrights
----------
The `bcc', 'as' and `ld' parts of the distribution are now covered by
the GPL. The `bccfp' library now in the libc/i386fp directory is under
the LGPL. (Primary copyright holder Bruce Evans)
The contents of the libc and libbsd subdirectories are under the LGPL
with a few noted exceptions. The programs in 'tests', elksemu, copt
and the bootblocks directory are under the GPL. Dis88 is freely
distributable if the source is distributed also. Unproto is freely
distributable as long as Wietse Venema <wietse@wzv.win.tue.nl> and the
"Mathematics and Computing Science Dept. Eindhoven University of
Technology. The Netherlands." is given credit.
In libc the regular expression routine and the printf/scanf functions are
not under LGPL, the former is 'freely distributable' the latter is public
domain.
See the COPYING file in this directory for the GPL and the COPYING file
in the libc directory for the LGPL.
--
Rob. (Robert de Bath <robert$@debath.co.uk>)