The HyperNews Linux KHG Discussion Pages

Feedback: AS86 :

Forum: Tour of the Linux kernel source
Re: Question How can I get as86 and ld86? (Qingzhi Feng)
Keywords: As86 and Ld86
Date: Tue, 30 Dec 1997 10:32:30 GMT
From: Srikant Sharma (chiku) <srikants@wipinfo.soft.net>

I am adding here the portion from Linux.Assembly  HOWTO ..
This is just cut and paste which I think is relevent to 
The question :

For more details see Linux Assembly HOWTO part 1 Section 3.5

---------------------------------------------------------
 3.5.  AS86

  AS86 is a 80x86 assembler, both 16-bit and 32-bit, part of Bruce
  Evans' C Compiler (BCC).  It has mostly Intel-syntax, though it
  differs slightly as for addressing modes.

  3.5.1.  Where to get AS86

  A completely outdated version of AS86 is distributed by HJLu just to
  compile the Linux kernel, in a package named bin86 (current version
  0.4), available in any Linux GCC repository.  But I advise no one to
  use it for anything else but compiling Linux.  This version supports
  only a hacked minix object file format, which is not supported by the
  GNU binutils or anything, and it has a few bugs in 32-bit mode, so you
  really should better keep it only for compiling Linux.

  The most recent versions are published together with the FreeBSD
  distribution.  Well, they were: I could not find the sources from
  distribution 2.1 on :( Hence, I put the sources in my place:

  <http:///www.eleves.ens.fr:8080/home/rideau/files/bcc-95.3.12.src.tgz>

  The Linux/8086 (aka ELKS) project is somehow maintaining bcc (though I
  don't think they included the 32-bit patches).  See around
  <http://www.linux.org.uk/Linux8086.html> <ftp://linux.mit.edu/>

  Among other things, it supports Linux GNU a.out format, so you can
  link you code to Linux programs, and/or use the usual tools from the
  GNU binutil package to manipulate your data.  This version can co-
  exist without any harm with the previous one (see question 2.4.4
  below).

  BCC from 12 march 1995 and earlier version has a misfeature that makes
  all segment pushing/popping 16-bit, which is quite annoying when
  programming in 32-bit mode.  A patch is published in the Tunes project

  <http://www.eleves.ens.fr:8080/home/rideau/Tunes/>

  subpage files/tgz/tunes.0.0.0.25.src.tgz in unpacked subdirectory
  LLL/i386/ The patch should also be in available directly from
  <http://www.eleves.ens.fr:8080/home/rideau/files/as86.bcc.patch.gz>
  Bruce Evans accepted this patch, so if there is a more recent version
  of bcc somewhere someday, the patch should have been included...

  Portability note: as86 makes a lot of presomptuous assumptions about
  type sizes, which prevents it from correctly running on architectures
  that fail to me